ELEC · Practical Guide 08 — Run a linear fit and inspect the residuals
Fit a line to six unweighted nitrogen observations at 0 rpm. Inspect the statistical assumptions and use residuals to assess the descriptive fit.
ELEC project · Practical GX-TXT guide 8 of 16.
Reproduction target: GX-TXT DEV112-P013. The original screenshots and recorded results document the historical ELEC session. A rerun on P013 has yet to be verified.
Module: Curve Fitter
Learning objective: Run a linear fit and read residuals
Prerequisites / input: Six unweighted 0 rpm N centres
Expected output: Accepted descriptive fit and residual inspection
Scientific background and reference results
Linear fitting is an initial exercise in choosing a source, model and interval before using richer models. It is descriptive and does not demonstrate a linear chemical process.
Step-by-step procedure
- Open Dataset Curve Fit 0.46.2 in the Session copy. In the Dataset panel choose
hal_fig3a_0rpm_six_interior_unweighted.measurement_1.curves, X Time (min) and Y Reported ammonia response (N basis); press Add Dataset curve and verify six centres. - Select orientation Y = f(X), model
linear, Fit pointsalland Output domainsource. Under Fit → Measurements and uncertainty → Input translation / shift positive disable both translations. Under Statistical assumptions and intervals select Unspecified — no interval claim, No measurement weighting, No measurement column and No response interval. - Press Preview fit. Compare points with the estimated line and check that the interval matches actual times rather than extrapolating beyond the data.


- Open Residuals and look for systematic structure as well as a summary goodness-of-fit measure. Examine Parameters & Statistics together with axis units and the limited point count.
- If the configuration matches the purpose, use Fit → Accept fit (F6), select its row under Accepted fits and choose Results → Publish accepted Dataset… with a new ID. Historical Dataset is
hal_fig3a_0rpm_global_six_unweighted_linear_fit; save using Workspace → Save; retain the source and settings to reconstruct the comparison.

Digitized centres do not automatically include experimental uncertainties. Describe an unweighted fit accordingly; future P013 reproduction is NOT_RUN.
Working materials
Figure 3 digitized datasets (CSV) · Model and constraint datasets (CSV)
Other steps of this project
- ELEC 02 — Model hierarchy: effective kinetics, transfer and identifiability
- ELEC 03 — From fits to constraints: what does the chlorine balance reveal?
- ELEC 01 — What does the experiment measure? Nitrogen, chlorine and pH
- ELEC 07 — Sources, conclusions and tests that could distinguish the mechanisms
- ELEC 04 — Kinetics, speciation and transport: from local reaction to reactor response
- ELEC 06 — Where the numbers came from: GX-TXT, GNU Octave and reproducibility