Skip to content

Interactive notebooks

Open the notebook workspace. Choose a lesson from the sidebar and run its cells when ready. Each notebook uses the Py-Fatigue version built from the same source as this edition of the Handbook. The first visit downloads the Python runtime and packages. The larger histories take longer to compute. Marimo WebAssembly notebooks.

Getting Started

Getting Started or view its saved outputs. The documentation build generates both notebooks from the same source.

Example catalogue

The plots have ECharts and Static tabs. Choose ECharts for hover values, zooming and image export, or Static for Matplotlib. The ECharts tab loads Apache ECharts from jsDelivr.

Several lessons also run a 3,000,000-cycle example using peaks from py_fatigue.testing.get_random_data. History plots sample the calculated results for display. Run long calculations locally, including the full surface-crack history, or open their saved results.

Lesson What it teaches Saved output
Development guide Compare ASTM and four-point residuals and overlay S–N curves. View
Rainflow counting Count full and half cycles, export a sparse spectrum, and compare it after reloading. View
Cycle count aggregation Add adjacent windows, recover residuals, and compare the spectrum and Miner damage with a whole-signal count. View
S–N curves and Miner damage Build a curve from knee points and see the effect of the endurance limit on life and damage. View
Mean stress and equivalent loads Compare corrections, Miner damage, damage equivalent stress, and damage equivalent moment. View
Nonlinear damage Compare Miner and Pavlou under reversed load orders and plot a Theil effective stress history. View
Plate stress intensity Sketch two plate geometries and compare stress intensities as crack depth changes. View
NASGRO growth rate Sweep intensity up to toughness and compare two fixed stress ratios. View
Crack growth Inspect applied stresses, crack dimensions, and peak stress intensities on a shared cycle range. View
Synthetic signal to failure Generate a long waveform and follow its ordered cycles to the Miner and crack-growth limits. View
Through-crack growth Propagate center and edge plate cracks under the same loads and compare their initial and final profiles. View
Surface-crack growth Compare a semi-elliptical plate crack with an SC07 round-bar crack under the same tensile blocks. Plot their depth histories and crack-front profiles. View
AFGROW FAC-1 stress-intensity history Reconstruct the combined stress intensity for bypass tension and pin bearing and compare published finite-element and NASGRO results. View

The examples draw on workflows in the original OWI-Lab tutorials. They use self-contained inputs so they can run from this checkout. OWI-Lab tutorial notebooks

End-to-end tutorials

Each tutorial defines a material curve, a geometry and a load history, then runs the analysis and plots the results. Crack-growth tutorials show the initial and final crack profiles. Each analysis includes a seeded 3,000,000-cycle load spectrum and explains the outcome.

Tutorial Analysis Saved output
Tube in bending Convert bending moments to stress, aggregate rainflow counts, and compare Miner damage and equivalent loads with an S–N curve. View
Through and surface cracks in a plate Compare the crack dimensions, stress intensities, and stop conditions under the same ordered loads. View
AFGROW FAC-1 loaded hole Check Py-Fatigue against the handbook stress intensities and independently integrate an illustrative crack-growth history. View
AFGROW blend-out repair Compare the life of a repaired edge crack against the handbook's reported and printed calculations. View

Run long calculations locally

Use a local Python environment with enough memory to hold the full simulation histories. Open the source notebooks in the marimo editor.

uv run --no-sync marimo edit notebooks

Build the documentation, saved outputs and browser notebooks from a checkout.

rustup target add wasm32-unknown-emscripten --toolchain stable
uv sync --group dev --group docs
uv run --no-sync invoke docs.build

Run uv run --no-sync invoke docs.serve to browse the result over HTTP.