# Is a constant function is a linear function?

Is a function of the form $F (x) = C$ for some $C \in \mathbb R$ a linear function? If No , What a bout the graph of it ? Isn't it a line?

Thank you very much

It depends on how you define "a linear function" The graph is a horizontal line. Often times, books describe linear functions as polynomials of degree 1, which would require a nonzero slope, so would call this a constant function instead.

Generally, when we discuss something being linear, we mean it scales with the input. Constants don't.

• Constants can. Oct 30 '17 at 1:13
• @KennyLau Constants can what?
– Alan
Oct 30 '17 at 1:13
• You mean that it isn't linear Oct 30 '17 at 1:14
• @Alan Constants can scale with the input. Oct 30 '17 at 1:14
• @Alan think about zero. Oct 30 '17 at 1:16

It really depends on your definition. It's certainly quite common to refer to a linear polynomial $$f(x) = ax +b$$ as a linear function. (And this naming is supported by the fact that the graph is a line, as you pointed out.) By this definition, the constant function $f(x) = b$ is a linear function.

However, we also have the notion of a linear transformation of a vector space, which is essentially something obeying $$f(a\vec x+b\vec y) = a f(\vec x) + b f(\vec y)$$ and it's also typical to defined "linear function" as referring to a linear transformation. In the vector space $\mathbb R,$ the mapping $f(x) =b$ is not a linear transformation (unless $b$ is zero). You can see this by $$f(x+x) = b \ne 2b = f(x) + f(x).$$ So by this definition, the constant, and more generally things like $f(x) = ax+b$ are not linear functions.

There is a name for mappings of vector spaces of the form $f(\vec x) = A\vec x +\vec b$ (where $A$ is a matrix) that generalize the linear polynomial but are not linear transformations unless $\vec b = \vec 0$. They are called affine transformations.

EDIT Reading some of the other answers it occurs to me that perhaps my answer is too advanced as it presumes knowledge of vector spaces. To ensure this answer is useful, I'll give the bottom line down here again: It depends on the definition. There is a perfectly useful and common definition that a linear function is anything whose graph is a line, in which case $f(x) = b$ is a linear function. For various reasons, it's also common to only consider functions of the form $y = ax$ with no constant term as linear functions. This isn't wrong... it's just a different, more restrictive definition that is used sometimes as well. For instance we might want 'linear' to imply the nice property of direct proportionality rather than that its graph forms a line.

• The question is for preparatory school level , What should be the suitable answer? Oct 30 '17 at 1:45
• @user373141 There's no right or wrong answer. It's whatever definition your class is using. Oct 30 '17 at 2:34
• @user373141 As for what definition you "should" be using in this context, I'd lean towards "yes". FYI here is the wikipedia that explains the different contexts. It suggests in calculus type contexts $f(x) = ax+b$ are typically called "linear functions" whereas the more restrictive $f(x) = ax$ should be called 'linear homogeneous functions' or something like that. en.wikipedia.org/wiki/Linear_function Oct 30 '17 at 2:44

For $C=0$, $F$ is a linear function. For $C\neq 0$, $F$ is an affine-linear function, but not a linear function.

However, in school mathematics, the term "linear" is often also used for affine-linear functions.

If the constant function is constantly $0$, then it's linear. Linear functions take $0$ to $0$. This, and the fact that other constant functions won't be linear, follows from the fact that for linear functions, $f (cx)=cf (x)$ for all $c$ in the field over which we have a vector space. ..

At least, this reasoning applies to linear transformations...

First degree polynomials, on the other hand, have graphs that are lines... so are called linear functions sometimes. ..

• Of course in college algebra, every polynomial function of degree 1 is called a "linear function"... Oct 30 '17 at 1:23
• @CarlMummert I guess I should edit. ..
– user403337
Oct 30 '17 at 1:27
• The question is for preparatory school level , What should be the suitable answer? Oct 30 '17 at 1:46
• @user373141 I like my answer... Apparently it should be two-tiered...
– user403337
Oct 30 '17 at 1:54

From the point of view of more advanced mathematics, such as calculus, a constant function is also called a linear function. But from the point of view of some elementary textbooks, such as in pre-algebra, a constant function is not called a linear function, and a linear function is defined as a function of the form $y = mx + b$ with $m \not = 0$.

Similarly, from the point of view of advanced mathematics a square is a kind of rectangle and a circle is a kind of oval, but from some elementary viewpoints a rectangle can't be square and an oval can't be circular.

The difference in viewpoints is that the more advanced viewpoint views a constant function as a special kind of linear function, while the more elementary viewpoint views the linear functions as going beyond the constant functions by no longer having horizontal graphs. Similarly with circles and ovals. Each viewpoint is appropriate for a certain level of understanding.

Another example comes with quadratic functions. Naively, we might think that any function of the form $y = ax^2 + bx + c$ would be called "quadratic", but many texts in algebra and calculus require $a \not = 0$. This is because they have already covered the case $a = 0$ when they looked at linear functions, so they want to reserve "quadratic functions" for the ones that are not linear. Books with a similar approach may want to reserve the term "linear functions" for the ones that are not constant.

Actually, calculus books can take a middle approach: the book that I taught out of for a while considers a linear function to be any function of the form $y = ax+b$ (even constant) but a quadratic function is of the form $y = ax^2 + bx + c$ with $a \not = 0$. So, for this text, every constant function is linear, but no linear function is quadratic. The terminology is designed to facilitate the exposition.

By the way, there is a different concept of "linear function" in linear algebra, which is also called a linear map. In the sense of basic high school algebra, the function given by $y = 2x + 1$ is a linear function. In the context of linear algebra that function is an affine function but not a linear function because, for example, $2y(3) = 2(7) = 14 \not = 7 = y(2\cdot 3)$.

• From the point of view of linear algebra, which is quite advanced mathematics, a constant function is not a linear function. Oct 30 '17 at 1:24
• The viewpoint that a square is a kind of rectangle or not, is one of different definitions, not one being more advanced. Oct 30 '17 at 1:25
• @Kenny Lau: the constant function 0 is certainly a linear map on a vector space. But the question is tagged with "algebra-precalculus" so the asker is more likely interested in the precalculus definitions. Oct 30 '17 at 1:25
• Then don't throw the word "advanced" around. Oct 30 '17 at 1:25
• Hmm? I only wrote "more advanced". Nothing here is genuinely advanced. But I suspect that if you check your favorite calculus text it will say that $y = 2x+1$ is a linear function. Oct 30 '17 at 1:29