Orthogonal Concerns

When a programmer refers to two factors as “orthogonal concerns”, it means that a change with regard to one factor doesn’t affect the other. We use the term “orthogonal” to mean something like “independent” or “unrelated”.

For example, domain logic, display logic and persistence logic are generally considered orthogonal concerns. Changing one should not affect the others.

“Orthogonal” traditionally means “perpendicular.” It comes from the Greek words for “upright” and “angle”. Our use of it to mean “independent” seems to come from geometry.

Picture a map, with an east-west axis and a north-south axis. If I travel along one of these axes, it doesn’t affect my location along the other. The axes are orthogonal in both senses we’ve discussed: they’re at literal right angles to each other (perpendicular), and changing my north-south coordinate doesn’t necessarily affect my east-west coordinate (independent).

(As an aside: When I hear a word I don’t know, I tend to look it up. But when you hear “orthogonal” the way programmers use it and look it up, the definitions aren’t very helpful. It’s probably more reliable to use words like “independent” or “unrelated”. Although “orthogonal” sure sounds fancy.)