Skip to main content

FoamNordic

FoamNordic

FoamNordic is a native C++ and Python framework for ordinary OpenFOAM and machine-learning field programs, including equation-level closures. It keeps atomic field exchange, packing, scaling, and lifecycle in the native runtime while exposing a compact declarative API for cases, placement, launch, observations, and results.

FoamNordic is active research software. Version 1.0.5 establishes the documented distribution baseline. Release notes and upgrade guidance are maintained in the changelog.

Install

python3 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install foamnordic

# Load or enter the desired OpenFOAM environment once, then:
foamnordic build

foamnordic --version
foamnordic --help
foamnordic dir
foamnordic doctor

The same installation includes ONNX packaging, compiled and Joblib/scikit-learn models, and JAX/Equinox resident models. No backend-specific extra is required.

Binary wheels carry the native Python control runtime and compact OpenFOAM source build kit. foamnordic build compiles it for the currently loaded ABI; each case later selects that runtime from its declared of_cmd and shell. The build also prepares the native ONNX ModelHost and verified ONNX Runtime 1.28.0. Offline systems can point FOAMNORDIC_ONNX_RUNTIME_ROOT at an unpacked 1.28.0 distribution.

First case

from pathlib import Path
import foamnordic as fno

case = fno.OpenFOAM.Case(
    name="cavity",
    case_dir=Path("cases/cavity"),
    run_dir="output/cavity",
    of_cmd="module load openfoam/2512",  # macOS OpenFOAM.app: "openfoam"
    shell="bash",
)

# Use an existing cavity case with a blockMeshDict and initial fields.
case.initialize(ranks=1, mesh="blockMesh", validate_mesh=True)
print(case.fields.keys())

run = fno.Longship(case=case).launch()
run.summary()

result = run.stop()
post = result.postprocess
statistics = post.statistics(["U", "p"], time_idx=-1, verbose=True)

Paths may be strings, pathlib.Path, or text PathLike objects. FoamNordic uses 0/ when available and otherwise copies 0.orig/ to 0/ inside the isolated run without changing the source case.

Platforms

  • Linux x86_64
  • Linux aarch64
  • macOS Apple Silicon (arm64)

Native macOS development uses OpenFOAM.app. It provides current OpenFOAM releases as Apple Silicon applications and Homebrew packages.

Learn more

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

foamnordic-1.0.5-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (701.3 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

foamnordic-1.0.5-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl (657.2 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.26+ ARM64manylinux: glibc 2.28+ ARM64

foamnordic-1.0.5-cp312-cp312-macosx_12_0_arm64.whl (471.6 kB view details)

Uploaded CPython 3.12macOS 12.0+ ARM64

foamnordic-1.0.5-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (701.7 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

foamnordic-1.0.5-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl (658.1 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.26+ ARM64manylinux: glibc 2.28+ ARM64

foamnordic-1.0.5-cp311-cp311-macosx_12_0_arm64.whl (472.4 kB view details)

Uploaded CPython 3.11macOS 12.0+ ARM64

File details

Details for the file foamnordic-1.0.5-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for foamnordic-1.0.5-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 396bbe7645d1d5c393b63b88694b66aca525a1c0227774eebda65d786fdf5212
MD5 9c02151bc7932abbcb85eb032c32ef80
BLAKE2b-256 50e82979bc73bcbe27390af9c8af62dcdd892d30d4c6a4e7cf60f7b5346bb2b4

See more details on using hashes here.

File details

Details for the file foamnordic-1.0.5-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for foamnordic-1.0.5-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 2e28e415f395169b12ab6efd72eeb7f6be9c1314af41466a12d0293372c5de53
MD5 0d658c2f6b3d3106af19061dc24844c3
BLAKE2b-256 ab46918cc94c519618ac9e312c7fe442b14170e966c0ab628184e123bffe1d08

See more details on using hashes here.

File details

Details for the file foamnordic-1.0.5-cp312-cp312-macosx_12_0_arm64.whl.

File metadata

File hashes

Hashes for foamnordic-1.0.5-cp312-cp312-macosx_12_0_arm64.whl
Algorithm Hash digest
SHA256 7e5f774c16248310274c02595bba82f1a0f5559b9633a70af287785ad6c1ca35
MD5 13b0ddce413f281b3f7b8fc95cd51899
BLAKE2b-256 b66e6d61a5395c58dabe3ad806bfbba54a39e999068d5040523046aa7aa03921

See more details on using hashes here.

File details

Details for the file foamnordic-1.0.5-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for foamnordic-1.0.5-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 98ccc96420c55dd6812a0aa9171ba8ca35f29cbe86336af8e9d995650b36e8e2
MD5 03069185a39823324e2c19b155043058
BLAKE2b-256 f802953e3c0b4fa8af6b3b6a35c03e2607d99a44c7bfaad3a250eb30dfc14f7d

See more details on using hashes here.

File details

Details for the file foamnordic-1.0.5-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for foamnordic-1.0.5-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 dd152f8d16b478a92a7f0baeb1a628726999afa21f9cc6cbe1e7674a104ff762
MD5 c7b19f4fbabe77e252652a44af5bcc82
BLAKE2b-256 e46ce9f56ec29f72af5637824240f230bf0e1c890e6c00bcc559e0ce5bb44a4e

See more details on using hashes here.

File details

Details for the file foamnordic-1.0.5-cp311-cp311-macosx_12_0_arm64.whl.

File metadata

File hashes

Hashes for foamnordic-1.0.5-cp311-cp311-macosx_12_0_arm64.whl
Algorithm Hash digest
SHA256 c82b6b0c23241e9d8bf2c71439a4a57cf9f34149461e968aeb6f4850285618b8
MD5 76b8097acf7e7bb5b818b3db3ffdf622
BLAKE2b-256 c123e9e739da0fe5f60277346e836a12099d997bb568b1838abf50b6fdf52f44

See more details on using hashes here.

Release history Release notifications | RSS feed

1.0.8

6 files

1.0.7

6 files

1.0.6

6 files

This release

1.0.5 This release

6 files

1.0.4

6 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page