I can see arguments both for and against classifying constant functions as linear functions.
- Against: "Linear function" means "first-degree polynomial function", and constant functions are not first-degree.
- For: "Linear function" means "polynomial function of degree at most 1, and constant functions do match that definition.
- Against: But we don't define "quadratic function" to mean "polynomial function of degree at most 2"; if we did, then linear functions (under whatever definition) would also be quadratic, and nobody uses the word "quadratic" that way.
- For: Nevertheless, the graph of a constant function is a line, so it's a linear function.
- Against: But the graph of $x=c$ is also a line, and that's not a function at all, let alone a linear one!
- For: The notion of "slope" is well-defined for constant functions, and the slope just happens to be $0$.
- Against: See above re: quadratic functions. Writing a constant function in the form $y=mx + b$ with $m=0$ is analogous to writing a linear function in the form $y=ax^2 + bx + c$ with $a=0$. Yes, you can do that, but we generally don't.
To some extent I can see this as just a matter of taste or convention. Does anybody see any compelling arguments one way or another that I have overlooked? Is there a "best" approach?
(Background: I recently put the following True/False question on an exam:
If a function is linear, then it is invertible.
Whether this is true or false depends on whether you regard constant functions as "linear" or not.)