Learn

Learning preferences

Make learning more comfortable. Changes apply immediately.

Enlarges page content, including diagrams and their labels. You can also use your browser’s zoom.

Choose the colours that are easiest for you to distinguish. Applies to lesson diagrams and lab plots. Labels, shapes, hatching and line patterns also distinguish meanings. Source photographs and raw image brightness stay unchanged; mask-only views are available for image overlays.

ExampleComparisonSample link

Saved in this browser on this device. Preferences are separate from progress backups.

Lesson 2 of 3

Construct and validate logarithmic responses

Fit a log-input response and distinguish its original-scale residual evidence from other transformations.

Loading your saved responses…

Try the optional starting-point checks and targeted refreshers. You can continue directly into this lesson.

Try

A synthetic sensor experiment compares a positive input with a fixed reference input. Write x=input/reference, so x is a dimensionless ratio, and let y be a response in sensor units. The reference makes taking a logarithm meaningful: changing the physical input unit does not change this ratio.

Suppose an ideal model says every doubling of x adds the same amount to y. Begin with two exact pairs: (1,2) and (4,8). Moving from 1 to 4 takes two doublings and raises the response by 6. Each doubling therefore adds 3 sensor units, giving the candidate y=2+3 log₂x. Here log₂x is the exponent to which 2 must be raised to obtain x. The model requires x>0.

Input ratio xlog₂xIdeal response
1/2−1−1
102
215
428
8311

Sketch these points on ordinary, equally spaced x axes. Their horizontal separations grow while each output step stays 3. A straight line through the table’s row numbers would misrepresent those input distances. A negative modeled output is not inherently invalid for a signed sensor reading, but it would need rejection if the response represented a nonnegative quantity such as mass.

Predict

Now examine noisy, synthetic calibration pairs (1,2.2), (2,4.7), (4,8.1), (8,10.8), (16,14.2). The response gains are 2.5, 3.4, 2.7 and 3.4 over successive doublings, so no single exact gain matches them all. Predict the sign of each residual if you used the ideal rule above. Then predict whether fitting a logarithmic model means transforming x, transforming y, or both.

The intended fit is y=a+b ln x, where ln is the natural logarithm. Only x is transformed. Responses remain on their original scale. This differs from exponential log-linear regression, which fits ln y against x and minimizes a different error criterion. If the response can be negative, logarithmic response fitting remains possible; taking ln y would not.

Experiment

Confirm the five supplied calibration rows in the workbench. Reveal the fit, record its coefficients and original-response sum of squared errors (SSE), then inspect the residual plot and each numerical row. Before checking the fresh response, predict y at x=√8. Use a sufficiently precise decimal input for √8, approximately 2.82842712474619, and retain more digits than the displayed response precision.

Fit a logarithmic response and test a prediction

Predict the direction and curvature before calculating. This tool fits y = a + b ln(x) by minimizing squared errors in the original y values. The seed is synthetic. Here x must be dimensionless, or a ratio such as time divided by a stated reference time; use the surrounding lesson's context and units.

Use 3–40 pairs, 0.000001 ≤ x ≤ 100 and −100 ≤ y ≤ 100. Repeated rows count as observations but are not automatically independent. A logarithmic response transforms x, not y; negative y values are permitted.

Record the model, data, residual pattern and a separate prediction check. Small training SSE does not establish future accuracy or the correct functional family. Calculations use floating-point arithmetic and rounded display values. Data edits clear the old fit and queries; query edits clear only the old query. This temporary workbench saves no answers and awards no mastery.

The fitted equation is ŷ=1.98+3.01 log₂x, equivalently ŷ=1.98+(3.01/ln 2) ln x. The hat means a predicted response. The natural-log coefficient is about 4.342512, not 3.01. Check which base the tool displays before copying a coefficient into an equation.

xFitted responseResidual: observed minus fitted
11.980.22
24.99−0.29
48.000.10
811.01−0.21
1614.020.18

The SSE is 0.22²+0.29²+0.10²+0.21²+0.18²=0.219 squared sensor units. At √8, log₂x=1.5, so the prediction is 1.98+3.01(1.5)=6.495. A separately supplied synthetic check is 6.5, giving residual 0.005. Keep that check out of the fitting rows; appending it would refit the model using the answer.

Understand

The fit is ordinary straight-line least squares in the transformed coordinate u=log₂x. In this dataset u=0,1,2,3,4, with mean 2, while mean y is 8. The sum of (u−2)² is 10; the sum of (u−2)(y−8) is 30.1. Their ratio gives slope 3.01, and the intercept is 8−3.01(2)=1.98. Thus the coefficients come from all five observations rather than choosing two convenient points. The plotted fitted curve is logarithmic in the original x coordinate.

The intercept is the response at x=1, the reference input. The base-two slope is the response change per doubling. Multiplying x by a positive factor k changes the prediction by 3.01 log₂k, independently of the starting input. Increasing x by a fixed additive amount is different: the gain becomes 3.01 log₂(1+h/x) for a positive increment h. As the starting x grows, h/x decreases, so the gain shrinks. This explains the increasing but flattening shape without derivatives.

Inverse prediction solves for the input producing a desired modeled response. With the fitted equation, target y=8 gives log₂x=(8−1.98)/3.01=2, hence x=4. In the natural-log form the same calculation is x=exp((y−a)/b). It requires b≠0. If b=0, the fitted response is constant: its single response corresponds to every admissible input, and other targets have no solution. There is no unique inverse in that case.

A response uncertainty ±δ is not automatically an equal additive uncertainty in x. With positive base-two slope 3.01, response endpoints y−δ and y+δ transform to input endpoints 2^((y−δ−1.98)/3.01) and 2^((y+δ−1.98)/3.01). They are multiplicative factors 2^(±δ/3.01) around the central input. These transformed endpoints propagate the stated response interval under a fixed model; they do not include uncertainty in fitted coefficients or guarantee statistical coverage.

Recognize a shifted input from equal output steps

A logarithmic graph shifted horizontally need not have proportional raw inputs at equal output steps. Reverse the viewpoint: suppose x=s+A bʸ, with A>0 and b>1, and equal output levels y=0,1,2 occur at inputs x₀,x₁,x₂. Then input differences satisfy Δ₁=A(b−1), Δ₂=Ab(b−1). Thus b=Δ₂/Δ₁, A=Δ₁/(b−1), s=x₀−A when these operations and the assumed signs are valid. Constant or non-geometric-compatible data require a separate diagnosis, not division by zero or a forced logarithmic fit.

For inputs 3,5,9 at output levels 0,1,2, the differences 2,4 give b=2, A=2, s=1. The response is y=log₂((x−1)/2), on x>1. Raw ratios 5/3 and 9/5 differ; after subtracting the offset, ratios 4/2 and 8/4 agree. Verify all observations by substitution. The changed practice uses inputs 4,10,28 and a withheld response at 82, requiring a new offset/base calculation and an original-response residual.

A positive residual (observed minus predicted) means underprediction. Whether it is worse than an equally large negative residual depends on the use: underpredicting required capacity can cause a shortage, while overpredicting can waste resources. A comparison should state those costs instead of declaring one residual sign universally preferable. One withheld check is useful evidence but does not establish the true family or every parameter assumption.

Direction and curvature without calculus

For E(x)=A bˣ with b>0, b≠1, the midpoint difference is [E(m+h)+E(m−h)]/2−E(m)=A bᵐ[(bʰ+b⁻ʰ)/2−1]. The bracket is positive for h≠0 because z+1/z−2=(z−1)²/z>0 for z=bʰ≠1. Thus A>0 gives concave up and A<0 gives concave down. The sign of A and whether b is above or below 1 separately determine increase/decrease. No unshifted nonconstant exponential has an interior extremum or a concavity change; translations preserve these conclusions. A horizontal reflection reverses monotonic direction but preserves concavity; a vertical reflection reverses both.

For ln x, geometric mean ≤ arithmetic mean gives (ln u+ln v)/2≤ln((u+v)/2), since ln is increasing. This is midpoint concavity; continuity and repeated bisection give every chord inequality. A positive multiple of ln x is concave down and a negative multiple is concave up. Since log_b x=ln x/ln b, a base below 1 reverses the sign. Horizontal translations keep the actual positive-argument domain and move the vertical asymptote. These arguments explain shape for the whole stated function family rather than infer it from finite samples; endpoint extrema on a restricted domain must still be checked separately.

Graph transformations can also be read directly from the laws: b^(x+h)=bʰbˣ turns an exponential horizontal shift into a vertical scaling, while b^(cx)=(bᶜ)ˣ changes the base. For x>0, log_b(xᵏ)=k log_b x turns an input power into a vertical scaling; its stated positive-input domain must be retained. For any b,c>0 with c≠1, bˣ=c^(x log_c b), since c^(log_c b)=b. These equivalent rules change the representation, not the modeled outputs or the need to check domains.

Apply

Construct a new exact logarithmic response y=A+B log₂x from the pairs (2,7) and (8,3). Predict at x=4, solve the target y=1, and explain the direction of its graph. Then suppose a fresh response at x=4 is 5.3±0.1. Does the exact prediction agree with that declared measurement interval? Keep the construction and the new check separate.

Check the changed response model

The logarithmic inputs are 1 and 3, so B=(3−7)/(3−1)=−2, and A=9. Thus y=9−2 log₂x. At 4 it predicts 5; target 1 requires log₂x=4, giving x=16. The negative coefficient makes the response decrease as positive x increases. The new reading permits [5.2,5.4], excluding 5, so this exact model fails that check. This does not identify whether its family assumption, calibration readings or measurement conditions caused the discrepancy.

For the noisy worked fit, distinguish mathematical domain x>0 from calibration range 1≤x≤16. Its unrestricted predictions tend to −∞ as x approaches zero from above and to +∞ as x grows without bound. Those algebraic limits do not establish sensor behavior outside the tested range. A physically impossible prediction can invalidate a contextual use even when a calculator returns a finite number.

Continue

Retain the raw calibration pairs, the logarithm base, both coefficients, residuals and SSE, a forward prediction, and an inverse prediction with their units and domain. State which observations were actually unused when predictions were made. Reusing the same check to select or revise a model consumes its status as independent evidence.

Use transformed inverses and logarithmic inequalities to justify inverse formulas and domains algebraically. For a refresher on identifying graph landmarks, revisit shifted exponential and logarithmic graphs. This page fits a logarithmic response; a dedicated semilog-axis investigation is a separate representation task.

Apply · explain · revise

Practice and reasoning

Drafts save locally as you type. Reveal worked solutions when useful; the site remembers that exposure. Automatic matches check the requested answer, while written arguments require review against the rubric.

A synthetic response R(x)=a+b log₂(x) has readings R(2)=7 and R(8)=15. Input x is a positive dimensionless concentration ratio and response units are points. Construct the model, predict R(4), and solve for the ratio producing 19 points.

Structure your argument and preserve revisions

These optional planning fields save locally. Recording your response saves an immutable copy of the argument and these fields. Older records may contain only first/latest responses; missing intermediate revisions are not reconstructed.

Each field allows 2,000 characters. Keep a specific claim, state where it applies, cite the facts you use, and explain what still needs checking. Blank fields are allowed and are not evidence of mastery.

Enter training pairs(1,3.1),(2,5.8),(4,9.2),(8,11.9),(16,15.0) into the logarithmic fitting tool. Fit a+b log₂(x), retaining coefficients, residuals and original-response SSE. Predict at x=4√2 before comparing with a fresh reading 10.6. Do not fit on this reading. Numerical answers within 0.002 are acceptable; response units are points.

Structure your argument and preserve revisions

These optional planning fields save locally. Recording your response saves an immutable copy of the argument and these fields. Older records may contain only first/latest responses; missing intermediate revisions are not reconstructed.

Each field allows 2,000 characters. Keep a specific claim, state where it applies, cite the facts you use, and explain what still needs checking. Blank fields are allowed and are not evidence of mastery.

A proposed response is R(x)=5+2 log₃x on x>0. Compare changes across[1,3],[3,9] and[9,27] with changes across[1,2],[2,3]. Explain the graph shape in ordinary language without derivatives.

Structure your argument and preserve revisions

These optional planning fields save locally. Recording your response saves an immutable copy of the argument and these fields. Older records may contain only first/latest responses; missing intermediate revisions are not reconstructed.

Each field allows 2,000 characters. Keep a specific claim, state where it applies, cite the facts you use, and explain what still needs checking. Blank fields are allowed and are not evidence of mastery.

A team proposes L(x)=4−3 ln(x−2) for a positive concentration x measured numerically in an agreed reference unit. A colleague enters x=1,2,3 and expects three real predictions. State the domain, identify valid inputs, and solve L(x)=1. Explain why the logarithm argument must be dimensionless in a physical model.

Structure your argument and preserve revisions

These optional planning fields save locally. Recording your response saves an immutable copy of the argument and these fields. Older records may contain only first/latest responses; missing intermediate revisions are not reconstructed.

Each field allows 2,000 characters. Keep a specific claim, state where it applies, cite the facts you use, and explain what still needs checking. Blank fields are allowed and are not evidence of mastery.

For a log-response candidate, original-scale residuals at three measurements are −2,1,1 points. Another candidate gives −1,−1,1.5 points. Compare their original-response SSEs. Explain why fitting log(response) instead of response would generally solve a different problem, and why negative response values need not invalidate a log-input model.

Structure your argument and preserve revisions

These optional planning fields save locally. Recording your response saves an immutable copy of the argument and these fields. Older records may contain only first/latest responses; missing intermediate revisions are not reconstructed.

Each field allows 2,000 characters. Keep a specific claim, state where it applies, cite the facts you use, and explain what still needs checking. Blank fields are allowed and are not evidence of mastery.

An assumed response law is R(x)=8−2 log₂(x/4) for positive x, a numerical intensity ratio. Determine the intensity giving response 2. Then compare the response at x and 4x and explain whether doubling the response corresponds to doubling the input.

Structure your argument and preserve revisions

These optional planning fields save locally. Recording your response saves an immutable copy of the argument and these fields. Older records may contain only first/latest responses; missing intermediate revisions are not reconstructed.

Each field allows 2,000 characters. Keep a specific claim, state where it applies, cite the facts you use, and explain what still needs checking. Blank fields are allowed and are not evidence of mastery.

An increasing logarithmic response is assumed to have x=s+A b^y with A>0,b>1. Observations (x,y) are (4,0),(10,1),(28,2). Recover s,A,b and write y as a function of x with its full real domain. Predict at x=82 before opening a new response3.1. Give the signed residual, state which side was underestimated, and explain why a capacity planner might penalize this direction more than the opposite error.

Structure your argument and preserve revisions

These optional planning fields save locally. Recording your response saves an immutable copy of the argument and these fields. Older records may contain only first/latest responses; missing intermediate revisions are not reconstructed.

Each field allows 2,000 characters. Keep a specific claim, state where it applies, cite the facts you use, and explain what still needs checking. Blank fields are allowed and are not evidence of mastery.

Reflect and continue

Before marking this lesson complete, explain one key idea without the worked solution and identify a condition that matters. Marking complete records participation, not independent mastery.