Skip to content

fusion-energy/model_benchmark_zoo

Repository files navigation

cad to dagmc cad to openmc

A collection of CAD and equivalent Constructive Solid Geometry (CSG) geometries

This is a unique set of CAD geometries with corresponding Constructive Solid Geometry (CSG). The intended use is for particle transport computational benchmarks. The collection of geometries provides particle transport codes an opportunity to verify particle transport is the same with both geometry types.

This benchmark is invaluable if you want to test that a particle transport code gets the same results in CSG and CAD geometry transport as it provides geometries that:

  • cover all standard CSG surface types
    • planes
    • spheres
    • cylinders
    • tori
    • cones
    • general quadratics
  • cover contacting and non-contacting geometries (to test imprint and merging)
  • cover single and multibody geometries
  • models are parametric so can easily be changed for parameter studies

I originally made this repository as there was no other comparison of CSG geometry with DAGMC geometry available and I wanted to verify the level of surface discretisation that was needed to provide accurate results.

The repository then grew into a way to test my DAGMC geometry making package cad-to-dagmc. Later on tests for cad-to-openmc which is another geometry making package were also added.

Models

The table below lists all 56 models with details of each model. The combined collection covers a significant number of CAD meshing challenges, but feel free to make a pull request if there are more edge cases to cover.

Model Description Materials Meshing challenge

Blanket module

Blanket module 3 Nested box shells with cylindrical coolant channel; multi-body imprint of curved and planar regions

Simplified tokamak 2 Multi-body with nested curved shells and cylindrical penetration

Nested tori 4 Double curvature with concentric toroidal shells requiring imprint and merge

Cubic lattice

Cubic lattice 2 Eight-sphere 2×2×2 array in a cube; multi-body curved-to-planar imprinting at 8 locations

Pebble bed cell

Pebble bed cell 4 Multiple spheres inside a box; multi-body curved-to-planar imprinting with N pebbles

Oktavian sphere 2 Nested spherical and cylindrical regions with complex boolean intersections

Fuel pin cell

Fuel pin cell 3 Concentric fuel/clad cylinders in a square cell; curved-to-planar imprinting at cylinder-box interface

Concentric cylinders

Concentric cylinders 3 Three nested cylindrical shells; multi-region imprint and merge on curved interfaces

Pipe elbow

Pipe elbow 1 Hollow toroidal section; double curvature with thin annular wall and cut-plane end faces

Divertor monoblock

Divertor monoblock 2 Rectangular block with annular pipe bore; curved-to-planar boolean and thin-walled annulus

Cylindrical intersection

Cylindrical intersection 1 Two perpendicular fused cylinders; curved-to-curved boolean with saddle-shaped intersection seam

Sphere with multiple holes

Sphere with multiple holes 1 Three orthogonal cylindrical booleans on a sphere; intersecting seam edges at hole crossings

Elliptical torus 1 Non-uniform curvature from elliptical cross-section on a toroidal path

Circular torus 1 Genus-1 topology with double curvature and saddle-point regions

Toroidal sector

Toroidal sector 1 Partial torus arc with open cut faces; double curvature meeting flat end planes

Overlapping spheres

Overlapping spheres 2 Lens-shaped curved intersection seam between two partially overlapping spheres

Hexagonal lattice cell

Hexagonal lattice cell 2 Cylindrical pin inside hexagonal prism; curved-to-planar imprint at 120-degree face junctions

Capsule

Capsule 1 Cylinder with hemispherical end caps; curved-to-curved tangent join at cap-barrel seam

Ogive

Ogive 1 Nose cone (spherical section); curved surface meeting a flat base plane at the perimeter

Sphere with cylindrical hole 1 Curved-to-curved boolean intersection producing saddle-shaped seam edges

Box with spherical cavity 1 Flat-to-curved boolean intersection; sharp curvature transition at cavity edge

Eccentric nested cylinders

Eccentric nested cylinders 2 Non-concentric annular gap; varying thin-wall thickness around the circumference

Hyperboloid

Hyperboloid 1 Negative Gaussian curvature surface; concave and convex directions simultaneously

Thin-walled sphere

Thin-walled sphere 1 Curved thin shell; element quality in narrow gap between two concentric curved surfaces

Thin-walled cylinder

Thin-walled cylinder 1 Cylindrical thin shell; element quality in narrow annular gap between concentric surfaces

Nested sphere 2 Concentric curved shells requiring conformal surface meshes at the shared interface

Cylinder in box

Cylinder in box 2 Curved surface tangent to flat faces; cylindrical-to-planar imprinting along tangent lines

Sphere in box

Sphere in box 2 Curved surface enclosed in rectilinear body; pebble-in-moderator case

Cross junction

Cross junction 2 Four-way body contact; non-coincident face imprinting at 4 re-entrant corners

T-junction

T-junction 2 Right-angle body contact; non-coincident face imprinting at a partial shared surface

Paraboloid

Paraboloid 1 Curvature varying from tight at the vertex to nearly flat far from the axis

Ellipsoid

Ellipsoid 1 Non-uniform curvature with poles where mesh elements tend to collapse

Three touching cuboids 3 Multi-body imprinting at T-shaped shared faces; triple-edge junction

Nested cylinders 2 Concentric cylindrical shells; conformal meshing at shared curved interfaces

Annular sector

Annular sector 1 Wedge slice of a cylindrical shell; curved surfaces meeting angled cut planes

Stepped cylinder

Stepped cylinder 1 Abrupt radius change at step; mesh grading at cylindrical-to-planar transition

Cone

Cone 1 Degenerate apex where surface converges to a point; element collapse at tip

Pyramid

Pyramid 1 Four flat faces converging to a degenerate apex point; element collapse at tip on planar faces

Two tetrahedrons in contact 2 Shared triangular face with acute dihedral angles at all edges

Two touching cuboids 2 Shared planar face imprinting between two bodies

Elliptic cylinder

Elliptic cylinder 1 Non-uniform curvature around the cross-section; tight curvature at minor-axis ends

Hemisphere

Hemisphere 1 Curved-to-flat transition at the cut plane; sharp edge where sphere meets plane

Sphere 1 Uniform curvature with poles; baseline for faceting error on curved surfaces

Pipe

Pipe 1 Hollow cylindrical wall; thin annular cross-section with inner void

Truncated cone

Truncated cone 1 Linearly varying radius; mesh grading from wide base to narrow top

Wedge

Wedge 1 Acute dihedral angle (~17 degrees); tet quality degrades at sharp edges

L-shaped solid

L-shaped solid 1 Non-convex body with a sharp 90-degree re-entrant corner

Hexagonal prism

Hexagonal prism 1 Non-90-degree planar edge angles; 120-degree junctions between flat faces

Chamfered box

Chamfered box 1 Angled planar chamfer faces at non-90-degree edge intersections

Cylinder 1 Single curvature surface; baseline for cylindrical faceting accuracy

Cladded plate

Cladded plate 3 Three-layer planar sandwich; multi-body conformal meshing at shared flat interfaces

Thin gap

Thin gap 2 Two cuboids separated by narrow void gap; thin-slit meshing and streaming path fidelity

Thin plate

Thin plate 1 High aspect ratio (20:1); thin-wall volume meshing with very few layers through thickness

Tetrahedron 1 Acute edges and vertices; mesh quality at sharp corners of a simplex

Cuboid 1 All-planar baseline; tests basic flat-face meshing and 90-degree edges

Installation

First clone the repository:

git clone https://github.com/fusion-energy/model_benchmark_zoo.git
cd model_benchmark_zoo

Install using pip

python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
pip install .

This uses an extra index for pre-built OpenMC wheels.

Install using Mamba

Requires a Conda/Mamba distribution:

mamba env create -f environment.yml
mamba activate model_benchmark_zoo
pip install .

If the environment solve fails, you can try installing OpenMC from source instead.

Usage

Each model provides both a CSG definition and a CadQuery CAD assembly. Example scripts that compare CSG and DAGMC simulation results can be found in the examples folder.

About

A collection of neutronics models for comparing neutronics simulations in both CAD and CSG formats.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages