The range of the function is all real numbers, or \((-\infty ,\infty )\)

When sketching a general logarithm with base b, it can be helpful to remember that the graph will pass through the points (1, 0) and (b, 1).

To get a feeling for how the base affects the shape of the graph, examine the graphs below.

Notice that the larger the base, the slower the graph grows. For example, the common log graph, while it grows without bound, it does so very slowly. For example, to reach an output of 8, the input must be 100,000,000.

Another important observation made was the domain of the logarithm. Like the reciprocal and square root functions, the logarithm has a restricted domain which must be considered when finding the domain of a composition involving a log.

Example \(\PageIndex{1}\):

Find the domain of the function \(f(x)=\log (5-2x)\).

Solution

The logarithm is only defined with the input is positive, so this function will only be defined when \(5-2x>0\). Solving this inequality, \[\begin{array}{l} {-2x>-5} \\ {x<\frac{5}{2} } \end{array}\]

The domain of this function is \(x<\frac{5}{2}\), or in interval notation, \(\left(-\infty ,\frac{5}{2} \right)\)

Exercise \(\PageIndex{1}\)

Find the domain of the function \(f(x)=\log (x-5)+2\); before solving this as an inequality, consider how the function has been transformed.

Answer

Add answer text here and it will automatically be hidden if you have a "AutoNum" template active on the page.

Transformations of the Logarithmic FunctionLogarithmic Functions:Transformations of the Logarithmic Function

Transformations can be applied to a logarithmic function using the basic transformation techniques, but as with exponential functions, several transformations result in interesting relationships.

From this, we can see that \(\log _{b} x\) is a vertical stretch or compression of the graph of the \(\log _{c} x\) graph. This tells us that a vertical stretch or compression is equivalent to a change of base. For this reason, we typically represent all graphs of logarithmic functions in terms of the common or natural log functions.

Next, consider the effect of a horizontal compression on the graph of a logarithmic function. Considering \(f(x)=\log (cx)\), we can use the sum property to see \[f(x)=\log (cx)=\log (c)+\log (x)\]

Since log(c) is a constant, the effect of a horizontal compression is the same as the effect of a vertical shift.

Example \(\PageIndex{2}\)

Sketch \(f(x)=\ln (x)\) and \(g(x)=\ln (x)+2\).

Graphing these,

Note that this vertical shift could also be written as a horizontal compression, since \[g(x)=\ln (x)+2=\ln (x)+\ln (e^{2} )=\ln (e^{2} x).\]

While a horizontal stretch or compression can be written as a vertical shift, a horizontal reflection is unique and separate from vertical shifting.

Finally, we will consider the effect of a horizontal shift on the graph of a logarithm.

Example \(\PageIndex{3}\):

Sketch a graph of \(f(x)=\ln (x+2)\).

Solution

This is a horizontal shift to the left by 2 units. Notice that none of our logarithm rules allow us rewrite this in another form, so the effect of this transformation is unique. Shifting the graph,

Notice that due to the horizontal shift, the vertical asymptote shifted to x = -2, and the domain shifted to \((-2,\infty )\).

Combining these transformations,

Example \(\PageIndex{4}\):

Add text here. For the automatic number to work, you need to add the "AutoNum" template (preferably at the end) to the page.

Exercise \(\PageIndex{2}\)

Sketch a graph of the function \(f(x)=-3\log (x-2)+1\).

Answer

Add answer text here and it will automatically be hidden if you have a "AutoNum" template active on the page.

This graph has a vertical asymptote at x = –2 and has been vertically reflected. We do not know yet the vertical shift (equivalent to horizontal stretch) or the vertical stretch (equivalent to a change of base). We know so far that the equation will have form \[f(x)=-a\log (x+2)+k\]

Notice that on the log scale above Example 8, the visual distance on the scale between points A and B and between C and D is the same. When looking at the values these points correspond to, notice B is ten times the value of A, and D is ten times the value of C. A visual linear difference between points corresponds to a relative (ratio) change between the corresponding values.

Logarithms are useful for showing these relative changes. For example, comparing $1,000,000 to $10,000, the first is 100 times larger than the second. \[\frac{1,000,000}{10,000} =100=10^{2}\]

Likewise, comparing $1000 to $10, the first is 100 times larger than the second. \[\frac{1,000}{10} =100=10^{2}\]

When one quantity is roughly ten times larger than another, we say it is one order of magnitude larger. In both cases described above, the first number was two orders of magnitude larger than the second.

Notice that the order of magnitude can be found as the common logarithm of the ratio of the quantities. On the log scale above, B is one order of magnitude larger than A, and D is one order of magnitude larger than C.

Orders of Magnitude

Given two values A and B, to determine how many orders of magnitudeOrders of MagnitudeLogarithmic Functions:Orders of Magnitude A is greater than B,

Add text here. For the automatic number to work, you need to add the "AutoNum" template (preferably at the end) to the page.

10

On the log scale above Example 8, how many orders of magnitude larger is C than B?

The value B corresponds to \(10^{2} =100\)

The value C corresponds to \(10^{5} =100,000\)

The relative change is \(\frac{100,000}{100} =1000=\frac{10^{5} }{10^{2} } =10^{3}\). The log of this value is 3.

C is three orders of magnitude greater than B, which can be seen on the log scale by the visual difference between the points on the scale.

Exercise \(\PageIndex{1}\)

Add exercises text here. For the automatic number to work, you need to add the "AutoNum" template (preferably at the end) to the page.

Answer

Add answer text here and it will automatically be hidden if you have a "AutoNum" template active on the page.

6. Using the table from Try it Now #5, what is the difference of order of magnitude between the softest sound a human can hear and the launching of the space shuttle?

Earthquakes

An example of a logarithmic scale is the Moment Magnitude Scale (MMS) used for earthquakes. This scale is commonly and mistakenly called the Richter Scale, which was a very similar scale succeeded by the MMS.

Moment Magnitude Scale

Moment Magnitude ScaleLogarithmic Functions:Moment Magnitude ScaleFor an earthquake with seismic moment S, a measurement of earth movement, the MMS value, or magnitude of the earthquake, is \[M=\frac{2}{3} \log \left(\frac{S}{S_{0} } \right)\] Where \(S_{0} =10^{16}\) is a baseline measure for the seismic moment.

Example \(\PageIndex{1}\):

Add text here. For the automatic number to work, you need to add the "AutoNum" template (preferably at the end) to the page.

11

If one earthquake has a MMS magnitude of 6.0, and another has a magnitude of 8.0, how much more powerful (in terms of earth movement) is the second earthquake?

Since the first earthquake has magnitude 6.0, we can find the amount of earth movement for that quake, which we’ll denote S\({}_{1}\). The value of S\({}_{0}\) is not particularly relevant, so we will not replace it with its value. \[6.0=\frac{2}{3} \log \left(\frac{S_{1} }{S_{0} } \right)\]\[6.0\left(\frac{3}{2} \right)=\log \left(\frac{S_{1} }{S_{0} } \right)\]\[9=\log \left(\frac{S_{1} }{S_{0} } \right)\]\[\frac{S_{1} }{S_{0} } =10^{9}\]\[S_{1} =10^{9} S_{0}\]

This tells us the first earthquake has about 10\({}^{9}\) times more earth movement than the baseline measure.

Doing the same with the second earthquake, S\({}_{2}\), with a magnitude of 8.0, \[8.0=\frac{2}{3} \log \left(\frac{S_{2} }{S_{0} } \right)\]\[S_{2} =10^{12} S_{0}\]

6. \(\frac{2x10^{9} }{2x10^{1} } =10^{8}\). The sound pressure in µPa created by launching the space shuttle is 8 orders of magnitude greater than the sound pressure in µPa created by the softest sound a human ear can hear.

The LibreTexts libraries are Powered by MindTouch®and are supported by the Department of Education Open Textbook Pilot Project, the UC Davis Office of the Provost, the UC Davis Library, the California State University Affordable Learning Solutions Program, and Merlot. We also acknowledge previous National Science Foundation support under grant numbers 1246120, 1525057, and 1413739. Unless otherwise noted, LibreTexts content is licensed by CC BY-NC-SA 3.0. Have questions or comments? For more information contact us at info@libretexts.org or check out our status page at https://status.libretexts.org.