To multiply a function by a
scalar, multiply each
output by that scalar. For example, if
*f* (*x*) = 4*x* - 1
, then
*f* (*x*) = (4*x* - 1) = 2*x* -
. If
*g*(*x*) = *x* - 2
, then
3*g*(*x*) = 3(*x* - 2) = 3*x* - 6
. If
*h*(*x*) = *x*
^{2} + 2
, then
-2*h*(*x*) = - 2(*x*
^{2} +2) = - 2*x*
^{2} - 4
.
(3*x*)*h*(*x*) = (3*x*)(*x*
^{2} +2) = 3*x*
^{3} + 6*x*
.

Scalar Multiplication

The

To multiply a function by another function, multiply their outputs. For
example, if
*f* (*x*) = 2*x*
and
*g*(*x*) = *x* + 1
, then
*fg*(3) = *f* (3)×*g*(3) = 6×4 = 24
.
*fg*(*x*) = 2*x*(*x* + 1) = 2*x*
^{2} + *x*
.

When we take
*f* (*g*(*x*))
, we take
*g*(*x*)
as the input of the function
*f*
. In
other words, we take
*x*
as the input of
*g*
and evaluate
*g*(*x*)
, and then we
take this result as the input of
*f*
and evaluate
*f* (*g*(*x*))
.

For example, if
*f* (*x*) = 10*x*
and
*g*(*x*) = *x* + 1
, then to find
*f* (*g*(4))
, we find
*g*(4) = 4 + 1 + 5
, and then evaluate
*f* (5) = 10(5) = 50
. Similarly,
*f* (*g*(12)) = *f* (12 + 1) = *f* (13) = 10(13) = 130
. In general,
*f* (*g*(*x*)) = *f* (*x* + 1) = 10(*x* + 1) = 10*x* + 10
.

*Example*:
*f* (*x*) = 2*x* - 2
,
*g*(*x*) = *x*
^{2} - 8
.

*f* (*g*(3)) = *f* (3^{2} - 8) = *f* (1) = 0
.

*f* (*g*(- 4)) = *f* ((- 4)^{2} - 8) = *f* (8) = 2(8) - 2 = 14
.

In general,
*f* (*g*(*x*)) = *f* (*x*
^{2} -8) = 2(*x*
^{2} -8) - 2 = 2*x*
^{2} - 18
.

*g*(*f* (3)) = *g*(2(3) - 2) = *g*(4) = 4^{2} - 8 = 8
.

*g*(*f* (- 4)) = *g*(2(- 4) - 2) = *g*(- 10) = (- 10)^{2} - 8 = 92
.

In general,
*g*(*f* (*x*)) = *g*(2*x* - 2) = (2*x* - 2)^{2} -8 = 4*x*
^{2} - 8*x* - 4
.

*f* (*g*(*x*))
is denoted
*f*
o
*g*(*x*)
and
*g*(*f* (*x*))
is denoted
*g*
o
*f* (*x*)
.
Note that it is not necessarily true that
*f*
o
*g*(*x*) = *g*
o
*f* (*x*)
, as
shown in the above example.