A10 Magnus schemes
| ID | Group | Type | Backends | Figure | Program |
|---|---|---|---|---|---|
| A10 | Accuracy | P | CPU (gfortran, nvfortran, ifx), GPU (OpenACC); orders in R8P | yes | selah_vv_magnus |
Case and scope
The commutator-free Magnus schemes of magnus_stepper (Schemes), run with the dense per-cell action, on two linear non-autonomous systems selah_test_magnus checks that case). ADAM's CFM-4 runs alongside as the defect it was: each exponential a forward-Euler step, an explicit Runge–Kutta of order 2 (notes/magnus.md §4).
Setup
| Item | Value |
|---|---|
| Rotation | |
| Two-level system | |
| Cells | three per system, |
| Reference | feagin-108 (order 10) at 32 sub-steps per step |
| Error | the largest over the run, |
| Orders | 8 to 256 steps; the bound: within 0.15 of the declared order at 32 → 64 steps (order 4) and 16 → 32 (orders 6 and 8: below |
| Norm | 1000 steps of 0.05: |
Program
./exe/selah_vv_magnus
scripts/run_vv.sh --only selah_vv_magnus # magnus-orders.dat, then the table and the figure belowResults

| Scheme | System | Declared | 8→16 | 16→32 | 32→64 | 64→128 | 128→256 | Error at 256 steps |
|---|---|---|---|---|---|---|---|---|
cf4-2 | rotation, turning axis | 4 | 3.97 | 3.99 | 4.00 | 4.00 | 4.00 | 1.27e-09 |
cf4-2 | driven two-level system | 4 | 4.05 | 4.01 | 4.00 | 4.00 | 4.00 | 8.33e-10 |
cf4-3opt | rotation, turning axis | 4 | 4.18 | 4.05 | 4.01 | 4.00 | 4.00 | 3.71e-11 |
cf4-3opt | driven two-level system | 4 | 4.19 | 4.01 | 4.00 | 4.00 | 4.00 | 3.30e-11 |
cf4-4 | rotation, turning axis | 4 | 3.20 | 3.85 | 3.96 | 3.99 | 4.00 | 5.05e-11 |
cf4-4 | driven two-level system | 4 | 3.72 | 3.93 | 3.98 | 4.00 | 4.00 | 2.16e-11 |
cf6-5 | rotation, turning axis | 6 | 5.98 | 5.99 | 6.00 | 6.00 | — | 3.16e-14 |
cf6-5 | driven two-level system | 6 | 6.02 | 6.00 | 6.00 | 6.01 | — | 1.52e-14 |
cf6-5b | rotation, turning axis | 6 | 5.98 | 6.00 | 6.00 | 6.00 | — | 3.11e-14 |
cf6-5b | driven two-level system | 6 | 6.33 | 5.98 | 6.01 | 6.00 | — | 1.98e-14 |
cf6-5opt | rotation, turning axis | 6 | 5.92 | 5.99 | 5.99 | 5.96 | — | 1.61e-14 |
cf6-5opt | driven two-level system | 6 | 5.98 | 5.99 | 6.00 | — | — | 1.39e-14 |
cf8-11 | rotation, turning axis | 8 | 7.98 | 8.00 | — | — | — | 1.95e-14 |
cf8-11 | driven two-level system | 8 | 8.88 | 8.08 | — | — | — | 1.43e-14 |
adam-cfm4 | driven two-level system | 2 | 2.40 | 2.11 | 2.00 | 1.98 | 1.99 | 2.01e-04 |
The observed order of each halving; — where the finer error is below 1e-13 (round-off). adam-cfm4: ADAM's CFM-4, each exponential a forward-Euler step (dashed); order 4 solid, 6 dash-dotted, 8 dotted. The bound: within 0.15 of the declared order at 32→64 (order 4) and 16→32 (orders 6 and 8), the finer error above 1e-13 (selah_vv_magnus).
The norm. Over 1000 steps of 0.05, every scheme keeps cf6-5opt), on both systems. Over the same run ADAM's CFM-4 drifts by rk4 by
Findings
- Every scheme has its order on both systems: 4 from 16 steps on, 6 from 8 (5.98 to 6.02), 8 for
cf8-11(8.00 and 8.08 at 16 → 32 steps), down to R8P's round-off,. cf4-3optandcf4-4are 25 to 40 times more accurate thancf4-2at the same steps,cf6-5opt15 times more thancf6-5: the optimised sets earn their extra exponential or node. - The cost at a given error.
cf8-11makes 11 exponentials a step, 5.5 timescf4-2's. At an error ofon the rotation (interpolated in the table's errors) it needs 18 steps, 198 exponentials; cf6-5opt42 steps, 210;cf4-2about 480, 960. Belowthe eighth order gains; above it cf6-5optis as cheap. - ADAM's CFM-4 has order 2, as its Runge–Kutta tableau says (
): at 256 steps where cf4-2, with half its exponentials, reaches. - The norm is kept to rounding by the dense action, whatever the scheme: the property the Magnus form exists for.