A linear system is one where the whole is precisely the sum of its parts. You can know how different parts will act together by simply knowing how they act in isolation. A nonlinear function lacks this nice property. For example, consider a linear function . It satisfies the property that . The function of the sum is the sum of the functions. One important point to note is that what is considered to be the paragon of linearity, namely a line on a graph, i.e. is not linear since . The y-intercept destroys the linearity of the line. A line is instead affine, which is to say a linear function shifted by a constant. A linear differential equation has the form
where can be in any dimension. Solutions of a linear differential equation can be multiplied by any constant and added together.
Linearity is thus essential for engineering. If you are designing a bridge then you simply add as many struts as you need to support the predicted load. Electronic circuit design is also linear in the sense that you combine as many logic circuits as you need to achieve your end. Imagine if bridge mechanics were completely nonlinear so that you had no way to predict how a bunch of struts would behave when assembled together. You would then have to test each combination to see how they work. Now, real bridges are not entirely linear but the deviations from pure linearity are mild enough that you can make predictions or have rules of thumb of what will work and what will not.
Chemistry is an example of a system that is highly nonlinear. You can’t know how a compound will act just based on the properties of its components. For example, you can’t simply mix glass and steel together to get a strong and hard transparent material. You need to be clever in coming up with something like gorilla glass used in iPhones. This is why engineering new drugs is so hard. Although organic chemistry is quite sophisticated in its ability to synthesize various compounds there is no systematic way to generate molecules of a given shape or potency. We really don’t know how molecules will behave until we create them. Hence, what is usually done in drug discovery is to screen a large number of molecules against specific targets and hope. I was at a computer-aided drug design Gordon conference a few years ago and you could cut the despair and angst with a knife.
That is not to say that engineering is completely hopeless for nonlinear systems. Most nonlinear systems act linearly if you perturb them gently enough. That is why linear regression is so useful and prevalent. Hence, even though the global climate system is a highly nonlinear system, it probably acts close to linear for small changes. Thus I feel confident that we can predict the increase in temperature for a 5% or 10% change in the concentration of greenhouse gases but much less confident in what will happen if we double or treble them. How linear a system will act depends on how close they are to a critical or bifurcation point. If the climate is very far from a bifurcation then it could act linearly over a large range but if we’re near a bifurcation then who knows what will happen if we cross it.
I think biology is an example of a nonlinear system with a wide linear range. Recent research has found that many complex traits and diseases like height and type 2 diabetes depend on a large number of linearly acting genes (see here). Their genetic effects are additive. Any nonlinear interactions they have with other genes (i.e. epistasis) are tiny. That is not to say that there are no nonlinear interactions between genes. It only suggests that common variations are mostly linear. This makes sense from an engineering and evolutionary perspective. It is hard to do either in a highly nonlinear regime. You need some predictability if you make a small change. If changing an allele had completely different effects depending on what other genes were present then natural selection would be hard pressed to act on it.
However, you also can’t have a perfectly linear system because you can’t make complex things. An exclusive OR logic circuit cannot be constructed without a threshold nonlinearity. Hence, biology and engineering must involve “the linear combination of nonlinear gadgets”. A bridge is the linear combination of highly nonlinear steel struts and cables. A computer is the linear combination of nonlinear logic gates. This occurs at all scales as well. In biology, you have nonlinear molecules forming a linear genetic code. Two nonlinear mitochondria may combine mostly linearly in a cell and two liver cells may combine mostly linearly in a liver. This effective linearity is why organisms can have a wide range of scales. A mouse liver is thousands of times smaller than a human one but their functions are mostly the same. You also don’t need very many nonlinear gadgets to have extreme complexity. The genes between organisms can be mostly conserved while the phenotypes are widely divergent.
6 thoughts on “Linear and nonlinear thinking”
I was once implicitly taught that everything interesting is nonlinear. But I later realized that most of my undergraduate courses in physics focused on linear equations — Newton’s 2nd law, Maxwell’s equations, Kirchhoff’s laws (voltage and current), Schrodinger’s equation, etc — and these were all still interesting.
Now in neuroscience I’ve become more interesting in linear thinking for complex systems.
For example, in terms of dynamics, nonlinear oscillations are robust but linear oscillations are generalizable. A nonlinear oscillation can do one thing but do it well. A linear oscillation can produce a continuum of different patterns based on initial conditions.
So, a nonlinear oscillation is good for a single neuron (do one thing — spike — and do it well) while linear oscillations might be better for a circuit that needs to produce a space of possible time-varying outputs such as in movement generation.
More generally, it’s worth noting that nonlinear feedback of nonlinear dynamical systems often linearizes the system. This is exploited often by control engineers but I see no reason why we wouldn’t expect to find this effect in the brain where feedback is ubiquitous.
I think biology as “the linear combination of nonlinear gadgets” is a good summary. After all, this is what has worked well for many machine learning problems.
@jseely Actually, Newton’s 2nd law can be highly nonlinear if the forces depend nonlinearly on the positions, which they often do. Maxwell’s equations in a medium of charged particles is plasma physics and this is also extremely nonlinear. But your point is well taken.
3 comments: 1) the blog azimuth has a post last month (sept 3) with a discussion which overlaps with this one. 2) I don’t think everyone is convinced on the approximate linearity of the missing heritability issue—in general (though i haven’t thought about this lately) its often hard to distinguish between some linear versus some other nonlinear mechanism generating some data (the same issue arises in trying to determine whether a time series is deterministic or stochastic (this is discussed on azimuth) 3) it seems one could also compare nonlinear combinations of linear things (eg Born’s rule, spin-statistics)
If the “nonlinear behavior approximates a linear model” is so prevalent in the physical sciences, can you point to any mathematical theory demonstrating how nonlinear gadgets (or functions) combine in ways that are linear in the end result?
excluding some logarithmic function?
@Tom Two separate points. The first is that any smooth nonlinear function over a small range looks linear. This is trivially true. The second and more subtle point is that nonlinear devices (functions) can be combined additively. It is thus linear in the functions but not necessarily linear in the variable of the nonlinear function. i.e. Say f_i(x) are nonlinear functions of x. Then y = \sum_i a_i f_i(x) is “linear” as a function f_i’s while nonlinear in x. The whole point is that you can design a system by combining the nonlinear f_i’s using linear theory.