Terms Developed in Context
The terms below connect the mathematical model, implementation choices, computed diagnostics, and limits of the scientific claim.
- Cell average
The volume-averaged state represented by one finite-volume zone. In this lecture it is used to address Does adding cells improve a result, or merely make a sharper-looking plot?
Model connection: Read the term against Numerical flux and the governing relation \(\mathbf U_i^{n+1}=\mathbf U_i^n-\frac{\Delta t}{\Delta x}(\hat{\mathbf F}_{i+1/2}-\hat{\mathbf F}_{i-1/2})\). The relevant computational evidence is a controlled output, residual, invariant, or refinement sequence rather than visual smoothness alone.
Interpretive limit: A fine grid is not automatically converged; the reference solution also has error, and a first-order method diffuses shocks. Never label the 512-cell solution exact. This distinction separates numerical behavior from physical accuracy and model adequacy.
- Numerical flux
An interface estimate of transported conserved quantities used in the discrete update. In this lecture it is used to address Does adding cells improve a result, or merely make a sharper-looking plot?
Model connection: Read the term against CFL condition and the governing relation \(\mathbf U_i^{n+1}=\mathbf U_i^n-\frac{\Delta t}{\Delta x}(\hat{\mathbf F}_{i+1/2}-\hat{\mathbf F}_{i-1/2})\). The relevant computational evidence is a controlled output, residual, invariant, or refinement sequence rather than visual smoothness alone.
Interpretive limit: A fine grid is not automatically converged; the reference solution also has error, and a first-order method diffuses shocks. Never label the 512-cell solution exact. This distinction separates numerical behavior from physical accuracy and model adequacy.
- CFL condition
A timestep restriction tying numerical propagation to the fastest resolved signal speed. In this lecture it is used to address Does adding cells improve a result, or merely make a sharper-looking plot?
Model connection: Read the term against Numerical diffusion and the governing relation \(\mathbf U_i^{n+1}=\mathbf U_i^n-\frac{\Delta t}{\Delta x}(\hat{\mathbf F}_{i+1/2}-\hat{\mathbf F}_{i-1/2})\). The relevant computational evidence is a controlled output, residual, invariant, or refinement sequence rather than visual smoothness alone.
Interpretive limit: A fine grid is not automatically converged; the reference solution also has error, and a first-order method diffuses shocks. Never label the 512-cell solution exact. This distinction separates numerical behavior from physical accuracy and model adequacy.
- Numerical diffusion
Artificial smoothing introduced by a discretization, especially near discontinuities. In this lecture it is used to address Does adding cells improve a result, or merely make a sharper-looking plot?
Model connection: Read the term against Resolution study and the governing relation \(\mathbf U_i^{n+1}=\mathbf U_i^n-\frac{\Delta t}{\Delta x}(\hat{\mathbf F}_{i+1/2}-\hat{\mathbf F}_{i-1/2})\). The relevant computational evidence is a controlled output, residual, invariant, or refinement sequence rather than visual smoothness alone.
Interpretive limit: A fine grid is not automatically converged; the reference solution also has error, and a first-order method diffuses shocks. Never label the 512-cell solution exact. This distinction separates numerical behavior from physical accuracy and model adequacy.
- Resolution study
A controlled comparison across grid spacings used to test convergence and estimate discretization error. In this lecture it is used to address Does adding cells improve a result, or merely make a sharper-looking plot?
Model connection: Read the term against Cell average and the governing relation \(\mathbf U_i^{n+1}=\mathbf U_i^n-\frac{\Delta t}{\Delta x}(\hat{\mathbf F}_{i+1/2}-\hat{\mathbf F}_{i-1/2})\). The relevant computational evidence is a controlled output, residual, invariant, or refinement sequence rather than visual smoothness alone.
Interpretive limit: A fine grid is not automatically converged; the reference solution also has error, and a first-order method diffuses shocks. Never label the 512-cell solution exact. This distinction separates numerical behavior from physical accuracy and model adequacy.
Problem and physical meaning
A finite-volume scheme represents cell averages, so a discontinuity is spread across a resolution-dependent number of cells. Grid convergence must compare quantities and integrated errors on a common coordinate, not compare line thickness by eye.
Does adding cells improve a result, or merely make a sharper-looking plot? Begin from the scientific observable or state variable, and name what is directly specified versus inferred. The model should be simple enough to validate, but not quietly presented as the entire astrophysical system.
Model and derivation
The governing expression for this lecture is:
Define the symbols and the independent variable before numerical evaluation. Dimensional analysis checks that both sides have matching units; if the model is dimensionless, state the adopted scale factors and the transformation back to physical units.
A finite-volume scheme represents cell averages, so a discontinuity is spread across a resolution-dependent number of cells. Grid convergence must compare quantities and integrated errors on a common coordinate, not compare line thickness by eye.
Numerical implementation
Run the identical initial-value problem at 32, 64, 128, and 256 cells; preserve CFL and final time; record mass error and L1 density discrepancy against a finer reference; discuss numerical diffusion and boundary influence.
Keep physical quantities and numerical arrays conceptually separate. Convert units at well-defined boundaries, preserve raw inputs, and record dtype, solver, tolerances/timestep, grid, and software versions. A numerical method is part of the model evidence, not an invisible implementation detail.
Worked, programmatically computed example
The density L1 discrepancy against the 512-zone reference decreases from 0.03066 at 32 cells to 0.00521 at 256; measured mass errors are listed independently.
These values are generated in src/astr474_computations.py, then shared with lecture/lab/assignment renderers. Re-run the generator after changing an input; do not hand-edit a displayed result without recomputing dependent artifacts.
At least one independent check is required: an analytic solution, a second numerical method, a conservation law, or a controlled convergence sequence. When these disagree, diagnose units, frame, discretization, source terms, and model scope before selecting a result.
Error budget and limitations
A fine grid is not automatically converged; the reference solution also has error, and a first-order method diffuses shocks. Never label the 512-cell solution exact.
Classify each uncertainty before combining terms: local/global solver error, timestep or spatial discretization, Monte Carlo sampling, parameter uncertainty, measurement uncertainty, and model discrepancy are not interchangeable. Conservation can test internal consistency but does not prove the model is physically complete.
Connection to evidence and research practice
Lab 04 requires a resolution table and a plot with discontinuity structure, not only a single final image.
For real parameters, the source record distinguishes the fetched product and epoch from derived values. For synthetic experiments, the initial conditions, generator, seed, and exact file are recorded. A simulation is not an observation, even when its parameters resemble a real object.
Misconceptions to avoid
- More displayed digits do not imply more physical accuracy.
- A successful solver exit or smooth plot does not establish convergence.
- Agreement between two solvers with the same wrong model is not independent physical validation.
- A formal covariance or Monte Carlo interval is conditional on the adopted model and noise process.
Study and review questions
- Does adding cells improve a result, or merely make a sharper-looking plot?
- Which numerical parameter would you vary first, what observable would you track, and how would you know the sequence reached an asymptotic regime?
- Design one independent check and state what failure would change your scientific interpretation.
Preparation for the next lecture: explain how this method's assumptions change when the problem becomes more coupled, stochastic, or data-driven.
Lecture-specific derivation and assumptions
Integrating partial_t U + partial_x F=0 over cell i and applying the divergence theorem gives U_i^(n+1)=U_i^n-(dt/dx)(Fhat_(i+1/2)-Fhat_(i-1/2)). Summing over cells cancels interior fluxes exactly, leaving only boundary flux and roundoff. The Rusanov flux is one-half the left/right physical flux sum minus one-half a maximum signal speed times the state jump. Stability requires a CFL restriction dt <= C*dx/max(|u|+c); refinement changes both shock width in physical units and numerical diffusion.
Algorithm trace and computed-output interpretation
Use identical initial states, CFL, boundaries, and final time at 32, 64, 128, and 256 cells. Interpolate the 512-cell teaching run onto each coarse grid, calculate mean absolute density difference, and compute successive coarse-grid error ratios. Verify total mass separately. A ratio near two is compatible with first-order behavior only if the sequence is approaching its asymptotic regime and the fine reference error is small enough.
Computed result: The density L1 discrepancy against the 512-zone reference decreases from 0.03066 at 32 cells to 0.00521 at 256; measured mass errors are listed independently.
The provided profile is an output of the same first-order code, so comparing against it is a resolution study rather than comparison with an exact Riemann solution. The 512-cell reference has its own diffusion/error. Preserve the measured error table and state that limitation when describing observed order.
Two-meeting teaching arc
Each weekly module is taught in two 75-minute meetings. The sequence below includes a formative check in each meeting and is intended to use the lecture's worked computation, not merely present it.
- Meeting 1 (75 min): 10 min grid representation; 20 min integral conservation derivation; 20 min Rusanov flux and wave speeds; 20 min CFL stability; 5 min predict refinement behavior.
- Meeting 2 (75 min): 10 min recap; 20 min diagnose numerical diffusion; 25 min analyze the four-grid table/profile; 15 min interpret the 512-cell reference; 5 min propose an independent benchmark.
Targeted study questions
- Derive the global conservation statement by summing the cell update.
- Why can an L1 ratio differ from two on a coarse grid even for a first-order scheme?
- What exact solution or independent solver would improve the reference, and what matching conventions would it require?
References and provenance: course reference log. Generated 2026-09-27.