Almost thrown off the plane for... doing math

THere’s a huge difference though: you see someone doing something potentially harmful that requires immediate action versus WRITING. How can writing be considered suspicious or dangerous? I mean, even if he was writing a formula to bomb something, how was that sufficient to stop the plane? It’s not like the formula on the paper would combust and firebomb the plane…