Want to understand the numerical result? Follow the six-step diffusion course from sampling and stability through controlled error studies to a checked C++/MPI run.

What would you like to do?

01 / Run

Run my first model

Check your SDK, create a diffusion model, and inspect how its field changes. Begin with installation, then run and inspect a model.

02 / Understand

Learn a numerical method

Why do two derivative formulas give different answers? Why can a more accurate spatial method need a smaller time step? Explore the numerical methods.

03 / Experiment

Work through examples

Explore the C++ tutorials from physical grids and derivatives to time stepping, coupled fields and output. Follow each lesson’s equations, run its model and check the result.

04 / Scale

Use MPI and a cluster

Take a checked one-rank calculation into an allocation. Understand what a rank owns, what crosses a halo, and why communication matters. Continue with HPC usage.

Your first working calculation

With a compatible SDK and native CLI installed, run:

openpfc doctor
openpfc init my-model --model=diffusion
cd my-model
openpfc run model.cpp input.json --launcher=none

doctor checks the installed compiler/SDK combination. init creates an editable C++ model and its input. run compiles when necessary, executes the model and prints a saved attempt directory. The installation guide explains prerequisites and SDK discovery; older release modules may not include these CLI commands.

In the printed attempt directory, open results/summary.json and results/diagnostics.csv. With the default diffusion input, the mean stays near 1 and the L2 norm decreases. You have a physical expectation to compare against the numbers: heat spreads out while the total amount is conserved on a periodic domain.

Change a parameter only after predicting its effect. A smaller diffusivity should smooth more slowly over the same time interval. A smaller time step with the same step count also changes the final time; change the step count as well when comparing errors at a fixed physical time.

Understand the result before scaling it

The differentiation lesson explains how samples become a spatial derivative. The diffusion lesson follows that derivative into an evolution equation and a stability restriction. Both let you change parameters and compare against an independently known answer in your browser.

Then return to C++: edit the generated model, keep the analytic checks that still apply, and use the run and bundle guide to preserve inputs, inspect outputs and package a compiled CPU model.

Keep the detailed reference close

The handbook contains configuration keys, installation details, cluster notes, troubleshooting and extension guides. The C++ API reference provides exact declarations. This learning route connects the ideas to those details as you need them.