4

For as simple as it is, I never fully grasped what mathematicians and physicists mean with linear .

Intuitively anything that looks like a straight line is interpreted as linear, like something in the form $f(x) = mx + q$ or any other function that maps $R \rightarrow R$ resulting in a graph that looks like a line.

Last time I had the chance to talk to a physicist, the guy made a "meh, not really" expression about this, meaning that I had the feeling that this is "true" at some conditions but it's not a rigorous and universally accepted definition.

So, since we are talking about this, could you define the concept of linear from the geometric and numeric point-of-view ?

So maybe I can really grasp what "linear" means everytime this adjective appears in the names of math topics like linear algebra, linear programming, and so on.

Shaun
  • 47,747

3 Answers3

3

A linear function is any function that satisfies, in general, $f(ax+by) = af(x)+bf(y)$. This function could be one dimensional or not.

Geometrically, linear functions tend to look like lines or their higher dimensional equivalents. For instance, a 2-D linear function looks like a flat plane, 3-D looks like a cube, etc...

However, not all things that look like lines are linear. Note that $f(x) = ax+b$ does not satisfy $f(x+y) = f(x)+f(y)$. If we wish to be very precise, we call this function affine. In essence, an affine function is a linear function plus a constant shift, which is manifest by the the existence of the constant $b$.

The distinction is really one of our coordinate system, however. In such a case, we can choose a slightly different coordinate system by taking the map $x \mapsto x-\frac{b}{a}$. Then, $ax+b \mapsto a(x-\frac{b}{a})+b = ax$. Now, in this shifted coordinate system, we do have a linear function, and we can treat it as such for the purposes of our analysis. We can go back and add $b/a$ to our results later, if we want. (Sometimes).

So, for that reason, we tend to call all degree-1 polynomials "linear", even if they aren't strictly linear.

Emily
  • 36,334
  • same question http://math.stackexchange.com/questions/794582/what-is-linear-numerically-and-geometrically-speaking#comment1644929_794630 – user2485710 May 14 '14 at 14:36
  • @user2485710 In a matrix representation, the matrix represents the linear map. In essence, the matrix-vector system $Ax=b$ is a shorthand way of writing the following system:$$\begin{align}a_{11}x_1+a_{12}x_2+\cdots+a_{1m}x_m &= b_1 \ \vdots \ a_{n1}x_1+a_{n2}x_2+\cdots+a_{nm}x_m &= b_n\end{align}$$ So each element of the matrix can be thought of as a coefficient in the linear system. – Emily May 14 '14 at 15:31
2

The concept of linearity can be explored easily enough for real functions. Formally, a function $f:\mathbb R \rightarrow \mathbb R$ is linear if $f(x+y)=f(x)+f(y)$. Note that any function of the form $f(x) = ax$ has this property since $$ f(x+y)= a(x+y) = ax+ay = f(x)+f(y). $$ In fact, it can be proved that the only continuous functions satisfying $f(x+y)=f(x)+f(y)$ are the functions of the form $f(x)=ax$. Note that $f(x)=ax+b$ doesn't cut it, unless $b=0$, because $$ f(x+y)= a(x+y)+b \neq (ax+b) + (ay+b) = f(x)+f(y). $$

Intuitively, we might say that a function is linear if its output is proportional to its input. If we double in the input, we double the output. If we triple the input, we triple the output. This is again a consequence of the defining property: $$ f(2x) = f(x+x) = f(x)+f(x) = 2f(x). $$ It's also easily derived from the form $f(x)=ax$.

More generally, a function $f:{\mathbb R}^n \rightarrow {\mathbb R}^m$ is linear if $f(x+y)=f(x)+f(y)$ for all $x,y\in{\mathbb R}^n$ and $f(\lambda x)=\lambda f(x)$ for all $x\in{\mathbb R}^n$ and $\lambda \in \mathbb R$. The symbol $\lambda$ is sometimes called a scalar and isn't really necessary when $m=n=1$, as above. In this more general case, it turns out that any such function can be represented in the form $f(x) = Ax$, where $A$ is an $m\times n$ matrix.

Even more generally, we might discuss linear functions $f:U\rightarrow V$, where $U$ and $V$ are vector spaces. Things get a bit more abstract at this point. The matrix representation might no longer be good as the spaces might be infinite dimensional. The same ideas still apply, however. We still need $f(x+y)=f(x)+f(y)$ and $f(\lambda x)=\lambda f(x)$. Differentiation is an example of such an operation, since $$\frac{d}{dx} (g(x) + h(x)) = g'(x)+h'(x).$$ Care needs to be taken with the domain; this operation maps the set of continuously differentiable function to the set of continuous ones for example.

Mark McClure
  • 31,496
  • what is the equivalent for $f(x)$ from the $R \rightarrow R$ case when using a matrix representation ? what each cell represents ? – user2485710 May 14 '14 at 14:35
  • 1
    @user2485710 I'm not certain I understand your question - specifically, I don't know what you mean by a cell. In the $R\rightarrow R$ case, though, we have $f(x)=ax$. In the $R^n\rightarrow R^m$ case, we have $f(x)=Ax$. They are exactly analogous. The number $a$ could even be though of as a $1\times 1$ matrix. – Mark McClure May 14 '14 at 14:41
  • @user2485710 Do you know matrix multiplication? – Mark McClure May 14 '14 at 14:42
  • by cell I mean the element $a_{m_x,n_y}$ in a $m \times n $ $A$ matrix . Your explanation meets what I was picturing in my mind, but at this point both matrices and vectors are useless in the definition of the linear algebra itself, they are just a way to represent ... what ? It's like linear algebra could be what it is even without vectors and matrices . And yes, I know about matrix multiplication. – user2485710 May 14 '14 at 14:45
  • @user2485710 Yes, I agree. From the abstract perspective, a matrix is a tool to represent a linear transformation, i.e. a linear function mapping one finite dimensional vector space to another. The matrix concept is not a defining characteristic of linear transformations. Hardly useless, though. :) I could elaborate further but it might be pointless, if you don't know matrix multiplication yet. – Mark McClure May 14 '14 at 14:50
  • I would appreciate an expansion on that, I know about matrix multiplication. – user2485710 May 14 '14 at 14:54
  • 1
    @MarkMcClure thank you for this nice answer. A clarification please: "... a function $f:{\mathbb R}^n \rightarrow {\mathbb R}^m$ is linear if $f(x+y)=f(x)+f(y)$ for all $x,y\in{\mathbb R}^m$..." the domain of this function is ${\mathbb R}^n$ shouldn't $x,y\in{\mathbb R}^n$ instead of $x,y\in{\mathbb R}^m$? – Steven Jun 29 '24 at 18:51
  • 1
    @Sha Yes, you're absolutely right. I edited my response. Thanks!! – Mark McClure Jun 30 '24 at 01:08
  • Thank you Prof. @MarkMcClure – Steven Jun 30 '24 at 06:43
1

We normally say that a function is linear, and normally in the following (slightly informal) sense: Let's suppose that a function $f$ is mapping elements from $A$ to $B$ and both $A$ and $B$ have a way of both adding elements together and also multiplying elements by scalars (what I really want to say is that $A$ and $B$ are vector spaces but don't worry if you don't know what a vector space is - just think of it is a place that you can add elements together and multiply by scalars).

Now, we say that $f\colon A\to B$ is linear if for any points $x,y$ in $A$ we have $f(x+y)=f(x)+f(y)$ and for any real number $r$ we have $f(r\cdot x)=r\cdot f(x)$.

In the special case that $A$ and $B$ are both $\mathbb{R}$, the graph of a linear function is in fact a straight line in the plane $\mathbb{R}\times\mathbb{R}$ and so at least in this sense it satisfies your intution. In order to get a better geometric intuition, you really need to take a course/read a book on linear algebra - generally a first year module in any good mathematics degree at the university level.

Dan Rust
  • 30,973
  • In particular the word "linear" on its own has no real definition. When you see something with the word "linear" in front of it, usually it's because there's a linear function in it somewhere. – Jack M May 14 '14 at 14:16
  • so linear algebra is linear because I can add matrices to matrices and vectors to vectors $f(x+y) = f(x)+f(y) $ and/or use coefficients for matrices and vectors ? In a $4 \times 3$ Matrix what is the equivalent of the $f(x)$ function in $R \rightarrow R$ ? – user2485710 May 14 '14 at 14:34
  • 1
    Linear algebra is linear because it is the study of linear functions on vector spaces (at its root anyway). A matrix actually is a linear map (and vice versa for finite dimensional spaces). So a $4\times 3$ matrix can be thought of as a linear map from $\mathbb{R}^4$ to $\mathbb{R}^3$. – Dan Rust May 14 '14 at 14:38