◀ Back to Note

Tony's Intertwingled Memex • Reference Manual

Differentials and Error Propagation

Formulas & Definitions
Core Definition

For a differentiable function z=f(x,y)z = f(x, y)z=f(x,y), let dx=Δxdx = \Delta xdx=Δx and dy=Δydy = \Delta ydy=Δy represent small independent changes (differentials) in the input variables. The total differential dzdzdz (or dfdfdf) is defined as:

  1. Total Differential Equation:
    dz=∂f∂xdx+∂f∂ydy=fx(x,y)dx+fy(x,y)dydz = \frac{\partial f}{\partial x} dx + \frac{\partial f}{\partial y} dy = f_x(x, y) dx + f_y(x, y) dydz=∂x∂f​dx+∂y∂f​dy=fx​(x,y)dx+fy​(x,y)dy
  2. Increment Approximation:
    Δz=f(x+Δx,y+Δy)−f(x,y)≈dz\Delta z = f(x + \Delta x, y + \Delta y) - f(x, y) \approx dzΔz=f(x+Δx,y+Δy)−f(x,y)≈dz
  3. Maximum Absolute Error Bound:
    ∣Δz∣≲∣dz∣max⁡=∣∂f∂x∣∣dx∣+∣∂f∂y∣∣dy∣|\Delta z| \lesssim |dz|_{\max} = \left|\frac{\partial f}{\partial x}\right| |dx| + \left|\frac{\partial f}{\partial y}\right| |dy|∣Δz∣≲∣dz∣max​=​∂x∂f​​∣dx∣+​∂y∂f​​∣dy∣
  4. Relative and Percentage Error:
    Relative Error=dzz,Percentage Error=dzz×100%\text{Relative Error} = \frac{dz}{z}, \quad \text{Percentage Error} = \frac{dz}{z} \times 100\%Relative Error=zdz​,Percentage Error=zdz​×100%

Concept Explanation

Geometric Distinction: Δz\Delta zΔz versus dzdzdz

Understanding the fundamental difference between the true increment Δz\Delta zΔz and the differential dzdzdz is essential in engineering error analysis:

  • Δz\Delta zΔz (True Increment): The actual vertical change in height measured directly along the curved surface z=f(x,y)z = f(x, y)z=f(x,y) as the input moves from (x0,y0)(x_0, y_0)(x0​,y0​) to (x0+Δx,y0+Δy)(x_0 + \Delta x, y_0 + \Delta y)(x0​+Δx,y0​+Δy).
  • dzdzdz (Total Differential): The vertical change in height measured along the flat tangent plane at (x0,y0)(x_0, y_0)(x0​,y0​).

Because the tangent plane is the best linear approximation to the surface, dzdzdz closely tracks Δz\Delta zΔz for small variations in dxdxdx and dydydy. As dx,dy→0dx, dy \to 0dx,dy→0, the discrepancy between Δz\Delta zΔz and dzdzdz shrinks faster than the distance (Δx)2+(Δy)2\sqrt{(\Delta x)^2 + (\Delta y)^2}(Δx)2+(Δy)2​.

             ^ z
             |                     . True Surface point (z + \Delta z)
             |                    /
             |                   /|  \Delta z (True change)
             |      dz          / |
             |   +-------------+  |
             |  /|             |  |
             | / | dz          |  . Tangent plane point (z + dz)
             |/  |             | /
             +---|-------------+/--------------> y
             |   (x_0, y_0)    (x_0 + dx, y_0 + dy)
             v x

Physical Sensitivity and Sensitivity Coefficients

In engineering systems, output performance zzz depends on several independently measured inputs (x,y)(x, y)(x,y). The partial derivatives in the total differential formula act as sensitivity coefficients:

dz=(∂f∂x)⏟Sensitivity to xdx+(∂f∂y)⏟Sensitivity to ydydz = \underbrace{\left(\frac{\partial f}{\partial x}\right)}_{\text{Sensitivity to } x} dx + \underbrace{\left(\frac{\partial f}{\partial y}\right)}_{\text{Sensitivity to } y} dydz=Sensitivity to x(∂x∂f​)​​dx+Sensitivity to y(∂y∂f​)​​dy

A large magnitude for ∣∂f∂x∣|\frac{\partial f}{\partial x}|∣∂x∂f​∣ indicates that the system is hypersensitive to small perturbations or measurement errors in xxx. Conversely, a small value indicates robustness against fluctuations in that variable. Engineers use this sensitivity weighting to decide where to invest in expensive high-precision instrumentation versus where cheaper sensors suffice.

Worst-Case Error Bounds (The Triangle Inequality)

When instruments measure physical parameters xxx and yyy with known manufacturing tolerances or measurement uncertainties ∣dx∣≤δx|dx| \le \delta_x∣dx∣≤δx​ and ∣dy∣≤δy|dy| \le \delta_y∣dy∣≤δy​, the errors can have either positive or negative signs. In safety-critical engineering, we calculate the worst-case maximum absolute error by applying the Triangle Inequality, assuming the errors reinforce each other constructively:

∣dz∣=∣fxdx+fydy∣≤∣fx∣∣dx∣+∣fy∣∣dy∣≤∣fx∣δx+∣fy∣δy|dz| = \left|f_x dx + f_y dy\right| \le |f_x| |dx| + |f_y| |dy| \le |f_x| \delta_x + |f_y| \delta_y∣dz∣=∣fx​dx+fy​dy∣≤∣fx​∣∣dx∣+∣fy​∣∣dy∣≤∣fx​∣δx​+∣fy​∣δy​

Extension to Three or More Variables

For a system governed by nnn variables w=f(x1,x2,…,xn)w = f(x_1, x_2, \dots, x_n)w=f(x1​,x2​,…,xn​):

dw=∑i=1n∂f∂xidxi=∂f∂x1dx1+∂f∂x2dx2+⋯+∂f∂xndxndw = \sum_{i=1}^n \frac{\partial f}{\partial x_i} dx_i = \frac{\partial f}{\partial x_1} dx_1 + \frac{\partial f}{\partial x_2} dx_2 + \dots + \frac{\partial f}{\partial x_n} dx_ndw=i=1∑n​∂xi​∂f​dxi​=∂x1​∂f​dx1​+∂x2​∂f​dx2​+⋯+∂xn​∂f​dxn​
∣dw∣max⁡≤∑i=1n∣∂f∂xi∣δxi|dw|_{\max} \le \sum_{i=1}^n \left|\frac{\partial f}{\partial x_i}\right| \delta_{x_i}∣dw∣max​≤i=1∑n​​∂xi​∂f​​δxi​​


Engineering Applications

  • Manufacturing Quality Assurance (QA/QC): Establishing dimensional tolerances on machined shafts, bolt diameters, and housing bores so that assembled clearances remain within safe operational limits.
  • Electrical Circuit Tolerance Analysis: Computing the total uncertainty in electrical power dissipation P=I2RP = I^2 RP=I2R or resonant frequency ω=1LC\omega = \frac{1}{\sqrt{LC}}ω=LC​1​ resulting from component manufacturing tolerances (±5%\pm 5\%±5% resistors and capacitors).
  • Civil & Geotechnical Surveying: Propagating measurement inaccuracies from laser total stations (angle and distance errors) into computed boundary land areas and building foundation elevations.
  • Fluid Mechanics & Pipeline Metering: Calculating the propagated uncertainty in volumetric flow rate Q=πD4ΔP128μLQ = \frac{\pi D^4 \Delta P}{128 \mu L}Q=128μLπD4ΔP​ (Hagen-Poiseuille equation) caused by pipe diameter manufacturing variations.

Example Problems

Example 1: Cylindrical Storage Tank Error Propagation

The volume of a cylindrical fluid storage tank is given by V(r,h)=πr2hV(r, h) = \pi r^2 hV(r,h)=πr2h. The radius is measured as r=2.0 mr = 2.0\text{ m}r=2.0 m with an uncertainty of ±0.02 m\pm 0.02\text{ m}±0.02 m, and height is measured as h=5.0 mh = 5.0\text{ m}h=5.0 m with an uncertainty of ±0.05 m\pm 0.05\text{ m}±0.05 m.

  1. Compute the total differential dVdVdV.
  2. Estimate the maximum absolute error in the calculated volume.
  3. Determine the relative error dVV\frac{dV}{V}VdV​ and percentage error.
Solution
  1. Compute Partial Derivatives:
    ∂V∂r=2πrh,∂V∂h=πr2\frac{\partial V}{\partial r} = 2\pi r h, \quad \frac{\partial V}{\partial h} = \pi r^2∂r∂V​=2πrh,∂h∂V​=πr2
    State the Total Differential Equation:
    dV=∂V∂rdr+∂V∂hdh=2πrh dr+πr2 dhdV = \frac{\partial V}{\partial r} dr + \frac{\partial V}{\partial h} dh = 2\pi r h \, dr + \pi r^2 \, dhdV=∂r∂V​dr+∂h∂V​dh=2πrhdr+πr2dh
  2. Estimate Maximum Absolute Error at (r,h)=(2.0,5.0)(r, h) = (2.0, 5.0)(r,h)=(2.0,5.0):
    ∂V∂r(2,5)=2π(2.0)(5.0)=20π\frac{\partial V}{\partial r}(2, 5) = 2\pi(2.0)(5.0) = 20\pi∂r∂V​(2,5)=2π(2.0)(5.0)=20π
    ∂V∂h(2,5)=π(2.0)2=4π\frac{\partial V}{\partial h}(2, 5) = \pi(2.0)^2 = 4\pi∂h∂V​(2,5)=π(2.0)2=4π
    Applying worst-case tolerances ∣dr∣≤0.02 m|dr| \le 0.02\text{ m}∣dr∣≤0.02 m and ∣dh∣≤0.05 m|dh| \le 0.05\text{ m}∣dh∣≤0.05 m:
    ∣dV∣max⁡≤∣20π∣(0.02)+∣4π∣(0.05)=0.40π+0.20π=0.60π≈1.885 m3|dV|_{\max} \le |20\pi|(0.02) + |4\pi|(0.05) = 0.40\pi + 0.20\pi = 0.60\pi \approx 1.885\text{ m}^3∣dV∣max​≤∣20π∣(0.02)+∣4π∣(0.05)=0.40π+0.20π=0.60π≈1.885 m3
  3. Compute Relative and Percentage Error: Nominal volume: V(2,5)=π(2.0)2(5.0)=20π m3≈62.83 m3V(2, 5) = \pi(2.0)^2(5.0) = 20\pi\text{ m}^3 \approx 62.83\text{ m}^3V(2,5)=π(2.0)2(5.0)=20π m3≈62.83 m3.
    Relative Error=dVV=2πrh dr+πr2 dhπr2h=2drr+dhh\text{Relative Error} = \frac{dV}{V} = \frac{2\pi r h \, dr + \pi r^2 \, dh}{\pi r^2 h} = 2\frac{dr}{r} + \frac{dh}{h}Relative Error=VdV​=πr2h2πrhdr+πr2dh​=2rdr​+hdh​
    dVV=2(0.022.0)+(0.055.0)=2(0.01)+0.01=0.02+0.01=0.030\frac{dV}{V} = 2\left(\frac{0.02}{2.0}\right) + \left(\frac{0.05}{5.0}\right) = 2(0.01) + 0.01 = 0.02 + 0.01 = 0.030VdV​=2(2.00.02​)+(5.00.05​)=2(0.01)+0.01=0.02+0.01=0.030
    Percentage Error=0.030×100%=3.0%\text{Percentage Error} = 0.030 \times 100\% = 3.0\%Percentage Error=0.030×100%=3.0%
    Engineering Takeaway: Notice that radius contributes twice as much relative error as height (2drr2 \frac{dr}{r}2rdr​ vs dhh\frac{dh}{h}hdh​) because radius is squared in the volume equation.

Example 2: Kinetic Energy Sensitivity in Mechanical Vehicles

The kinetic energy of a moving drone is K(m,v)=12mv2K(m, v) = \frac{1}{2} m v^2K(m,v)=21​mv2. A drone's mass is measured as m=4.0 kgm = 4.0\text{ kg}m=4.0 kg with an uncertainty of ±0.1 kg\pm 0.1\text{ kg}±0.1 kg, and its velocity is measured as v=10.0 m/sv = 10.0\text{ m/s}v=10.0 m/s with an uncertainty of ±0.2 m/s\pm 0.2\text{ m/s}±0.2 m/s. Estimate the percentage uncertainty in kinetic energy.

Solution
  1. Compute Total Differential:
    dK=∂K∂mdm+∂K∂vdv=(12v2)dm+(mv)dvdK = \frac{\partial K}{\partial m} dm + \frac{\partial K}{\partial v} dv = \left(\frac{1}{2}v^2\right) dm + (mv) dvdK=∂m∂K​dm+∂v∂K​dv=(21​v2)dm+(mv)dv
  2. Formulate Relative Error:
    dKK=12v2dm+mvdv12mv2=dmm+2dvv\frac{dK}{K} = \frac{\frac{1}{2}v^2 dm + mv dv}{\frac{1}{2}mv^2} = \frac{dm}{m} + 2\frac{dv}{v}KdK​=21​mv221​v2dm+mvdv​=mdm​+2vdv​
  3. Substitute Relative Uncertainties:
    dmm=0.14.0=0.025(2.5%)\frac{dm}{m} = \frac{0.1}{4.0} = 0.025 \quad (2.5\%)mdm​=4.00.1​=0.025(2.5%)
    dvv=0.210.0=0.020(2.0%)\frac{dv}{v} = \frac{0.2}{10.0} = 0.020 \quad (2.0\%)vdv​=10.00.2​=0.020(2.0%)
    dKK=0.025+2(0.020)=0.025+0.040=0.065  ⟹  6.5%\frac{dK}{K} = 0.025 + 2(0.020) = 0.025 + 0.040 = 0.065 \implies 6.5\%KdK​=0.025+2(0.020)=0.025+0.040=0.065⟹6.5%
    The maximum uncertainty in the calculated kinetic energy is approximately ±6.5%\pm 6.5\%±6.5%.

Connections & References

  • Parent Concepts: Linear Approximations | Partial Derivatives
  • Related Notes: Tangent Planes | Equations of Planes in 3D | Multivariable Chain Rule
  • Course Sessions: Calc-3 Session 10, Calc-3 Session 11