Linearity Analyzer
Analyze sensor transfer-curve linearity with adjustable non-linearity and knee point. View transfer function and residual plots side by side.
Linearity Analyzer
Analyze sensor response linearity. Visualize the input-output transfer curve, deviation from ideal, and maximum non-linearity.
Transfer Curve
Residual (Deviation)
Model scope
Use this browser tool for intuition, relative trends, and design-space exploration. Its local simplified model is not a substitute for RCWA/FDTD sign-off, silicon calibration, or vendor process data.
Learn more
Transfer-Curve Linearity
An ideal sensor doubles its output when the light doubles — a perfectly straight line on a chart. Real sensors curve slightly, especially near saturation, and that curvature breaks precise photometry, HDR stitching, and colour correction. Linearity analysis hunts for the curvature using the residual between measured points and a fitted straight line.
Linearity measures how closely output code follows input exposure before saturation or knee compression.
Assumptions
- The transfer curve is compared against a fitted straight line over a selected valid exposure range.
- Residuals represent compact nonlinearity; ADC code transition details and column gain errors are not separately solved.
- Illumination, temperature, and timing are assumed stable across the measurement sequence.
Outputs
- Measured/fitted transfer curve, residual plot, INL proxy, usable range, saturation or knee-compression warning.
- A calibration view of whether nonlinearity is small enough for photometry, color correction, or HDR merging.
Validation Example
- For an ideal linear response, residuals should stay near zero until saturation or intentional knee compression.
- Including saturated samples in the fit should distort the fitted slope and make low-signal residuals misleading.
Core Equations
- \(g\): Slope (gain)
- \(X\): Input signal
A linear sensor has constant slope over the usable exposure range.
- \(Y_{\text{meas}}\): Measured digital value
Residual plots reveal curvature that is hidden in the main transfer curve.
- \(INL\): Integral Non-Linearity
INL normalizes the worst deviation by full-scale output.
Model Interpretation
- Knee compression extends highlight range at the cost of linear radiometry.
- Linearity errors affect photometry, color correction, HDR merge, and calibration.
- Real measurements need black-level subtraction and stable illumination.
Residual Interpretation
- A smooth residual curve indicates transfer nonlinearity; alternating residuals can indicate measurement noise or flicker.
- Near saturation, residuals often grow before hard clipping appears.
- Use a defined fit range; including the knee region can hide low-signal linearity.
Calibration Impact
- Color correction assumes linear channel ratios; nonlinearity changes those ratios with exposure.
- HDR merge needs a known transfer function to align short and long exposures.
- Photometry and scientific imaging require tighter linearity than consumer tone-mapped imaging.
Known Missing Physics
- The compact analyzer does not model ADC code transitions, column gain errors, or source-follower compression separately.
- It does not include temperature drift, illumination drift, or exposure timing error during measurement.
- Piecewise HDR and dual-gain sensors require multiple transfer curves, not one global line.