Linear function (calculus): Difference between revisions

Content deleted Content added
Slope: Standard forms of a linear function
Relationship with linear equations: Clarify, omit needless words, add example
Line 42:
==Relationship with linear equations==
[[Image:wiki linearna funkcija eks1.png|thumb|right]]<!-- are PNG and a translit from a foreign language necessary? -->
Linear functions commonly arise from practical problems involving variables <math>x,y</math> with a linear relationship, that is, obeying a [[linear equation]] <math>Ax+By=C</math>. If <math>B\neq 0</math>, one can solve this equation for ''y'', obtaining
The points on a line have coordinates which can also be thought of as the solutions of [[linear equation]]s in two variables (the equation of the line). These solution sets define functions which are linear functions. This connection between linear equations and linear functions provides the most common way to produce linear functions.
:<math>y = -\tfrac{A}{B}x +\tfrac{C}{B}=ax+b,</math>
where we denote <math>a=-\tfrac{A}{B}</math> and <math>b=\tfrac{C}{B}</math>. That is, one may consider ''y'' as a dependent variable (output) obtained from the independent variable (input) ''x'' via a linear function: <math>y = f(x) = ax+b</math>. In the ''xy''-coordinate plane, the possible values of <math>(x,y)</math> form a line, the graph of the function <math>f(x)</math>. If <math>B=0</math> in the original equation, the resulting line <math>x=\tfrac{C}{A}</math> is vertical, and cannot be written as <math>y=f(x)</math>.
 
The features of the graph <math>y = f(x) = ax+b</math> can be interpreted in terms of the variables ''x'' and ''y''. The ''y''-intercept is the intial value <math>y=f(0)=b</math> at <math>x=0</math>. The slope ''a'' measures the rate of change of the output ''y'' per unit change in the input ''x''. In the graph, moving one unit to the right (increasing ''x'' by 1) moves the ''y''-value up by ''a'': that is, <math>f(x{+}1) = f(x) + a</math>. Negative slope ''a'' indicates a decrease in ''y'' for each increase in ''x''.
The [[equation]] {{math|1=''y'' = ''ax'' + ''b''}} is referred to as the slope-intercept form of a linear equation. In this form, the variable is {{mvar|x}}, and {{mvar|y}}, is the value of the function. It also has two coefficients, {{mvar|a}} and {{mvar|b}}. In this instance, the fact that the values of {{mvar|y}} depend on the values of {{mvar|x}} is an expression of the functional relationship between them. To be very explicit, the linear equation is expressing the equality of values of the dependent variable {{mvar|y}} with the functional values of the linear function {{math|1=''f''(''x'') = ''ax'' + ''b''}}, in other words {{math|1=''y'' = ''f''(''x'')}} for this particular linear function&nbsp;{{mvar|f}}.
 
For example, the linear function <math>y = -2x + 4</math> has slope <math>a=-2</math>, ''y''-intercept point <math>(0,b)=(0,4)</math>, and ''x''-intercept point <math>(2,0)</math>.
If the linear function {{mvar|f}} is given, the linear equation of the graph of this function is obtained by ''defining'' the variable {{mvar|y}} to be the functional value {{math|''f''(''x'')}}, that is, setting {{math|1=''y'' = ''f''(''x'') = ''ax'' + ''b''}} and suppressing the functional notation in the middle. Starting with a linear equation, one can create linear functions, but this is a more subtle operation and must be done with care. Why this is so is not immediately apparent when the linear equation has the slope-intercept form, so this discussion will be postponed. For the moment observe that if the linear equation has the slope-intercept form, then the expression that the dependent variable {{mvar|y}} is equal to is the linear function whose graph is the line satisfying the linear equation.
 
===Example===
The constant {{mvar|b}} is the so-called {{mvar|y}}-intercept. It is the {{mvar|y}}-value at which the line intersects the {{mvar|y}}-axis. The coefficient {{mvar|a}} is the [[slope]] of the line. This measures of the rate of change of the linear function associated with the line. Since {{mvar|a}} is a constant, this rate of change is constant. Moving from any point on the line to the right by one unit (that is, increasing {{mvar|x}} by 1), the {{mvar|y}}-value of the point's coordinate changes by {{mvar|a}}. This is expressed functionally by the statement that {{math|1=''f''(''x'' + 1) = ''f''(''x'') + ''a''}} when {{math|1=''f''(''x'') = ''ax'' + ''b''}}.
Suppose salami and sausage cost &euro;6 and &euro;3 per kilogram, and we wish to buy &euro;12 worth. How much of each can we purchase? Letting ''x'' and ''y'' be the weights of salami and sausage, the total cost is: <math>6x + 3y = 12</math>. Solving for ''y'' gives the point-slope form <math>y = -2x + 4</math>, as above. That is, if we first choose the amount of salami ''x'', the amount of sausage can be computed as a function <math>y = f(x) = -2x + 4</math>. Since salami is twice as expensive as sausage, adding one kilo of salami decreases the sausage by 2 kilos: <math>f(x{+}1) = f(x) - 2</math>, and the slope is &minus;2. The ''y''-intercept point <math>(x,y)=(0,4)</math> corresponds to buying only 4kg of sausage; while the ''x''-intercept point <math>(x,y)=(2,0)</math> corresponds to buying only 2kg of salami.
 
Note that we could instead have chosen ''y'' as the independent variable, and computed ''x'' as a linear function of it: <math>x = -\tfrac12 y +4</math>. Also, the graph includes points with negative values of ''x'' or ''y'', which have no meaning in terms of the original variables (unless we imagine selling meat to the butcher). Thus we should restrict our function to the ___domain <math>0\le x\le 2</math> (or <math>0\le y\le 4</math>).
For example, the slope-intercept form {{math|1=''y'' = −2''x'' + 4}} has {{math|1=''a'' = −2}} and {{math|1=''b'' = 4}}. The point {{math|1=(0, ''b'') = (0, 4)}} is the intersection of the line and the {{mvar|y}}-axis, the point {{math|1=({{sfrac|−''b''|''a''}}, 0) =}} {{math|1=({{sfrac|−4|−2}}, 0) = (2, 0)}} is the intersection of the line and the {{mvar|x}}-axis, and {{math|1=''a'' = −2}} is the slope of the line. For every step to the right ({{mvar|x}} increases by 1), the value of {{mvar|y}} changes by −2 (goes down).
 
[[Image:wiki linearna funkcija stand1.png|180px|right]]
If the linear equation in the general form
:{{math|1=''Ax'' + ''By'' = C|size=120%}}.
has {{math|''B'' ≠ 0}}, then it may be solved for the variable {{mvar|y}} and thus used to define a linear function, namely, {{math|1=''y'' = −({{sfrac|''A''|''B''}})''x'' + ({{sfrac|''C''|''B''}}) = ''f''(''x'')}}. While all lines have equations in the general form, only the non-vertical lines have equations which can give rise to linear functions.
 
== Relationship with other classes of functions ==