Compare commits

...

1809 commits

Author SHA1 Message Date
Satoshi Misumi
852f92780c
Fix M_PI being unavailable where _USE_MATH_DEFINES comes too late (#4023)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-21 15:45:41 +00:00
GuySten
61c8a59cff
Override NJOY default damage energy threshold (#4022)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-20 14:52:30 +00:00
Mazeyar Moeini Feizabadi
05d01274a7
Add analytic tests for ray-traced intersection distances (#4014)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
2026-07-19 14:49:48 -05:00
Joffrey Dorville
db673b9acb
Automatic C++ doc generation (#3950)
Some checks failed
Tests and Coverage / filter-changes (push) Has been cancelled
dockerhub-publish-develop / main (push) Has been cancelled
dockerhub-publish-develop-dagmc-libmesh / main (push) Has been cancelled
dockerhub-publish-develop-dagmc / main (push) Has been cancelled
dockerhub-publish-develop-libmesh / main (push) Has been cancelled
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / coverage (push) Has been cancelled
Tests and Coverage / Check CI status (push) Has been cancelled
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-17 15:47:40 +00:00
GuySten
796ae384b8
Fix not reseting filter_matches corrupt pulse height results (#4019)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-17 13:18:53 +00:00
GuySten
d3bc1669d3
Access element subshell map data only if it has atomic relaxation data (#4020) 2026-07-17 07:40:16 -05:00
Paul Romano
f1fb6721f0
Performance optimizations for shared secondary bank (#4011)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
2026-07-17 01:25:18 +00:00
Ethan Peterson
c55c578812
Native parametric tokamak source (#3999)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-16 09:54:56 -05:00
Paul Romano
16cde42ff4
Enable parent-nuclide tally breakdowns in R2S calculations (#4013)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
2026-07-16 00:00:42 +03:00
Lewis Gross
243c249533
normalize new_u after periodic crossing to prevent unnormalized direction (#4015)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
2026-07-15 08:57:53 -05:00
Eden
e783e01471
Add chain parameter to Material.get_activity for half-life data (#3957)
Some checks failed
Tests and Coverage / filter-changes (push) Has been cancelled
dockerhub-publish-develop / main (push) Has been cancelled
dockerhub-publish-develop-dagmc-libmesh / main (push) Has been cancelled
dockerhub-publish-develop-dagmc / main (push) Has been cancelled
dockerhub-publish-develop-libmesh / main (push) Has been cancelled
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / coverage (push) Has been cancelled
Tests and Coverage / Check CI status (push) Has been cancelled
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-11 06:18:26 +00:00
Jonathan Shimwell
7256d5046a
extra checks for pixels (#4009)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
Co-authored-by: Jonathan Shimwell <jon@proximafusion.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-10 15:02:14 +00:00
Paul Romano
216651b69e
Shared secondary bank performance optimizations (#3995) 2026-07-10 09:22:16 -05:00
Paul Romano
7c408f6a10
Replace Ben Forget with John Tramm on technical committee (#4008)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
2026-07-10 09:48:11 +02:00
Paul Romano
3c3ebba98b
Turn on weight windows if weight_windows_file is specified (#4007)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
2026-07-09 23:59:33 +00:00
GuySten
e73d8048da
Support cell densities per instances in plots (#4006)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-09 22:45:09 +00:00
Jonathan Shimwell
5203640549
Further input validation for plot methods (#4004) 2026-07-09 16:55:32 -05:00
Paul Romano
3cdb67e50d
Store slice overlap indices in cell ID field (#4002)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
2026-07-09 11:47:55 +02:00
Paul Romano
8b15ee3915
Add Jon Shimwell to technical committee (#4001)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
2026-07-08 11:25:21 -05:00
Andrew Davis
8684506269
This fixes compile isuees found with GCC 16.1.1 and FMT version (#4000)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-07 14:58:19 +00:00
viktormai
0c6b3fb835
Overlap detection for plotter (#3969)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-06 17:47:22 +00:00
Paul Romano
3fcb9692be
Make sure output is treated consistently in R2SManager (#3994)
Some checks failed
Tests and Coverage / filter-changes (push) Has been cancelled
dockerhub-publish-develop / main (push) Has been cancelled
dockerhub-publish-develop-dagmc-libmesh / main (push) Has been cancelled
dockerhub-publish-develop-dagmc / main (push) Has been cancelled
dockerhub-publish-develop-libmesh / main (push) Has been cancelled
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / coverage (push) Has been cancelled
Tests and Coverage / Check CI status (push) Has been cancelled
2026-07-04 22:20:03 -05:00
Matteo Zammataro
e3bc615172
Fix numerical cancellation in RectLattice::distance for large pitch values (#3853)
Some checks failed
Tests and Coverage / filter-changes (push) Has been cancelled
dockerhub-publish-develop / main (push) Has been cancelled
dockerhub-publish-develop-dagmc-libmesh / main (push) Has been cancelled
dockerhub-publish-develop-dagmc / main (push) Has been cancelled
dockerhub-publish-develop-libmesh / main (push) Has been cancelled
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / coverage (push) Has been cancelled
Tests and Coverage / Check CI status (push) Has been cancelled
Co-authored-by: matteo.zammataro <matteo.zammataro@newcleo.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-03 21:39:17 +00:00
Paul Romano
66359e5dd8
Fix surface tally crash on lattice crossings (#3993)
Co-authored-by: GuySten <guyste@post.bgu.ac.il>
2026-07-03 15:52:19 -05:00
Matteo Zammataro
97e04c464a
Add ambient dose coefficients (H*(10)) from ICRP74 (#3256)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
Co-authored-by: matteo.zammataro <matteo.zammataro@newcleo.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-02 23:51:10 +00:00
Jon Shimwell
df6f94300f
Turn the weight window game off for a zero or negative lower bound (#3990)
Co-authored-by: John Tramm <john.tramm@gmail.com>
Co-authored-by: shimwell <mail@jshimwell.com>
2026-07-02 13:04:02 -05:00
Paul Romano
3247587d49
Ensure photon cross sections are loaded when FileSource contains photons (#3988)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
2026-07-02 11:54:12 -05:00
John Tramm
24fdb84edc
Tally 32-bit Overflow Fix (#3960)
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-07-02 11:53:49 -05:00
John Tramm
f01852411d
Random Ray Forward Flux Save in Adjoint Mode (#3962)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-01 22:35:27 +02:00
Jonathan Shimwell
d06fdee93a
Preserve user material names in convert_to_multigroup and avoid overwriting material with same name bug fix (#3984)
Some checks failed
Tests and Coverage / filter-changes (push) Has been cancelled
dockerhub-publish-develop / main (push) Has been cancelled
dockerhub-publish-develop-dagmc-libmesh / main (push) Has been cancelled
dockerhub-publish-develop-dagmc / main (push) Has been cancelled
dockerhub-publish-develop-libmesh / main (push) Has been cancelled
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / coverage (push) Has been cancelled
Tests and Coverage / Check CI status (push) Has been cancelled
2026-06-30 09:38:09 -05:00
GuySten
4d6244d93c
Fix for numpy 2.5.0 (#3981)
Some checks failed
Tests and Coverage / filter-changes (push) Has been cancelled
dockerhub-publish-develop / main (push) Has been cancelled
dockerhub-publish-develop-dagmc-libmesh / main (push) Has been cancelled
dockerhub-publish-develop-dagmc / main (push) Has been cancelled
dockerhub-publish-develop-libmesh / main (push) Has been cancelled
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / coverage (push) Has been cancelled
Tests and Coverage / Check CI status (push) Has been cancelled
2026-06-24 16:09:16 -05:00
Paul Romano
608a1c3386
Fix several issues related to independent operator depletion (#3977)
Some checks failed
Tests and Coverage / filter-changes (push) Has been cancelled
dockerhub-publish-develop / main (push) Has been cancelled
dockerhub-publish-develop-dagmc-libmesh / main (push) Has been cancelled
dockerhub-publish-develop-dagmc / main (push) Has been cancelled
dockerhub-publish-develop-libmesh / main (push) Has been cancelled
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / coverage (push) Has been cancelled
Tests and Coverage / Check CI status (push) Has been cancelled
2026-06-23 09:00:47 +02:00
stetsonschott
09ee8308d0
Replaced 'C0' by elemental carbon in `openmc/examples.py'. (#3974)
Some checks failed
Tests and Coverage / filter-changes (push) Has been cancelled
dockerhub-publish-develop / main (push) Has been cancelled
dockerhub-publish-develop-dagmc-libmesh / main (push) Has been cancelled
dockerhub-publish-develop-dagmc / main (push) Has been cancelled
dockerhub-publish-develop-libmesh / main (push) Has been cancelled
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / coverage (push) Has been cancelled
Tests and Coverage / Check CI status (push) Has been cancelled
2026-06-17 20:33:40 -05:00
GuySten
02eb999af1
fix tmate start only on successful tests (#3954)
Some checks failed
Tests and Coverage / filter-changes (push) Has been cancelled
dockerhub-publish-develop / main (push) Has been cancelled
dockerhub-publish-develop-dagmc-libmesh / main (push) Has been cancelled
dockerhub-publish-develop-dagmc / main (push) Has been cancelled
dockerhub-publish-develop-libmesh / main (push) Has been cancelled
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / coverage (push) Has been cancelled
Tests and Coverage / Check CI status (push) Has been cancelled
2026-06-08 22:09:25 -05:00
Logan Harbour
998565808e
Use non-deprecated methods for getting libMesh node points (#3963) 2026-06-08 22:07:21 -05:00
Patrick Shriwise
ea6ba328c9
Fix collision track feature for photon transport (#3946)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-06-08 23:37:34 +00:00
Paul Romano
4f6a25e00a
Introduce new C API function for slice plots (#3806)
Some checks are pending
Tests and Coverage / filter-changes (push) Waiting to run
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Blocked by required conditions
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Blocked by required conditions
Tests and Coverage / coverage (push) Blocked by required conditions
Tests and Coverage / Check CI status (push) Blocked by required conditions
dockerhub-publish-develop / main (push) Waiting to run
dockerhub-publish-develop-dagmc-libmesh / main (push) Waiting to run
dockerhub-publish-develop-dagmc / main (push) Waiting to run
dockerhub-publish-develop-libmesh / main (push) Waiting to run
2026-06-08 21:08:08 +00:00
Paul Romano
db322f2c5d
Add section in depletion user's guide about comparing to other codes (#3955) 2026-06-08 18:22:32 +00:00
EdenRochmanSharabi
111eb77066
Implement SphericalMesh.get_indices_at_coords (#3919)
Some checks failed
Tests and Coverage / filter-changes (push) Has been cancelled
Tests and Coverage / Python 3.13 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14 (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.14t (omp=n, mpi=n, dagmc=, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=n, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=n, libmesh=n, event=n (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=n, dagmc=, libmesh=, event=y (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=y, libmesh=, event= (push) Has been cancelled
Tests and Coverage / Python 3.12 (omp=y, mpi=y, dagmc=, libmesh=y, event= (push) Has been cancelled
Tests and Coverage / coverage (push) Has been cancelled
Tests and Coverage / Check CI status (push) Has been cancelled
dockerhub-publish-develop / main (push) Has been cancelled
dockerhub-publish-develop-dagmc-libmesh / main (push) Has been cancelled
dockerhub-publish-develop-dagmc / main (push) Has been cancelled
dockerhub-publish-develop-libmesh / main (push) Has been cancelled
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-05-30 06:18:09 +00:00
Jonathan Shimwell
219d82726f
Allow tracklength estimator for neutron heating (#3915)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-05-30 06:10:05 +00:00
hugo-barthod
2dd5322fee
Fix undefined variable in openmc.mgxs.library (scatt_mgxs) (#3943)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-05-30 05:35:31 +00:00
Bor Kos
46d8896132
Pulsed Height Tally in mixed neutron-gamma fields (#3937)
Co-authored-by: Bor Kos <bor.kos@bakerhughes.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-05-30 03:25:38 +00:00
Jon Shimwell
ddabe1c8c5
Avoid storing inconsistent sum/sum_sq on summed D1S tallies (#3949)
Co-authored-by: shimwell <mail@jshimwell.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-05-30 03:25:22 +00:00
Paul Romano
1914e3eefa
Support endf.Material in from_endf methods (#3932) 2026-05-29 21:53:45 -05:00
Ahnaf Tahmid Chowdhury
dfb6c5699c
Modernize CMake packaging (#3653)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-05-21 20:33:56 +00:00
Patrick Shriwise
7d09a12606
DAGMC Cell Override Updates (#3888)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-05-20 21:43:21 +00:00
Patrick Shriwise
66497e76b1
Support writing of hex elements to VTKHDF format. (#3623)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-05-20 14:01:21 -05:00
Hridoy Kabiraj
3c7a030d43
Guard average molar mass and validate materials depletion inputs (#3941) 2026-05-20 13:49:00 -05:00
John Tramm
0169fd9226
Shared Secondary Particle Bank (#3863)
Co-authored-by: John Tramm <jtramm@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
Co-authored-by: Copilot <copilot@github.com>
2026-05-19 23:23:10 -05:00
charliesheh
beed56e6ee
Check for missing thread count argument for -s/--threads (#3940) 2026-05-18 13:35:56 -05:00
Hridoy Kabiraj
195dff6d1d
Fix missing volume checks in material activity/decay heat (#3939) 2026-05-18 09:20:59 -05:00
Paul Romano
d56cda2544
Implement DecaySpectrum distribution type and utilize in R2S (#3930)
Co-authored-by: Copilot <copilot@github.com>
2026-05-08 20:53:12 -05:00
Paul Romano
f3e1066d46
Include mass_attenuation.h5 in package data (#3936) 2026-05-07 23:50:23 +00:00
Jonathan Shimwell
e542b2f035
Allow Mesh.volumes property for 1D and 2D RegularMesh (#3914) 2026-05-06 10:07:35 -05:00
Jack Fletcher
368ea069ca
Local adjoint source for Random Ray (#3717) 2026-04-28 16:10:03 -05:00
Paul Romano
1116c4bdc0
Support multiple meshes in R2S calculations (#3860) 2026-04-28 10:02:08 -04:00
Travis L.
806fb4ce77
Clean up MCPL references (#3927) 2026-04-27 09:40:44 -05:00
Perry
2d5c50080c
Allow the use of substeps for CRAM (#3908)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-22 18:24:34 -05:00
Perry
1f7ac4215f
Clip negative atom densities that result from CRAM (#3879)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-21 20:24:53 +00:00
Ethan Peterson
a1df5842e0
Remove self loops from spontaneous fission decay mode (#3907)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-21 16:47:40 +00:00
Lorenzo Chierici
e431d49bec
Add reactivity control to coupled transport-depletion analyses (#2693)
Co-authored-by: Andrew Johnson <drewejohnson@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-20 07:13:53 -05:00
Luke Labrie-Cleary
36e70d8efc
Add Arch Linux User Repository (AUR) installation instructions to documentation (#3921)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-18 16:01:09 +00:00
Paul Romano
fd1bc26af0
Pin NJOY version in Dockerfile (#3920) 2026-04-09 23:13:18 +03:00
Paul Romano
1eb368bbd2
Pin NJOY version in CI to 2016.78 (#3917) 2026-04-09 09:31:27 +02:00
Paul Romano
23e8a11102
Update versions of several GHA Actions (#3913) 2026-04-05 14:04:34 -05:00
Jonathan Shimwell
542f949fa0
Use local variable to avoid attribute lookup in form_rxn_matrix loop (#3884)
Co-authored-by: Perry <yrrepy@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-04 20:53:50 +00:00
GuySten
efc542825e
Add the ability to tally microscopic cross sections in void materials with tracklength estimator (#3771)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-04 20:32:51 +00:00
Ethan Peterson
60d1dfba7f
Refactor form_matrix method on depletion chain class (#3892)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-03 21:27:39 +00:00
John Tramm
b215f13218
RAG search tool for agents (#3861)
Co-authored-by: John Tramm <jtramm@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-03 16:18:19 -05:00
Jonathan Shimwell
9ff50499e1
Adding per m3 to material functions (#3912)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-03 00:00:02 +00:00
bessemoa
df985e10b3
Add from_bounding_box classmethod to structured mesh classes (#3903)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-02 22:51:33 +00:00
Jonathan Shimwell
ca22a5174a
adding pdf to read the docs (#3893) 2026-04-02 17:01:30 -05:00
GuySten
d9b30bbbd5
Approximate multigroup velocity (#3766)
Co-authored-by: Adam Nelson <1037107+nelsonag@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-02 16:59:02 +00:00
Md. Ariful Islam
97d9a839c2
Fix MPI depletion hang (#3910) 2026-04-02 11:30:09 -05:00
April Novak
8223099ed9
All reduce to print correct number of surface source particles (#3901) 2026-03-26 12:35:12 -05:00
GuySten
6cd39073b3
Fix surface tally when crossing lattice (#3895) 2026-03-23 10:16:59 -05:00
Paul Romano
3ce6cbfdda
Add fusion_neutron_spectrum to openmc.stats module (#3862) 2026-03-17 22:10:18 +01:00
itay-space
1578698129
Implement angular PDF evaluation for angle-energy distributions (#3550)
Co-authored-by: Your Name <you@example.com>
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
Co-authored-by: GuySten <guyste@post.bgu.ac.il>
Co-authored-by: Eliezer214 <110336440+Eliezer214@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-03-14 23:58:17 +02:00
Marco De Pietri
bc9c31e0f9
get indices for rectilinear meshes (#3876)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-03-14 04:19:51 +00:00
Paul Wilson
dd6d31bfae
Add properties to settings w/ documentation, c++ loading of filename, and python round-trip test (#3808)
Co-authored-by: Patrick C Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-03-13 21:40:52 +00:00
AlvaroCubi
4bda85f17e
Allow StepResult.get_material to accept integer material ID (#3872)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-03-12 15:04:42 -05:00
Christopher Ashe
c44d2f0b43
Allow groups to be passed as sequence of floats in convert_to_multigroup (#3873)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-03-12 19:47:47 +00:00
Paul Romano
27522fe851
Improve review skill instructions for determining PR context (#3875) 2026-03-12 14:27:00 -05:00
CoronelBuendia
387b41ab65
Change plotting docstring to specify integer RGB values (#3868) 2026-03-12 12:35:10 -05:00
Eshed Magali
ba94c58230
Closing the stdout file descriptor when finished (#3864) 2026-03-11 16:50:58 +00:00
Amanda Lund
1dc4aa9882
Add setting to optionally disable atomic relaxation (#3855)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-03-10 04:00:10 +00:00
Paul Romano
908e63115a
Add reusable reviewing-openmc-code skill and Copilot Review agent (#3842)
Co-authored-by: John Tramm <john.tramm@gmail.com>
2026-03-05 21:40:36 -06:00
GuySten
be4148ad0d
Refactor Ray class into its own file (#3845)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-03-06 01:07:42 +00:00
Paul Romano
6f72619729
Fix include guard in output.h (#3856) 2026-03-05 23:29:36 +00:00
John Tramm
533f09defd
Enable CMake "compile_commands.json" Output (#3854)
Co-authored-by: John Tramm <jtramm@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-03-05 23:20:54 +00:00
Paul Romano
dbfd6387b2
Fix two docstrings that should have r prefix (#3851) 2026-03-05 07:37:47 +02:00
Ethan Peterson
2bd06660c5
Parallelize sampling external sources and threadsafe rejection counters (#3830)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-03-04 14:36:43 -06:00
GuySten
0ab46dfa35
Fix cell data parsing (#3848) 2026-03-04 06:56:49 -06:00
GuySten
70be650003
Implement surface flux tallies (#3742)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-03-04 14:17:48 +02:00
Patrick Shriwise
b796afb591
Correction to surface normal determination in SolidRayTrace plots (#3846) 2026-03-04 14:10:54 +02:00
Marco De Pietri
53d98ce71a
Add method on Material for computing photon contact dose rate (#3700)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-03-03 15:48:56 +00:00
Paul Romano
49b896b0eb
Enable "hybrid" tallies in get_microxs_and_flux (#3831) 2026-03-02 22:06:52 -05:00
GuySten
823b4c96c9
Speed up depletion with transfer rates (#3839) 2026-03-02 06:53:20 -06:00
Paul Romano
83a7b36add
Speed up Docker build (#3841)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2026-03-01 21:52:51 +02:00
Paul Romano
b3788f11e1
Use clang-format version 18 for CI format checks (#3840) 2026-02-27 13:56:00 +02:00
Micah Gale
1d9a8f542b
Add Python 3.14 to testing matrix and drop Python 3.11 (#3642)
Co-authored-by: GuySten <guyste@post.bgu.ac.il>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-26 18:18:04 -06:00
Paul Romano
3b5ac08bfb
Skip DAGMC lost particles test (#3836) 2026-02-26 11:26:39 -06:00
Paul Romano
17d4164242
Update copyright to 2026 (#3834) 2026-02-26 08:14:28 +00:00
GuySten
322b741fde
Support Mixture distributions in combine_distributions (#3784)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-26 07:30:08 +00:00
Jonathan Shimwell
6050c789ca
making use of endf.get_evaluations (#3819)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-26 03:14:44 +00:00
GuySten
3ba8a9f078
Correctly score pulse height tally when no cell filter is present (#3821)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-26 02:44:17 +00:00
Jonathan Shimwell
8081815b99
Add RegularMesh.get_indices_at_coords method (#3824)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-26 02:19:02 +00:00
John Tramm
54c8e3d6eb
Speedup CI and Improve Reproducibility Across Compilers (#3823)
Co-authored-by: John Tramm <jtramm@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-25 17:12:18 -06:00
GuySten
2a38dc11ec
Do not fail CI when coveralls.io is not available. (#3835) 2026-02-25 15:04:00 -06:00
GuySten
c0427dd40a
Resolve conflict with weight windows and global russian roulette (#3751)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2026-02-25 14:01:33 -06:00
Patrick Shriwise
5a85bd92f2
C++ formatting suggestions on PRs (#3829) 2026-02-25 11:08:04 -06:00
Jonathan Shimwell
3ff6b59a49
Allow Mesh.from_domain to use bounding boxes directly (#3828) 2026-02-24 23:44:30 -06:00
Paul Romano
e130701f10
Fix MeshFilter.get_pandas_dataframe to handle all mesh types (#3817) 2026-02-24 07:35:23 +00:00
Vitaly Mogulian
8c24c1c064
Modify the plotter ray tracing for its utilization in estimators (#3816)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-24 06:46:21 +00:00
GuySten
83a30f6860
Support arbitrary symmetry axis for CylindricalIndependent class (#3474)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-21 20:00:36 +00:00
Paul Romano
139907c955
Implement tally filter for filtering by reaction (#3809) 2026-02-21 10:17:12 -06:00
Jonathan Shimwell
153281a490
Remove unused class Tabulated2D (#3818) 2026-02-21 15:00:22 +00:00
John Tramm
53ce1910f9
Fix S2 Random Ray Casting Issue (#3825) 2026-02-19 18:25:31 +00:00
Kevin Sawatzky
efefdb17b1
Add more operator overloads in the new Tensor class (#3822) 2026-02-19 11:03:19 -06:00
Kevin Sawatzky
417343c920
Implement S2 directional sampling in the random ray solver (#3811) 2026-02-19 14:25:19 +02:00
GuySten
f007c85a50
Check for positive radii (#3813) 2026-02-19 08:36:12 +00:00
Jonathan Shimwell
6d6b051507
avoid need to set particles and batches for dagmc models when calling convert_to_multigroup (#3801)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
2026-02-18 11:18:05 -06:00
GuySten
d4dc089618
Remove redundant check (#3812) 2026-02-18 09:09:39 -06:00
John Tramm
977ade79a1
Replace xtensor with internal Tensor/View classes (#3805)
Co-authored-by: John Tramm <jtramm@gmail.com>
2026-02-17 09:50:38 -06:00
Kevin Sawatzky
c6ef84d1d5
Set upper and lower interpolation bounds for MGXS data. (#3803) 2026-02-15 23:59:08 +02:00
Paul Romano
a35927aad3
Extend ParticleProductionFilter to support multiple particle types (#3780) 2026-02-13 22:18:29 -06:00
GuySten
7fc5b94877
Store atomic mass in ParticleType. (#3765)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-14 03:14:03 +00:00
Kevin Sawatzky
19c0aafdc6
Fix None values appearing in cross section data generated with Model.autoconvert (#3802) 2026-02-13 18:52:10 +02:00
Patrick Shriwise
bcb9395207
SolidRayTracePlot CAPI (#3789)
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
2026-02-13 07:54:27 +02:00
GuySten
b145fdd999
Improve radial crossing checks in SphericalMesh and CylindricalMesh (#3792)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-13 05:10:20 +00:00
Jonathan Shimwell
4e5deed0cc
Using ``_LIBRARY` and `_SUBLIBRARY`` from endf package (#3804) 2026-02-13 03:25:49 +00:00
Paul Romano
8198e6021d
Add truncated normal distribution support (#3761) 2026-02-12 18:25:56 +02:00
Patrick Shriwise
a3426cf833
Fix weight windows regression test (#3798) 2026-02-12 06:30:31 -06:00
Jonathan Shimwell
8d0fe6c71d
making use of sum_rules in endf package (#3799) 2026-02-12 10:11:28 +00:00
Jonathan Shimwell
26b13083f3
Use gnds_name and zam from endf package (#3796) 2026-02-12 05:58:00 +00:00
GuySten
96383fcb2b
More interpolation types in Tabular. (#3413)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-11 21:05:07 +00:00
azim-givron
360ec24b41
Implement vector fitting to replace external vectfit package (#3493)
Co-authored-by: azim_givron <a.givron@naarea.fr>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
Co-authored-by: GuySten <guyste@post.bgu.ac.il>
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
2026-02-11 10:00:18 -06:00
Matthew Feickert
44da7022b8
FIX: Remove setuptools from run dependencies (#3794) 2026-02-11 09:21:13 -06:00
Jonathan Shimwell
3f20a5e228
Use several data variables from endf package (#3787) 2026-02-10 06:41:04 -06:00
Jonathan Shimwell
8053111f2d
making use of endf-python package more (#3786)
Co-authored-by: GuySten <guyste@post.bgu.ac.il>
2026-02-10 02:08:25 +00:00
Kevin Sawatzky
4f4930b633
Temperature feedback support in the random ray solver. (#3737) 2026-02-09 16:54:59 -06:00
Paul Romano
d0346e94ac
Install parallel h5py with no build isolation (#3782) 2026-02-08 22:22:39 +00:00
Patrick Shriwise
6efc9db7b3
Modifications to C++ plots for interactive raytrace plots (#3776) 2026-02-08 12:11:19 -06:00
GuySten
04bee9c49f
Check that Surface IDs are at least 1 (#3772)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-06 18:44:16 +00:00
Lewis Gross
a632429267
Move distrib (mat, temp, dens) from XML attribute to subelement for better compatibility with very large instance lists (#3774) 2026-02-06 19:32:32 +02:00
Kevin Sawatzky
14acc762bc
C-API bindings for key random ray functions (#3749) 2026-02-06 10:42:32 -06:00
Jonathan Shimwell
8a62a97115
openmc.Tally creation from constructor (#3777) 2026-02-06 10:23:11 -06:00
Jonathan Shimwell
6f625f3dea
Precompute offsets in random ray source update (#3775) 2026-02-06 09:25:14 -06:00
Gavin Ridley
f2c936cf5b
Implement filter for secondary particle production binned by energy (#3453)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-02-05 18:00:03 -06:00
Jonathan Shimwell
1039b5d9ff
Parallelize transpose of scattering matrix for random ray adjoints (#3768) 2026-02-05 10:43:16 -06:00
Paul Romano
3b619d6904
Fix use of length multiplier in several LibMesh methods (#3773) 2026-02-04 22:29:30 -06:00
David Andrs
a22238e069
Fixing compiler warning about VLA (Clang extension) (#3769) 2026-02-04 14:50:38 -06:00
Paul Romano
b41e22f68b
Refactor ParticleType to use PDG Monte Carlo numbering scheme (#3756)
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
Co-authored-by: Amanda Lund <alund1187@gmail.com>
2026-02-03 07:23:24 +00:00
Ethan Peterson
fc0d9eec65
Ignore all source build directories that match build* pattern (#3762) 2026-02-02 09:55:45 -06:00
David Andrs
6041ee6ae3
SpatialBox can be constructed via ctor with parameters (#3760) 2026-01-31 17:02:39 -06:00
GuySten
7b4617affb
Fix for plotting model with multi-group cross sections (#3748)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-01-30 06:10:16 +00:00
Paul Romano
f7a734189a
Optionally compute bounding boxes in Mesh.material_volumes (#3731) 2026-01-29 09:20:48 +02:00
GuySten
008d584607
Warn users when setting undefined attributes in ``openmc.Settings`` (#3746)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-01-28 08:02:02 +00:00
Jonathan Shimwell
db426b66ca
Materials name persist when running depletion simulation (#3738)
Co-authored-by: GuySten <guyste@post.bgu.ac.il>
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-01-27 06:06:36 +00:00
Paul Romano
5c502ddb3e
Do not add radioactive Ta180 when calling add_element('Ta') (#3750) 2026-01-26 19:09:58 +02:00
Kevin Sawatzky
3e2f1f521a
Enable fission heating tallies in the random ray solver (#3714) 2026-01-23 10:23:05 -06:00
Olek
73a98b2cc6
Add random_ray_pincell() example model (#3735)
Co-authored-by: John Tramm <john.tramm@gmail.com>
2026-01-23 10:20:25 -06:00
Olek
049a852e52
Random Ray main function and autosetup refactoring (#3733) 2026-01-22 15:21:47 -06:00
GuySten
6b43a298f4
Add n_elements to the MeshBase protocol and deprecate num_mesh_cells (#3745) 2026-01-22 15:04:30 +00:00
GuySten
c5df2bf621
Fix for pandas version 3 (#3743) 2026-01-21 21:57:40 -06:00
GuySten
2691ff8a0f
Fix type hinting and simplify implementation of combine_distributions (#3445)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-01-21 14:33:30 +00:00
Kevin Sawatzky
5847b0de23
Block restriction of libMesh unstructured mesh tallies (#3694) 2026-01-17 04:01:37 +00:00
Paul Romano
51ea89ccc8
Implement depth-awareness when enforcing precedence between union/intersection operators (#3730)
Co-authored-by: GuySten <guyste@post.bgu.ac.il>
2026-01-15 22:23:35 -06:00
GuySten
179048b801
Skip tests on documentation-only changes (#3727)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-01-14 23:24:07 -06:00
Paul Romano
7861adf53b
Add git branching information to AGENTS.md (#3726) 2026-01-14 13:29:24 -06:00
Kevin Sawatzky
5bce5adabc
Support cell densities in the random ray solver (#3720) 2026-01-14 20:02:17 +02:00
GuySten
7106958e00
Simplify IFP message passing (#3719)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-01-13 23:25:33 +00:00
GuySten
65e19c1d53
Fix settings io_format documentation. (#3718)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-01-13 21:31:01 +00:00
Jonathan Shimwell
84a413b130
Speed up reaction rate lookup for FluxCollapseHelper (#3724) 2026-01-13 15:34:07 -05:00
Jack Fletcher
0486e433d2
Source biasing capabilities (#3460)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-01-12 09:51:12 -06:00
Perry
37e2feb34b
Flux Energy Group Conversion using lethargy-weighted redistribution (#3705)
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
2026-01-10 22:04:47 +02:00
Paul Romano
8c8867ea1c
Add --merge-mode-functions=separate to gcovr call in CI (#3716) 2026-01-09 20:05:51 +00:00
GuySten
551bf0730b
Simplify translational periodic boundary conditions (#3697) 2026-01-09 07:56:40 -06:00
Jonathan Shimwell
dfc80c7069
fixing temperatures setting for mgxs (#3712) 2026-01-07 10:54:57 +00:00
Paul Romano
830f075b5c
Update documentation describing HexLattice orientation (#3709) 2026-01-06 22:59:58 +00:00
Jonathan Shimwell
7dceb1d80a
closing mgxs h5py file with context manager (#3707)
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
2026-01-06 22:59:38 +00:00
Jonathan Shimwell
10f2b7534c
Fixing group names in MGXS HDF5 file (#3708) 2026-01-06 20:18:23 +00:00
GuySten
c7d7fa4613
Fix a bug in rotational periodic boundary conditions (#3692)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-01-06 13:29:40 +00:00
GuySten
818fd11b18
Simplify rectangular lattice crossing and correctly handle corner checks (#3703)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-01-06 09:29:46 +00:00
Jonathan Shimwell
60ddafa9b3
Open dagmc model file within a context manager (#3706) 2026-01-05 22:57:05 +02:00
Paul Romano
9c91bddf04
Migrate to SciPy sparse arrays (#3613) 2026-01-02 13:43:25 +02:00
Paul Romano
932f36f411
Add recognized thermal scattering names for JEFF 4.0 and JENDL 5 (#3693) 2026-01-02 12:31:46 +02:00
GuySten
f08326a9ac
Cache cross sections according to the hash of download-xs.sh script (#3701) 2026-01-01 13:30:09 +02:00
Paul Romano
92d7fdb199
Use min/max position members in C++ BoundingBox class (#3699) 2025-12-30 21:31:53 -06:00
GuySten
3f06a42abb
Refactor get_energy_index to prevent repetition (#3686) 2025-12-23 14:18:59 -06:00
Zoe Prieto
a2fd6cc57e
Support rotation in MeshFilter (#3176)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-12-19 22:56:13 -06:00
GuySten
a230b86128
Fix mcpl dependency in test (#3691) 2025-12-18 15:56:43 +00:00
Jonathan Shimwell
e0eb91b955
using id_map in model.plot for more efficient plotting (#3678) 2025-12-17 22:44:53 +02:00
Patrick Shriwise
d118356638
Use MeshBase method to check replicated. Add header for replicated mesh (#3689) 2025-12-17 06:10:07 +00:00
Kevin Sawatzky
bbfa18d72c
Add a command-line argument for output verbosity (#3680)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-12-12 09:29:43 +00:00
GuySten
1b5033dab4
IFP creates fatal error in all run modes except eigenvalue. (#3681) 2025-12-12 00:21:46 -06:00
GuySten
5c4121efd2
Fix hdf5 source_bank struct size. (#3676) 2025-12-11 22:01:10 -06:00
pranav
a62e754bbb
Add user documentation for DAGMCUniverse synchronization (#3674)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-12-10 21:54:28 -06:00
John Tramm
d09fbc61b5
Copilot Bot File (#3651)
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-12-10 09:26:26 -06:00
Lewis Gross
bc1348579f
Generalize RotationalPeriodicBC for X-, Y-, or Z-axis (#3591)
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
2025-12-10 12:16:04 +02:00
Jonathan Shimwell
a9dc84f75a
Allowing material making from class constructor (#3649)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-12-08 19:43:30 +00:00
Jonathan Shimwell
8e06ed8998
Allowing model.id_map to return overlap ID values (#3669)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-12-08 15:54:37 +00:00
GuySten
9b40ea008e
Read IFP settings only in source/eigenvalue run mode (#3673) 2025-12-08 05:39:48 -06:00
Paul Romano
f70febb05f
Update CITATION.cff file (#3671) 2025-12-06 21:54:30 +00:00
Boris Polania
9b675adda5
Introduce SlicePlot and VoxelPlot to replace the Plot class (#3528)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-12-05 20:17:09 +00:00
Jonathan Shimwell
f28139250a
Fixed plotting issue by scaling source locations with axis units (#3668) 2025-12-05 11:02:26 -06:00
Paul Romano
db8d462738
Allow DistribcellFilter to work with apply_tally_results=True (#3667) 2025-12-04 06:53:04 -06:00
John Tramm
ad5a876bee
Improved automatic MGXS generation for random ray (#3658)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-12-03 07:48:38 +00:00
John Tramm
10706510bf
Random Ray Eigenvalue Flux Normalization Change (#3595)
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-02 22:00:32 -06:00
Paul Romano
9e9ab84833
Update C++/CMake policy based on Ubuntu 22.04 (#3666) 2025-12-02 16:11:56 +00:00
GuySten
ef22558f4a
fix a bug in borated_water temperature assignment (#3662) 2025-11-29 16:28:18 +01:00
Paul Romano
7ab92ec142
Fix typo in description of distance_inactive for random ray setting (#3663) 2025-11-28 15:39:08 +00:00
Jonathan Shimwell
dcb7443711
added test to check dagmc name is in xml (#3657) 2025-11-27 10:03:38 -06:00
Paul Romano
27e38e8946
Add release notes for 0.15.3 (#3644) 2025-11-22 23:06:17 +01:00
Paul Romano
d217efa007
Add two MPI barriers in R2S workflow (#3646) 2025-11-20 12:10:04 -06:00
Paul Romano
f544d02e49
Don't write reaction rates in depletion results by default, remove per-stage data for multistage integrators (#3609) 2025-11-19 12:26:57 -05:00
Paul Romano
028f440448
Support MPI parallelism in R2SManager (#3632) 2025-11-19 11:19:27 -06:00
Paul Romano
5c63e0df21
Fix a few warnings, rename add_to_tallies_file (#3639) 2025-11-18 17:57:12 -06:00
Patrick Shriwise
7815d3a680
Fix typo in DAGMC lost particle test (#3634) 2025-11-14 05:27:17 +00:00
Paul Romano
8d618716b5
Avoid multiprocessing Pool when running depletion tests with MPI (#3633) 2025-11-13 17:14:39 -06:00
Michel Saliba
cd5cd35ad9
Addition of a collision tracking feature (#3417)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-11-13 20:35:33 +00:00
Lorenzo Chierici
50bb0df191
depletion-thermochemistry: Redox control transfer rates (#2783)
Co-authored-by: Gavin Ridley <gavin.keith.ridley@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-11-12 16:45:48 -06:00
April Novak
4e24c2d933
Update documentation for particle tracks (#3627)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-11-12 21:59:45 +00:00
Gregoire Biot
2d77544b0c
Adding variance of variance and normality tests for tally statistics (#3454)
Co-authored-by: Ethan Peterson <eepeterson3@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-11-12 11:41:37 -05:00
Marco De Pietri
e5348d3f62
Avoid divide-by-zero in from_multigroup_flux when flux is zero (#3624)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-11-12 10:35:07 +00:00
Patrick Shriwise
5c2bfe771e
Write particle states as separate lines in track VTK files. (#3628) 2025-11-12 00:29:19 -06:00
Patrick Shriwise
8cd3911cbe
Reset DAGMC history when reviving from source. (#3601)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-11-12 06:01:18 +00:00
Perry
c0f302db68
Add energy group structure: SCALE-999 (#3564) 2025-11-07 10:58:40 -06:00
Jon Shimwell
e5c7d0ca88
Adding vtkhdf option to write vtk data (#3252)
Co-authored-by: shimwell <mail@jshimwell.com>
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: rherrero-pf <156206440+rherrero-pf@users.noreply.github.com>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-11-05 16:03:20 +00:00
Paul Romano
bd76fc0566
Fix bug in normalization of tally results with no_reduce (#3619) 2025-11-03 11:11:57 -06:00
Perry
2d8e006c3d
Enable nuclide filters with get_decay_photon_energy (#3614)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-11-03 11:10:30 -06:00
GuySten
fd964bc9b0
Enable specifying reference direction for azimuthal angle in PolarAzimuthal distribution (#3582)
Co-authored-by: shimwell <mail@jshimwell.com>
2025-11-03 09:42:59 +02:00
Paul Romano
5fc289b99d
Automate workflow for mesh- or cell-based R2S calculations (#3508)
Co-authored-by: Ethan Peterson <eepeterson3@gmail.com>
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2025-11-01 00:15:25 +00:00
Paul Romano
4c41766611
Criticality search method on the Model class (#3569) 2025-10-28 11:36:03 -05:00
Makarand More
a74c1424a8
Update check_type calls to accept both str and os.PathLike objects. (#3618)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-10-28 14:50:11 +00:00
Paul Romano
f10d7d9f67
Speed up apply_time_correction by reducing file I/O and deepcopies (#3617) 2025-10-28 09:23:16 +01:00
John Tramm
230db28d39
FW-CADIS Disregard Max Realizations Setting (#3616) 2025-10-28 09:22:37 +01:00
John Tramm
70b5254662
Random Ray Geometry Debug Mode Fix (#3615) 2025-10-27 09:30:54 +01:00
GuySten
c31032cf25
load mesh objects from weight_windows.h5 file (#3598)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-10-21 23:03:27 +00:00
Jonathan Shimwell
3ac5d6f8f5
Allow Path objects in MGXSLibrary.export_to_hdf5 (#3608)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-10-20 16:45:14 +00:00
Paul Romano
055ea15a2d
Clip mixture distributions based on mean times integral (#3603) 2025-10-17 18:09:37 -05:00
GuySten
b94b496113
Ability to source electron/positrons directly (#3404)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-10-15 23:51:59 +00:00
jiankai-yu
e9077b1372
Allow V0 in atomic_mass function (for ENDF/B-VII.0 data) (#3607) 2025-10-14 20:21:11 +00:00
Paul Romano
58c7fbeac6
Re-run flaky tests when needed (#3604) 2025-10-14 07:47:26 -05:00
Paul Romano
3dfa34d2c6
Switch to using coveralls github action for reporting (#3594) 2025-10-07 05:14:37 +03:00
Paul Romano
2c15480cc9
Add user setting for free gas threshold (#3593) 2025-10-06 15:45:26 +03:00
Jonathan Shimwell
50071aa3bd
Speed up time correction factors (#3592)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-10-03 15:09:57 +00:00
Thomas Kittelmann
8a62e7e323
Fix caching issue when using NCrystal materials (#3538)
Co-authored-by: Jose Ignacio Marquez Damian <22483345+marquezj@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-10-02 23:27:36 +00:00
Copilot
7806703c26
Fix random ray source region mesh export when using model.export_to_xml() (#3579)
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: jtramm <1009059+jtramm@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-10-02 22:52:39 +00:00
Perry
91a19cf220
Ensure weight_windows_file information is read from XML (#3587)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-10-02 21:50:42 +00:00
Patrick Shriwise
1dacf4fd2b
Add missing documentation on <source> in depletion chain file format (#3590)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
Co-authored-by: April Novak <novak@berkeley.edu>
2025-10-02 16:48:02 +00:00
John Tramm
3ac64d9a01
Random Ray Base Source Region Refactor (#3576) 2025-10-02 11:02:43 -05:00
Jonathan Shimwell
feefcc6713
Adding tally filter type option to statepoint get_tally (#3584)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
2025-09-30 22:09:15 +00:00
Perry
4011b7a551
Optional separation of mesh-material-volume calc from get_homogenized_materials (#3581)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-09-26 16:46:23 +00:00
Alex Nellis
781dbf9c12
Multi-group capability for kinetics parameter calculations with Iterated Fission Probability (#3425)
Co-authored-by: GuySten <guyste@post.bgu.ac.il>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-09-26 16:27:05 +00:00
Joffrey Dorville
767db7e6a0
Fix IFP implementation (#3580) 2025-09-25 14:58:29 -05:00
GuySten
66e7d8634c
Remove several TODOs related to C++17 support (#3574)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-09-24 09:02:19 +00:00
Kevin Sawatzky
ed433fe1cd
Fix performance regression in libMesh unstructured mesh tallies (#3577) 2025-09-23 11:31:14 -05:00
Paul Romano
8f36ff2b3a
Update find_package calls in OpenMCConfig.cmake (#3572) 2025-09-23 10:06:29 -05:00
Patrick Shriwise
ca63da91b9
Ensure n_dimension_ attribute is set for unstructured meshes. (#3575) 2025-09-19 20:00:51 +00:00
Ilham Variansyah
ecb0a3361f
Combing for fission site sampling, and delayed neutron emission time (#2992)
Co-authored-by: Gavin Ridley <gavin.keith.ridley@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-09-19 08:10:08 +00:00
Paul Romano
007ac8148b
Allow newer Sphinx version and fix docbuild warnings (#3571) 2025-09-19 07:27:41 +03:00
Kevin Sawatzky
607f6babe5
Add distributed cell densities (#3546)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-09-19 04:11:06 +00:00
GuySten
afd9d06074
Fixed a bug when combining TimeFilter, MeshFilter, and tracklength estimator (#3525)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-09-12 20:23:17 +00:00
Jack Fletcher
c7175289eb
PowerLaw raises an error if sampling interval contains negative values (#3542) 2025-09-11 15:57:02 +03:00
Robert Carlsen
ca4295748d
depletion: fix performance of chain matrix construction (#3567)
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
2025-09-11 02:13:28 +00:00
Patrick Shriwise
3665090513
Do not apply boundary conditions when initialized in volume calculation mode (#3562) 2025-09-05 11:34:49 +00:00
Paul Romano
5918564727
Bump up tolerance for flaky activation test (#3560) 2025-09-03 16:35:11 +00:00
GuySten
eaed400987
Fixed a bug in plotting cross sections with S(a,b) data (#3558) 2025-09-02 22:52:27 -05:00
GuySten
00edc77691
Change test order to run unit tests first. (#3533)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-08-30 03:39:46 +00:00
Jonathan Shimwell
ec15803d41
adding ecco 33 (#3556) 2025-08-30 04:39:45 +03:00
GuySten
5529731e2f
Refactor endf_data to be a fixture (#3539) 2025-08-29 07:06:33 -05:00
GuySten
2a278c93a6
Revert "fix broken CI" (#3554) 2025-08-27 23:18:06 +00:00
GuySten
b14eff4760
fix broken CI (#3551) 2025-08-27 19:28:11 +00:00
GuySten
d1df80a210
Leverage particle.move_distance in event advance (#3544) 2025-08-22 09:58:39 -05:00
GuySten
5e3249f006
fix tests that accidentaly got broken (#3543) 2025-08-21 21:13:50 +00:00
Jonathan Shimwell
e878aeb82f
not printing nuclides with 0 percent to terminal (option 2 ) (#3448) 2025-08-21 11:14:21 +02:00
GuySten
68e894c4b0
Fix a bug in time cutoff behavior (#3526) 2025-08-18 09:40:54 -05:00
Rémi Delaporte-Mathurin
c5a7173864
Avoid duplicate materials written to XML (#3536)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-08-18 14:34:12 +00:00
GuySten
75b5813012
Use cached property for openmc.data.Decay.sources (#3535)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-08-18 13:42:38 +00:00
Jonathan Shimwell
14d51e0eba
more helpful error message for dose_coefficients (#3534) 2025-08-14 21:26:27 +03:00
Jonathan Shimwell
f8fa751da0
Adding 616 group structure (#3531) 2025-08-13 16:41:39 +03:00
GuySten
a34365396e
Remove unused special accessors for tallies (#3527) 2025-08-11 10:51:45 -05:00
GuySten
a11021cd07
Consistent XML parsing using functions from _xml module (#3517)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-08-08 17:47:55 +00:00
Boris Polania
e36c0aef2f
Add stat:sum field to MCPL files for proper weight normalization (#3522)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-08-08 14:09:24 +00:00
GuySten
4500f07b44
Remove reorder_attributes from openmc._xml (#3519) 2025-08-08 16:59:22 +07:00
GuySten
4fabed542d
fixed a bug in MeshMaterialFilter.from_volumes (#3520)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-08-08 00:53:33 +00:00
GuySten
a64cc96ed5
Fixed a bug in distribcell offsets logic (#3424) 2025-07-30 12:10:34 -05:00
Jonathan Shimwell
6f5e1347d4
Add test for FW-CADIS based WW generation on a DAGMC model (#3504)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-07-29 11:17:51 +00:00
John Tramm
4cce6ee6c0
Fix for Weight Window Scaling Bug (#3511)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-07-29 10:15:40 +00:00
Rémi Delaporte-Mathurin
836bc487cf
Fix: materials, plots, and tallies cannot be passed as lists (#3513)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-07-29 09:34:03 +00:00
Paul Romano
6b672f772f
Allow already-initialized openmc.lib in TemporarySession (#3505) 2025-07-26 16:42:33 -05:00
Patrick Shriwise
9d9dcc26c5
Update DAGMC and libMesh precompiler definitions (#3510) 2025-07-22 11:10:08 +07:00
Jonathan Shimwell
a649d7bc69
Avoid adding ParentNuclideFilter twice when calling prepare_tallies (#3506)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-07-18 16:23:02 +00:00
Jonathan Shimwell
8be65513b7
Adding material depletion function (#3420)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
Co-authored-by: Micah Gale <mgale@fastmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-07-18 14:37:57 +00:00
Joffrey Dorville
659e43af7d
Enabling MCPL source files to be read when using surf_source_read (#3472)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-07-18 08:47:08 +00:00
Patrick Shriwise
637e04a9ba
Boundary info accessors (#3496)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-07-18 07:51:30 +00:00
Jonathan Shimwell
4483583ddd
automatically finding appropriate dimension when making regular mesh from domain (#3468) 2025-07-18 13:46:13 +07:00
Patrick Shriwise
bca818ced6
Add accessor methods for LocalCoord (#3494)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-07-17 03:29:41 +00:00
Ahnaf Tahmid Chowdhury
5318ea6e2b
Make MCPL a Runtime Optional Dependency (#3429)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-07-17 02:46:39 +00:00
Perry
24f78e6e92
Use auto-chunking for StepResult HDF5 writing (#3498) 2025-07-17 08:40:02 +08:00
Patrick Shriwise
6372c29cfa
Provide a way to get ID maps from plot parameters on the Model class (#3481)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-07-16 08:31:49 -05:00
Shikhar Kumar
58ee8d825d
Update OSX install instructions to point to x64 platform (#3501) 2025-07-15 15:53:52 -05:00
Paul Romano
d700d395de
Update conda install instructions for macOS Apple silicon (#3488) 2025-07-03 22:59:40 +00:00
April Novak
dd8d621f0b
Only show warning if in restart mode. Refs #3477 (#3478) 2025-07-03 10:10:12 -05:00
Nathan Glaser
b6c6ac078b
Add flag to CMakeLists to use submodules instead of searching (#3480)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-07-03 14:49:25 +00:00
Micah Gale
efcf8f649e
Added citation metadata file (#3409) 2025-07-03 10:32:43 +02:00
GuySten
6636b7e32b
fix zam parsing (#3484) 2025-07-02 22:52:39 -05:00
Paul Romano
eb74d497d2
Introduce openmc.lib.TemporarySession context manager (#3475) 2025-07-01 12:43:45 -05:00
Paul Romano
ecfb666db7
Allow spatial constraints on element sources within MeshSource (#3431) 2025-07-01 09:03:28 -05:00
Paul Romano
dab8af5672
Support flux collapse method in get_microxs_and_flux (#3466)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2025-07-01 12:43:28 +02:00
John Tramm
b939f9003b
Stabilize Adjoint Source (#3476) 2025-06-30 10:33:22 +02:00
Ahnaf Tahmid Chowdhury
25d64c9b26
Refactor and Harden Configuration Management (#3461)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-27 00:49:55 +00:00
John Tramm
c116288ea3
Updated Docs to Not Give Specific Python Version Requirement (#3473) 2025-06-26 23:50:26 +00:00
Jonathan Shimwell
5c10214465
added openmc.Material.mean_free_path function (#3469) 2025-06-25 20:29:45 -05:00
Paul Romano
01fa8056d1
Introduce WeightWindowsList class that enables export to HDF5 (#3456) 2025-06-25 13:44:53 -05:00
John Tramm
a6db05ac8b
Optimize Mapping of Random Ray Source Regions to Tallies (#3465) 2025-06-25 08:47:23 -05:00
John Tramm
15dfe7e8b9
Parallelization of Weight Window Update (#3467) 2025-06-25 08:46:40 -05:00
John Tramm
2a0299aec7
Limit Random Ray Weight Window Generation to Final Batch (#3464) 2025-06-24 15:20:26 -05:00
Paul Romano
3a8894c3f8
Fix Dockerfile DAGMC build (#3463) 2025-06-24 11:29:16 +02:00
John Tramm
7c6aaf7204
Fix Weight Window Infinite Loop Bug (#3457)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-23 22:20:36 +00:00
John Tramm
eaef13b9bc
Weight Window Birth Scaling (#3459)
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-23 20:53:27 +00:00
Jonathan Shimwell
3d16d4b100
Adding checks to geometry.plot to avoid material name overlaps (#3458)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-06-19 20:43:45 +00:00
Jonathan Shimwell
3e32aed2da
Fixing crash when calling Geometry.plot when DAGMCUniverse in geometry (#3455)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-18 18:34:07 +00:00
GuySten
1c5aa6559b
fixing expansion of elemental Ta bug (#3443)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-18 15:10:03 +00:00
John Tramm
f31130d367
Prevent Adjoint Sources from Trending towards Infinity (#3449) 2025-06-18 06:34:56 -05:00
Jonathan Shimwell
7a1cafa6c1
adding plot function to DAGMCUnvierse (#3451)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-17 22:36:35 +00:00
Jan Malec
23eab2c89b
Allow specifying number of equiprobable angles for thermal scattering data generation (#3346)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-14 06:39:31 +00:00
Paul Romano
b11eb02655
Change Dockerfile from debian:bookworm-slim to ubuntu:24.04 (#3442) 2025-06-13 20:38:16 +00:00
John Tramm
aeb1052c19
Fix Resetting of Auto IDs When Generating MGXS (#3437) 2025-06-13 00:54:35 +00:00
Jonathan Shimwell
f81962c960
Allowing chain_file to be chain object to save reloading time (#3436)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-12 21:02:35 +00:00
April Novak
6c9c69628c
update units for flux (#3441) 2025-06-12 16:49:59 +00:00
GuySten
e678b1a057
Fix raytrace infinite loop. (#3423)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-11 22:54:04 +00:00
John Tramm
2eeba89992
Apply Max Number of Events Check to Random Rays (#3438)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2025-06-11 12:41:38 -05:00
Paul Romano
f571be87c5
Add user setting for source rejection fraction (#3433) 2025-06-10 22:51:51 -05:00
Patrick Shriwise
f796fa04e0
Adding fix and tests for spherical mesh as spatial distribution (#3428)
Co-authored-by: Paul Wilson <paul.wilson@wisc.edu>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-10 10:01:28 -05:00
John Tramm
56b44aa4e8
Random Ray Missed Cell Policy Change for Adjoint Mode (#3434) 2025-06-10 09:13:08 -05:00
Paul Romano
7fda3eb846
Implement a new MeshMaterialFilter (#3406)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-06-06 16:30:50 -05:00
John Tramm
67aa0def9d
Random Ray External Source Plotting Fix (#3430) 2025-06-06 14:51:39 -05:00
Paul Romano
4943fa3630
Avoid negative heating values during pair production and bremsstrahlung (#3426)
Co-authored-by: GuySten <guyste@post.bgu.ac.il>
2025-06-05 10:45:49 -05:00
GuySten
dadc4fe418
Fix no serialization of periodic_surface_id bug (#3421)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-05 00:07:59 +00:00
Lewis Gross
e14bb884eb
Update _get_start_data to always grab the beginning of timestep time (#3414)
Co-authored-by: Paul Wilson <paul.wilson@wisc.edu>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-04 23:40:55 +00:00
GuySten
ace73ab5de
Fixed a bug in charged particle energy deposition. (#3416)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-06-03 18:02:20 +00:00
GuySten
cb95c784b7
Fix bug where the same mesh is written multiple times to settings.xml (#3418) 2025-05-27 11:04:16 -05:00
Alberto P
a7d1ceba3f
small typo - spelling of Debian (#3411) 2025-05-18 20:28:00 +03:00
Jonathan Shimwell
757617be50
added test for dagmc geometry plot (#3375)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-05-16 13:55:41 +00:00
Lorenzo Chierici
7382b5d1c8
External transfer rates source term (#3088)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-05-12 15:48:21 -05:00
John Tramm
f615441f06
Random Ray Misc Memory Error Fixes (#3405)
Co-authored-by: Hunter Belanger <hunter.belanger@gmail.com>
2025-05-09 22:10:25 -05:00
Jonathan Shimwell
ba834be5c2
added type hints to model file (#3399)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-05-08 06:10:33 +00:00
Patrick Shriwise
c1c5c0b93e
Apply resolve paths to path values in config (#3400) 2025-05-08 00:51:40 +00:00
GuySten
f9dca9a458
Fixing an incorrect computation of CDF of bremsstrahlung photons (#3396)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-05-06 00:04:47 +00:00
Paul Romano
e4f55a57b6
Fix weight modification for uniform source sampling (#3395)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-05-05 20:59:11 +00:00
Gregoire Biot
dc619eac17
Filter weight implementation (#3345)
Co-authored-by: Grego01-biot <grego01@pc-neutronic-06.psfc.mit.edu>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-05-05 15:33:12 -05:00
Patrick Shriwise
9942269a91
Updates to VTK data checks (#3371)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-05-05 18:55:14 +00:00
Amanda Lund
57dc71f530
Map Compton subshell data to atomic relaxation data (#3392)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-05-05 18:05:48 +00:00
Gregoire Biot
1e7d8324ee
Figure of Merit implementation (#3363)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-05-03 08:19:10 -04:00
Amanda Lund
512df2f4ff
Skip atomic relaxation if binding energy is larger than photon energy (#3391)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-05-03 05:46:14 +00:00
Hunter Belanger
a921280fa9
Fix extremely large yields from Bremsstrahlung (#3386)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-05-03 05:10:18 +00:00
Jonathan Shimwell
d0354dbd71
corrected tally name in D1S example (#3383)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-05-03 04:38:23 +00:00
Paul Romano
4138bc34e0
Add option to determine waste disposal rating by nuclide (#3376) 2025-05-02 20:07:43 -04:00
Paul Romano
c17908f24c
Install MCPL using same build type as OpenMC in CI (#3388) 2025-05-02 18:38:10 -05:00
Jonathan Shimwell
820648daee
using reduce chain level to remove need for reduce chain (#3377)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-04-23 06:44:46 +00:00
Patrick Shriwise
5dd6ff6527
Fix negative distances from bins_crossed for CylindricalMesh (#3370) 2025-04-22 23:00:44 -05:00
John Tramm
a113440986
Small Fixes to Allow Random Ray to Work with DAGMC (#3374)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-04-22 17:17:04 +00:00
Joffrey Dorville
47ca2916aa
Kinetics parameters using Iterated Fission Probability (#3133)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-04-14 14:07:48 +00:00
Paul Romano
c1a4d43da8
Add methods on Material class for waste disposal rating / classification (#3366)
Co-authored-by: Ethan Peterson <eepeterson3@gmail.com>
2025-04-11 23:43:27 +00:00
Jonathan Shimwell
bd95b52f4d
Add check for equal value bins in an EnergyFilter (#3372) 2025-04-11 16:35:30 -05:00
John Tramm
cdc254ccf4
Fix for Issue Loading MGXS Data Files with LLVM 20 or Newer (#3368)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-04-10 17:31:33 +00:00
John Tramm
07f5334616
Random Ray Point Source Locator (#3360)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-04-02 05:40:07 +00:00
John Tramm
b67771a3d0
Random Ray AutoMagic Setup (#3351)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-04-01 21:47:49 -05:00
Patrick Shriwise
24655dfd5d
Report plot ID instead of index for unsupported plot types in random ray mode (#3361) 2025-03-31 09:29:30 -05:00
Ahnaf Tahmid Chowdhury
3f3649da08
Handle Missing Tags in Versioning by Setting Default to 0 (#3359)
Co-authored-by: Micah Gale <mgale@fastmail.com>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-03-21 21:33:28 +00:00
Jonathan Shimwell
277390b220
added kg units to doc string in results class (#3358) 2025-03-20 07:00:34 -05:00
Paul Romano
e23760b026
Add release notes for 0.15.2 (#3357) 2025-03-19 09:09:47 -05:00
Joffrey Dorville
18d9f97551
Correcting the size of the displacement list in the SourceSite MPI interface object (#3356) 2025-03-18 21:25:48 +00:00
Kevin Sawatzky
08e7043f8d
Throw an error if a spherical harmonics order larger than 10 is provided. (#3354) 2025-03-18 16:19:15 -05:00
Adam Nelson
58f2a21771
Hotfix: Remove errant openmc.Settings.random_ray check and removed of not useful warning in MG mode (#3344) 2025-03-14 11:57:33 -05:00
Paul Romano
906548db20
Release notes for 0.15.1 (#3340)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-03-07 14:49:36 -06:00
John Tramm
9b5678b5f0
Random Ray Source Region Mesh Subdivision (Cell-Under-Voxel Geometry) (#3333)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-03-07 02:48:31 +00:00
Perry
e8c9134ff6
Add option for survival biasing source normalization (#3070)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-03-06 18:00:29 -06:00
Stefano Segantin
9bfce4ee1c
Determine nuclides correctly for DAGMC models in d1s.get_radionuclides (#3335)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-03-06 21:33:26 +00:00
Jonathan Shimwell
e360cb467e
added stable and unstable nuclides to the Chain object (#3338)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-03-06 16:39:05 +00:00
Stefano Segantin
e12c65dff9
openmc.Material.mix_materials() allows for **kwargs (#3336) 2025-03-06 07:44:10 -06:00
Paul Romano
e878933b90
Fix bug in Mesh::material_volumes for void materials (#3337) 2025-03-06 05:48:04 +00:00
Lewis Gross
557b714d87
add continue feature for depletion (#3272)
Co-authored-by: Connor Moreno <camoreno@wisc.edu>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Lewis Gross <ligross@cnerg-docker-04.neep.wisc.edu>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-03-06 01:07:50 +00:00
Thomas Kittelmann
ced8929128
NCrystal becomes runtime rather than buildtime dependency (#3328)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-03-05 15:45:27 -06:00
ahman24
239f7fed5e
Implement user-configurable random number stride (#3067)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-03-04 17:26:38 -06:00
Paul Romano
e2557bbe22
Update pugixml to v1.15 (#3332) 2025-03-01 02:04:27 +00:00
Paul Romano
39ad29d82e
Fix reading of horizontal field of view for ray-traced plots (#3330)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-02-28 19:50:35 +00:00
rzehumat
8fb48f125f
Manually fix broken links (#3331) 2025-02-28 16:38:31 +00:00
Jonathan Shimwell
c26fde6665
Adding per kg as unit option on material functions (#3329)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
2025-02-28 08:00:40 -06:00
Paul Romano
e060534ff1
Compute material volumes in mesh elements based on raytracing (#3129)
Co-authored-by: Olek <45364492+yardasol@users.noreply.github.com>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-02-26 08:14:53 -06:00
Olek
865c80a5f9
Reflect multigroup MicroXS in IndependentOperator docstrings (#3327)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-25 19:50:00 +00:00
John Tramm
27258c009c
Random Ray Adjoint Source Logic Improvement (#3325) 2025-02-25 10:34:28 -06:00
Paul Romano
1729b3bf91
Fixes for problems encountered with version determination (#3320) 2025-02-25 03:49:47 +00:00
Micah Gale
fed4b28616
Mark a canonical URL for docs (#3324) 2025-02-25 03:49:12 +00:00
Paul Romano
244d630fd2
Clarify effect of CMAKE_BUILD_TYPE in docs (#3321) 2025-02-24 23:25:33 +00:00
John Tramm
cba132c4b4
Random Ray Linear Source Stability Improvement (#3322) 2025-02-24 23:25:11 +00:00
Patrick Shriwise
c794065d46
Fix access order issues after applying tally results from Model.run. (#3313)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-24 22:11:18 +00:00
John Tramm
53066768de
Random Ray Void Accuracy Fix (#3316) 2025-02-24 09:49:51 -06:00
Ahnaf Tahmid Chowdhury
a2a5c2af19
Add Versioning Support from version.txt (#3140)
Co-authored-by: Jonathan Shimwell <mail@jshimwell.com>
Co-authored-by: Paul Wilson <paul.wilson@wisc.edu>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-21 17:48:11 -06:00
Paul Romano
fefe825e65
Handle reflex angles in CylinderSector (#3303) 2025-02-21 17:44:09 -06:00
Patrick Shriwise
6ae2001400
Enable overlap plotting from Python API (#3310)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-21 20:58:37 +00:00
Paul Romano
d643ad0c41
Simulation of decay photons through the D1S method (#3235)
D1S FTW!
2025-02-21 12:47:38 -05:00
Zoe Prieto
2b788ea6e0
Streamline use of CompositeSurface with SurfaceFilter (#3167)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-20 19:51:05 -06:00
Paul Romano
7638661fad
Add nuclides_to_ignore argument on Model export methods (#3309)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2025-02-20 19:07:07 +00:00
Gavin Ridley
aa4de82258
remove gsl-lite dependency (#3225)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-20 01:03:20 +00:00
Gavin Ridley
bcc2a4c5f0
simplify mechanism to detect if geometry entity is DAG (#3269) 2025-02-19 15:58:14 -06:00
Paul Romano
06a88526cf
Relax requirement on polar/azimuthal axis for wwinp conversion (#3307) 2025-02-19 07:48:39 -06:00
Sam Pasmann
d96e6860e6
Randomized Quasi-Monte Carlo Sampling in The Random Ray Method (#3268)
Co-authored-by: John Tramm <john.tramm@gmail.com>
2025-02-19 03:44:15 +00:00
John Tramm
3011a14a13
Random Ray Explicit Void Treatment (#3299)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-18 23:38:59 +00:00
Gavin Ridley
81b7388624
Raytrace plots (#2655)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-18 03:11:54 +00:00
Olek
a5b26de041
Random ray consistency changes (#3298) 2025-02-17 11:02:51 -06:00
Jonathan Shimwell
11587786e0
removed old command line scripts (#3300)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-14 22:58:30 -06:00
Jonathan Shimwell
be4396c12b
adding non elastic MT number (#3285)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-14 16:39:09 +00:00
Jonathan Shimwell
02e225b8f6
Avoid end of life ubuntu 20.04 in ReadTheDocs runner (#3301)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
2025-02-13 22:03:19 -06:00
Paul Romano
0ceb49bc5c
Avoid error in CI from newlines in commit message (#3302) 2025-02-14 00:04:04 +00:00
rherrero-pf
78bf4cf145
Add VTU export for Unstructured meshes (#3290)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-13 21:26:36 +00:00
Patrick Shriwise
18c3112415
Adding tmate action to CI for debugging (#3138) 2025-02-12 07:03:17 -06:00
Jose Ignacio Marquez Damian
e9ddf885e7
Correct normalization of thermal elastic in non standard ENDF-6 files (#3234)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-02-12 00:12:52 +00:00
John Tramm
04393200cc
Random Ray Source Region Refactor (#3288) 2025-02-11 11:23:26 -06:00
Thomas Kittelmann
27ce2ceee3
Updates for building with NCrystal support (and fix CI) (#3274) 2025-02-11 14:18:27 +00:00
Jonathan Shimwell
7e033b25ad
added terminal output showing compile options selected (#3291)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
2025-02-11 09:15:43 +01:00
Paul Romano
6e0f156d33
Fix Tabular.from_xml_element for histogram case (#3287) 2025-02-04 10:38:37 -06:00
Paul Romano
59c398be84
Consolidate plotting capabilities in Model.plot (#3282)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2025-01-31 10:12:24 -06:00
Skywalker
d9c8e594c7
fix the bug in function differentiate_mats() (#3277)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-28 19:44:04 +00:00
Jonathan Shimwell
860d739f4c
Doc typo fix for rand ray mgxs (#3280)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
2025-01-28 10:44:32 -06:00
Skywalker
27f3afefa4
Fix the bug in the Material.from_xml_element function (#3278)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-28 07:57:27 +00:00
Andrew Johnson
8626ce5c43
Rely on std::filesystem for file_utils (#3042)
Co-authored-by: Andrew Johnson <git.vyveu@simplelogin.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-28 07:31:59 +00:00
John Tramm
a8768b7845
FW-CADIS Weight Window Generation with Random Ray (#3273)
Co-authored-by: Olek <45364492+yardasol@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-27 22:54:32 -06:00
Andrew Davis
2bea7f338b
Added missing documentation (#3275)
Co-authored-by: Jonathan Shimwell <mail@jshimwell.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-25 01:59:52 +00:00
Patrick Shriwise
7a18108724
Adjust for secondary particle energy directly in heating scores (#3227)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-25 00:06:15 +00:00
Patrick Shriwise
f207d4220a
Adding methods to automatically apply results to existing Tally objects. (#2671)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-24 22:49:58 +00:00
Patrick Shriwise
7089780026
Add test for flux bias with weight windows in multigroup mode (#3202)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-24 20:29:00 +00:00
John Tramm
560bd22bce
Tweak To Sphinx Install Documentation (#3271) 2025-01-21 16:27:01 -06:00
Paul Romano
9170bf34ad
Update recognized thermal scattering materials for ENDF/B-VIII.1 (#3267) 2025-01-20 14:51:13 +01:00
Paul Romano
3bf1486f49
Fix bug in Surface.normalize (#3270) 2025-01-20 20:18:50 +07:00
Joshua Einstein-Curtis
bd874f1b3e
Update plots.py for PathLike to string handling error (#3261)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-16 09:38:19 -06:00
Patrick Shriwise
32662b409a
Add constant for invalid surface tokens. (#3260)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-16 09:36:13 -06:00
Paul Romano
6d731934f4
Fix bug in WeightWindowGenerator for empty energy bounds (#3263) 2025-01-15 06:35:37 -06:00
Adam Nelson
549cc0973c
Enable the LegendreFilter filter to be used in photon tallies for orders greater than P0. (#3245)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-14 15:51:47 +00:00
azimG
d39a414011
Set Model attributes only if needed (#3209)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-13 06:19:07 +00:00
Patrick Shriwise
cf3f0201a0
Update to a consistent definition of the r2 parameter for cones (#3254)
Co-authored-by: Matthew Nyberg <mnyberg@wisc.edu>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-12 23:50:48 +00:00
Jan Malec
d2edf0ce4e
Fix path handling for thermal ACE generation (#3171)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-11 01:23:35 +00:00
Ethan Peterson
c226c783c4
Bug fix for Polygon 'yz' basis (#3259) 2025-01-10 22:20:00 +00:00
Paul Romano
51f0e6f350
Add Patrick Shriwise to technical committee (#3255) 2025-01-10 15:11:32 -06:00
Joseph F. Specht IV
7c142a361f
Change Zernike documentation in polynomial.py (#3258) 2025-01-10 19:18:03 +00:00
Patrick Shriwise
1eca46f536
Write mesh type as a dataset always (#3253) 2025-01-08 22:15:00 -06:00
Paul Romano
0d4a85d3a8
Remove top-level import of openmc.lib (#3250) 2025-01-08 20:00:57 +00:00
Adam Nelson
8ba66f9fe3
Fix for erroneously non-zero tally results of photon threshold reactions (#3242)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-08 13:58:59 -06:00
Andrew Davis
4492f9db10
Fix type comparison (#3244) 2025-01-08 12:16:01 -06:00
Micah Gale
10a63bbd27
Move to support python 3.13 (#3165) 2025-01-08 11:47:25 -06:00
Jonathan Shimwell
6a5d80efd6
updated docker file to latest DAGMC (#3251) 2025-01-08 16:27:09 +00:00
Patrick Shriwise
8c7200fad3
Enable UWUW library when building with DAGMC in CI (#3246) 2025-01-07 17:31:25 -06:00
Baptiste Mouginot
5ad1a4aa1e
Differentiate materials in DAGMC universes (#3056)
Co-authored-by: Baptiste Mouginot <bam.git.not.reply@gmail.com>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: azimG <azimgivron@yahoo.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-07 21:50:02 +00:00
Masoud
393334829d
Adding '#define _USE_MATH_DEFINES' to make M_PI declared in Intel and MSVC compilers (#3238)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2025-01-07 06:32:05 +00:00
Jonathan Shimwell
3a001d3de2
updated link to log mapping technique (#3241) 2025-01-06 06:40:13 -06:00
Patrick Shriwise
775c415122
Write and read mesh name attribute (#3221) 2024-12-16 15:40:02 +01:00
Jonathan Shimwell
de8132a5a4
adding unstrucutred mesh file suffix to docstring (#3211)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-12-03 07:22:46 +00:00
Kevin Sawatzky
a940216d3a
Ensure libMesh::ReplicatedMesh is used for LibMesh tallies (#3208) 2024-12-02 22:41:41 -06:00
Kevin Sawatzky
a9fe2a05c1
Fix bin index to DoF ID mapping bug in adaptive libMesh meshes (#3206) 2024-11-26 21:23:29 -06:00
Ebny Walid Ahammed
2d988a69a1
External sources alias sampler (#3201)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-11-23 19:10:39 +00:00
Kevin Sawatzky
dd01c40ae1
Enable adaptive mesh support on libMesh tallies (#3185)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2024-11-23 08:09:47 -06:00
Zoe Prieto
ae37d6c0da
Statistical weights in IndependentSource (#3195)
Co-authored-by: Paul Wilson <paul.wilson@wisc.edu>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-11-22 09:16:49 -06:00
John Tramm
172867b1df
Random Ray Adjoint Mode (#3191)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-11-20 20:15:41 +00:00
Patrick Shriwise
fbb115921c
Apply weight windows at collisions in multigroup transport mode. (#3199) 2024-11-18 08:52:59 -06:00
Paul Romano
d30b2e8014
Fix docstring for Model.plot (#3198) 2024-11-13 21:58:22 +00:00
Paul Wilson
58400cbf10
Add PointCloud spatial distribution (#3161)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-11-13 15:39:41 -06:00
Seda Yilmaz
0ecd45c906
Add a vessel composite surface with ellipsoids on top and bottom. (#3168)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-11-12 23:11:59 +00:00
Patrick Shriwise
3e2a042eb1
Fix documentation typo in boundary_type (#3196) 2024-11-12 14:58:15 -06:00
Paul Romano
c9207795d8
Fixes in MicroXS.from_multigroup_flux (#3192) 2024-11-11 16:03:31 -06:00
Nicolas Linden
c05132cb0d
add export_model_xml arguments to Model.plot_geometry and Model.calculate_volumes (#3190)
Co-authored-by: Nicolas Linden <n.linde@naarea.fr>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-11-09 19:33:14 +00:00
azimG
70807b146f
Update surface_composite.py (#3189) 2024-11-09 10:56:37 -06:00
Jonathan Shimwell
9983ee1a7e
allowing varible offsets for polygon.offset (#3120)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-11-08 23:52:40 +00:00
Patrick Shriwise
754f6fa44a
Reset values of lattice offset tables when allocated (#3188) 2024-11-08 15:18:15 -06:00
Paul Romano
339d78c5fa
Fix plot_xs type hint (#3184) 2024-11-06 12:59:25 +01:00
Jonathan Shimwell
7552123c76
added list to doc string arg for plot_xs (#3178) 2024-10-29 17:05:40 +00:00
Rayan HADDAD
9c9a13c48e
enable polymorphisme for mix_materials (#3180)
Co-authored-by: r.haddad <r.haddad@naarea.fr>
2024-10-28 11:28:59 -05:00
Ahnaf Tahmid Chowdhury
82a6f9e40b
Update fmt Formatters for Compatibility with Versions below 11 (#3172) 2024-10-18 18:18:16 -05:00
Jonathan Shimwell
c19b9b1beb
added subfolders to txt search command in pyproject (#3174) 2024-10-18 18:12:18 -05:00
Lorenzo Chierici
dcb25575ca
avoid zero division if source rate of previous result is zero (#3169) 2024-10-14 14:47:22 -05:00
Soha
8263f05e7e
Update quickinstall instructions for macOS (#3130)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-10-11 23:11:27 -05:00
Paul Romano
fc3de1cbef
Add ConicalFrustum composite surface (#3151)
Co-authored-by: Ethan Peterson <eepeterson3@gmail.com>
2024-10-11 07:15:15 -04:00
Paul Romano
04ecf54907
Improve clipping of Mixture distributions (#3154)
Co-authored-by: Ethan Peterson <eepeterson3@gmail.com>
2024-10-11 07:13:10 -04:00
Paul Romano
b4a796e9b4
Avoid writing subnormal nuclide densities to XML (#3144) 2024-10-10 13:39:16 -05:00
Paul Romano
91fd60be69
Immediately resolve complement operators for regions (#3145) 2024-10-10 12:58:15 -05:00
Paul Romano
579777a3e5
Consistency in treatment of paths for files specified within the Model class (#3153) 2024-10-10 12:17:40 -05:00
Ahnaf Tahmid Chowdhury
fb3aaa46ac
Improve Detection of libMesh Installation via LIBMESH_ROOT and CMake's PkgConfig (#3149) 2024-10-10 11:05:32 -05:00
Ahnaf Tahmid Chowdhury
e047138833
Fix for UWUW Macro Conflict (#3150)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2024-10-08 20:57:14 -05:00
Matteo Zammataro
c0acc28038
Add dose coefficients from ICRP 74 (#3020)
Co-authored-by: matteo.zammataro <matteo.zammataro@newcleo.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-10-08 18:29:55 +00:00
Paul Romano
34f04267a5
Update fmt submodule to version 11.0.2 (#3162) 2024-10-05 17:28:22 +00:00
Zoe Prieto
2450eef424
Introduce ParticleList class for manipulating a list of source particles (#3148)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-10-05 06:51:56 +00:00
Patrick Shriwise
9070b8b220
Prepare point query data structures on meshes when applying Weight Windows (#3157)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-10-04 22:59:41 -05:00
Zoe Prieto
c285a2c4ce
Implement filter for cosine of angle of surface crossing (#2768)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-10-04 05:07:03 +00:00
Jonathan Shimwell
1a520c9f4d
Adding material.get_element_atom_densities (#3103)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-10-04 01:37:51 +00:00
rzehumat
836428666d
[docs] theory on PCG random number generator (#3134)
Co-authored-by: Matej Rzehulka <matej.rzehulka@suro.cz>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-10-04 00:51:12 +00:00
Rayan HADDAD
3a5b218728
adapt the openmc-update-inputs script for surfaces (#3131)
Co-authored-by: r.haddad <r.haddad@naarea.fr>
2024-10-03 23:13:18 +00:00
Zoe Prieto
9686851e7a
Write surface source files per batch (#3124)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-10-03 22:32:03 +00:00
Paul Romano
b54de4d761
Fix check for trigger score name (#3155) 2024-10-02 12:12:44 -05:00
azimG
1645e3bb87
Mat ids reset (#3125)
Co-authored-by: azimgivron <azimgivron@gmail.com>
Co-authored-by: azim_givron <a.givron@naarea.fr>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-09-27 00:31:59 +00:00
Jonathan Shimwell
8b77a8dd3b
Adding source option to plot (#2863)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-09-26 22:20:40 +00:00
Patrick Shriwise
890cab5242
Correct failure due to progress bar values (#3143) 2024-09-26 06:45:13 -05:00
Paul Romano
57816e6b8c
Fix a typo in feature request template (#3128) 2024-09-07 22:50:38 +00:00
Patrick Shriwise
bd43d75163
Tweaking title of feature issue template (#3127) 2024-09-05 19:00:08 +00:00
John Tramm
5bc04b5d78
Alternative Random Ray Volume Estimators (#3060)
Co-authored-by: Olek <45364492+yardasol@users.noreply.github.com>
2024-08-23 11:56:26 -05:00
Paul Romano
86fc40a645
Add OrthogonalBox composite surface (#3118) 2024-08-19 10:07:28 -05:00
Paul Romano
39a2d46e26
Implement bounding_box operation for meshes (#3119) 2024-08-18 23:09:32 -05:00
Paul Romano
4ef1faf766
Add delta_function convenience function (#3090) 2024-08-16 11:33:59 -05:00
Lorenzo Chierici
54c28b7705
run microxs with mpi (#3028) 2024-08-16 06:57:32 -05:00
John Tramm
b22656e57f
Fix random ray solver to correctly simulate fixed source problems with fissionable materials (#3106)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-08-16 01:47:05 +00:00
Youssef Badr
e7bc9ba23c
Added error if cross sections path is a folder (#3115) 2024-08-15 16:56:22 -05:00
Zoe Prieto
10c511a0e2
Nuclide temperatures - solution to issue #3102 (#3110) 2024-08-15 15:10:26 +00:00
Jon Shimwell
9483cce0bc
Remove resonance reconstruction and Cython dependency (#3111)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-08-14 14:34:17 +00:00
pitkajuh
ae245e0fb7
Ensure RegularMesh repr shows value for width of the mesh (#3100)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-08-14 06:52:15 +00:00
Jonathan Shimwell
3ef54ec349
Replacing endf c functions with package (#3101) 2024-08-13 23:43:44 -05:00
John Vincent Cauilan
346f751deb
Adjust decay data reader to better handle non-normalized branching ratios (#3080)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-08-13 21:51:30 +00:00
Juan M. Valderrama
9d9b2daceb
Improve description of probabilities for openmc.stats.Tabular class (#3099)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-07-30 19:47:00 +00:00
John Vincent Cauilan
467b8e99ab
Fix ParticleFilter to work with set inputs (#3092) 2024-07-30 07:27:35 -05:00
Jonathan Shimwell
0ad003307a
packages used for testing moved to tests section of pyprojects.tom (#3094) 2024-07-24 07:27:39 -05:00
Jonathan Shimwell
e5cc925db3
removed unused which function in CI scripts (#3095) 2024-07-23 21:42:03 -05:00
John Vincent Cauilan
4c0e08bae8
Replace all deprecated Python typing imports and syntax with updated forms (#3085)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-07-18 17:40:42 +00:00
Paul Romano
32440ad203
Remove use of pkg_resources package (#3069) 2024-07-18 16:54:06 +00:00
Rufus
fd47df4bb2
Linear Source Random Ray (#3072)
Co-authored-by: John Tramm <john.tramm@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-07-16 19:53:40 -05:00
John Vincent Cauilan
58f9092a68
Include batch statistics discussion in methodology introduction (#3076)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-07-16 21:59:16 +00:00
Jonathan Shimwell
2107af5e2f
Moving most of setup.py to pyproject.toml (#3074)
Co-authored-by: Jon Shimwell <jon@proximafusion.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-07-12 18:17:25 +00:00
John Vincent Cauilan
cbec1ab035
Correct openmc.Geometry initializer to accept iterables of openmc.Cell (#3081) 2024-07-10 22:04:09 +00:00
Nicolas Linden
a5a26bb749
Add -DCMAKE_BUILD_TYPE=Release flag for MOAB in Dockerfile (#3077)
Co-authored-by: Nicolas Linden <n.linden@naarea.fr>
2024-07-09 17:30:09 +00:00
John Vincent Cauilan
e74dc5037e
Enforce non-negative percents for material.add_nuclide to prevent unintended ao/wo flipping (#3075) 2024-07-08 16:29:49 -05:00
John Vincent Cauilan
b11f8b73ca
Enforce sequence type when setting Setting.track (#3071) 2024-07-08 09:37:17 -05:00
John Tramm
1b22dd28d4
Random Ray Testing Simplification (#3061)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-07-03 18:28:06 +00:00
John Vincent Cauilan
653d8835dc
Add missing show_overlaps option to plots.xml input file documentation (#3068) 2024-07-03 17:44:20 +00:00
John Tramm
391450ce01
Random Ray Normalization Improvements (#3051)
Co-authored-by: Olek <45364492+yardasol@users.noreply.github.com>
2024-06-28 12:41:20 -04:00
Olek
ac0ad0bac2
Fix hyperlinks in random_ray.rst (#3064) 2024-06-28 09:18:17 -05:00
Ethan Krammer
a8171cbd4e
Implementation of Shannon Entropy for Random Ray (#3030)
Co-authored-by: Ethan Krammer <ethan@DESKTOP-MGFGK9N>
Co-authored-by: John Tramm <john.tramm@gmail.com>
2024-06-27 09:22:10 -05:00
Paul Romano
8ce81d132a
Change version number to 0.15.1-dev (#3058) 2024-06-24 16:29:51 +00:00
Paul Romano
55b52b7ef3
Release of version 0.15.0 (#3050) 2024-06-22 01:28:56 +00:00
Patrick Shriwise
00faa7d698
Set DAGMC cell instances on surface crossing (#3052) 2024-06-21 23:21:13 +00:00
Ethan Peterson
4bd0b09e60
Avoiding more numpy 2.0 deprecation warnings (#3049) 2024-06-20 18:14:55 +00:00
Paul Romano
78ee851990
Determine whether nuclides are fissionable in volume calc mode (#3047)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2024-06-20 09:27:49 -05:00
Paul Romano
390005e841
Make sure time boundary doesn't prevent secondary particle creation (#3043) 2024-06-20 09:26:53 -05:00
Paul Romano
3dff03f824
Resolve warnings related to numpy 2.0 (#3044) 2024-06-19 15:47:08 -05:00
lhchg
3bedd043d0
update math function unit test with catch2 (#2955)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-06-19 15:56:02 +00:00
Joffrey Dorville
ddc9526966
Storing surface source points using a cell ID (#2888)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-06-19 10:11:58 -05:00
Jonathan Shimwell
84f561c1ed
sets used instead of lists when membership testing (#3021) 2024-06-19 14:48:34 +00:00
ybadr16
f6d3ee7a26
Update IsogonalOctagon to use xz basis and update tests (#3045) 2024-06-18 22:56:08 +00:00
pitkajuh
e33e66aa88
Fix #2994, non-existent path causes segmentation fault when saving plot (#3038)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-06-18 06:56:51 -05:00
Lorenzo Chierici
b0732cb6b3
add dagmc fill materials to homogenized materials method (#3026)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-06-18 06:31:07 -05:00
vanessalulla
97537d5e9a
Rename max_splits to max_history_splits, set default value to 1.0e7 (#2954)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-06-18 03:31:34 +00:00
Patrick Shriwise
ce4176deb5
Hexagonal lattice iterators (#2921)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-06-17 21:14:12 +00:00
Paul Romano
89d4dafa5a
Implement policy for Python, C++, and CMake versions (#3035) 2024-06-17 16:00:45 -05:00
Paul Romano
8be35cd7b5
Fix bug with invalidated iterators when enforcing precedence in region expressions (#2950) 2024-06-17 14:25:05 -05:00
John Tramm
5222b343a4
Fixed Source Random Ray (#2988)
Co-authored-by: Gavin Ridley <gavin.keith.ridley@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-06-17 11:02:20 -05:00
Sigfrid Stjärnholm
b1b8a4c328
Set OpenMCOperator materials to the model materials when diff_burnable_mats = True (#2877) 2024-06-12 22:46:18 -05:00
Gavin Ridley
3e16c038fe
only add png or h5 extension if not present in plots.py (#3036)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-06-12 22:33:55 +00:00
Paul Romano
dcb80338c5
Eliminate deprecation warnings from scipy and pandas (#2951) 2024-06-11 22:56:31 -04:00
Paul Romano
1f3280461f
Make sure skewed dataset is cast to bool properly (#3001) 2024-06-11 22:49:01 -04:00
Isaac Meyer
8b33615ac2
fix shannon entropy broken link (#3034) 2024-06-11 21:37:28 -05:00
hsameer481
e971bd1213
added error checking on cylindrical mesh (#2977)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-06-10 21:31:00 +00:00
kmeag
12a278b1ac
Enforce lower_left in lattice geometry (#2982)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-06-10 19:54:59 +00:00
Paul Romano
88f3e4d21f
Allow mesh material homogenization to include or exclude voids (#3000) 2024-06-10 12:19:46 -05:00
Jonathan Shimwell
e6c5f56ee2
Fixing plot xs for when plotting element string reaction (#3029) 2024-06-10 12:18:04 -05:00
Paul Romano
2a53aba1c1
Make sure direction is set when checking source spatial constraints (#3022) 2024-06-03 11:34:37 -05:00
Olek
3420199718
Fix CylinderSector and IsogonalOctagon translations (#3018)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-05-28 16:14:38 +00:00
Patrick Shriwise
0b686e365e
Correction for histogram interpolation of Tabular distributions (#2981)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-05-25 14:11:21 -05:00
Chris Wagner
18cd81a6aa
added extra error checking on spherical mesh creation (#2973)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-05-25 03:27:37 +00:00
Patrick Shriwise
12ecc17997
Hexagonal Lattice Roundtrip (#3003)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-05-25 00:50:59 +00:00
Patrick Shriwise
25e47dea9b
Apply memoization in get_all_universes (#2995)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-05-24 23:56:20 +00:00
Erik B Knudsen
1702b4554b
Restricted file source (#2916)
Co-authored-by: church89 <l.chierici89@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-05-15 15:49:04 -05:00
April Novak
a7d6939c11
Fixes reordering in random ray. Refs #2997 (#2998)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-05-14 06:47:11 +00:00
Paul Romano
cfe210da22
Allow MeshSource to take a 1D array of sources (#2980) 2024-05-03 14:30:49 -04:00
Paul Romano
6e57f1dc72
Compute homogenized materials over mesh elements (#2971) 2024-05-02 13:47:10 -04:00
Travis L
c976653abf
Allow zero bins in tally triggers (#2928)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-05-02 14:00:22 +00:00
Gavin Ridley
d1366c0545
Update random_dist.h comment to be less specific (#2991) 2024-05-02 06:52:39 -05:00
Jonathan Shimwell
5d2b352025
f strings instead of .format for string editing (#2987) 2024-04-29 16:45:37 -05:00
Paul Romano
e8ae7063af
Update CODEOWNERS file (#2974) 2024-04-26 17:54:38 -05:00
Paul Romano
d1d37a5b99
Allow MOAB k-d tree to be configured (#2976) 2024-04-26 05:57:02 -05:00
Jonathan Shimwell
95b15f9522
moved apt get to optional ci parts (#2970)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-25 00:39:51 +00:00
Gavin Ridley
ff50afb19f
Allow pure decay IndependentOperator (#2966)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-24 22:14:37 +00:00
Patrick Shriwise
7936b8a59c
Support track file writing for particle restart runs. (#2957)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-24 22:14:17 +00:00
Patrick Shriwise
f543c007a3
Statepoint file loading refactor and CAPI function (#2886)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-24 17:09:56 -05:00
Catherine Yu
3370ce1978
Print warning if no natural isotopes when using add_element and wrote unit test (#2938)
Co-authored-by: Catherine Yu <cathyy@umich.edu>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-24 21:05:10 +00:00
Jonathan Shimwell
1d56adbc3d
added damage-energy as optional reaction for micro (#2903) 2024-04-24 13:07:36 -05:00
Luke Labrie-Cleary
6b08f75065
make uwuw optional (#2965) 2024-04-24 11:05:11 -05:00
Paul Romano
b54b1e975c
Update bounding_box docstrings (#2972) 2024-04-24 08:02:05 -05:00
Paul Romano
cddb3be139
Add C to list of cmake project languages (#2969) 2024-04-20 15:45:16 +00:00
Gavin Ridley
b53b601edc
Tiny updates from experience building on Mac (#2894)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-20 05:44:40 +00:00
John Tramm
5111aa2621
Random Ray Transport (#2823)
Co-authored-by: Gavin Ridley <gavin.keith.ridley@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-18 22:10:16 +00:00
Aidan Crilly
d53155d234
Added fix to cfloat_endf for length 11 endf floats (#2967)
Co-authored-by: aidancrilly <a.crilly16@imperial.ac.uk>
2024-04-18 16:46:18 +00:00
Paul Romano
2974d53b3c
Update minimum Python version to 3.8 (#2958) 2024-04-15 09:25:32 -05:00
Patrick Shriwise
e77a5247b6
Support UnstructuredMesh for IndependentSource (#2949)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-12 12:14:13 -05:00
Patrick Shriwise
4ba053ca47
Generate Region Plots Directly (#2895)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-12 16:03:19 +00:00
Patrick Shriwise
9fd096b843
Add a max_events setting. (#2945)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-11 17:09:23 +00:00
Jonathan Shimwell
cfebe16127
added check for length of value passed into EnergyFilter (#2887) 2024-04-11 17:35:29 +02:00
Patrick Shriwise
26280bc9d5
Add MPI calls to DAGMC external test. (#2948) 2024-04-11 15:10:45 +02:00
Paul Romano
256150f567
Ensure that two surfaces with different boundary type are not considered redundant (#2942) 2024-04-11 15:00:41 +02:00
Lorenzo Chierici
569c087597
Depletion restart with mpi (#2778)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-09 12:26:03 -07:00
Jonathan Shimwell
fea90e0926
updated package versions in Dockerfile (#2946) 2024-04-08 15:08:15 +00:00
Hunter Belanger
70ba23a367
Update xtl and xtensor submodules (#2941) 2024-04-08 16:08:18 +02:00
Ethan Peterson
463299d04a
Polygon fix to better handle colinear points (#2935)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-08 15:45:01 +02:00
Patrick Shriwise
c85ba93040
Fix distribcell labels for lattices used as fill in multiple cells (#2813)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-08 10:46:59 +00:00
Jonathan Shimwell
db3b6f3e9e
added missing functions and classes to openmc.lib docs (#2847)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-07 16:50:44 +00:00
Jonathan Shimwell
704cfbf1af
Updating docker file base to bookworm (#2890) 2024-04-07 17:27:51 +02:00
Jonathan Shimwell
27bd315f0f
changing y axis label for heating plots (#2859)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-05 09:37:46 +00:00
Ethan Peterson
0aad22d541
Allow get_microxs_and_flux to use OPENMC_CHAIN_FILE environment variable (#2934) 2024-04-05 08:35:15 +02:00
Joffrey Dorville
cc848effe7
Meshborn filter (#2925)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-04-04 21:32:21 +00:00
Paul Romano
1a34ddf121
Fix CMFD to work with scipy 1.13 (#2936) 2024-04-03 20:54:13 -04:00
Paul Romano
9fee6534b6
Prepare for NumPy 2.0 (#2845) 2024-03-26 12:00:06 -04:00
Paul Romano
ce7efa415e
Fix Chain.form_matrix to work with scipy 1.12 (#2922) 2024-03-23 15:29:09 -07:00
Micah Gale
23f19a0310
Implemented contains for BoundingBox containing other BoundingBox (#2906)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2024-03-21 14:22:35 -05:00
Jonathan Shimwell
231fcb651b
Mkdir to always allow parents and exist ok (#2914) 2024-03-17 10:23:24 -05:00
Micah Gale
d10e128e76
Fixed small sphinx typo (#2915) 2024-03-13 23:13:02 +00:00
Micah Gale
539f58d3b1
Changed CI to use latest actions to get away from the Node 16 deprecation. (#2912)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-03-13 11:08:13 -05:00
Yue JIN
0f07420af2
docs: add missing max_splits in settings specification (#2910) 2024-03-12 07:31:34 -05:00
Paul Romano
c4a75f7062
Ensure that Model.run() works when specifying a custom XML path (#2889) 2024-03-11 22:35:32 -05:00
Micah Gale
7ed12788df
Clarifying documentation for Cones (#2892) 2024-03-09 12:49:28 -06:00
Gavin Ridley
aa0516f06b
abort on cmake config if openmp requested but not found (#2893) 2024-03-06 04:55:45 +00:00
Jonathan Shimwell
b75ccd598e
Adding energy axis units to plot xs (#2876)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-02-29 01:31:54 +00:00
Gavin Ridley
02c0a09281
fix expansion filter merging (#2882)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-02-29 00:11:52 +00:00
Jonathan Shimwell
a8f7a61acb
removed unused step_index arg from restart (#2867) 2024-02-28 22:13:45 +00:00
rlbarker
b3a2456f2b
Added checks that tolerance value is between 0 and 1 (#2884) 2024-02-26 16:15:50 -06:00
Jonathan Shimwell
e8f68a0159
adding resulting nuclide to cross section plot legend (#2851)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-02-17 18:21:52 +00:00
Patrick Shriwise
3b575a4daa
Adding openmc.read_source_file (#2858)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-02-16 21:16:36 +00:00
Jonathan Shimwell
5005c3cdc6
type hinting openmc.deplete.abc.py (#2866)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-02-15 07:30:46 +00:00
John Tramm
33c910ddd3
Fix issue with Cell::get_contained_cells() utility function (#2873) 2024-02-14 23:19:10 -06:00
Paul Romano
bf33a9e11b
Add openmc_mesh_get_volumes C API function (#2869) 2024-02-13 06:44:05 -06:00
Paul Romano
f14fc55e60
Add bounding_box property to RectilinearMesh and UnstructuredMesh (#2861) 2024-01-30 21:24:30 -06:00
Patrick Shriwise
cb7ef009b9
Setting surf_source_ attribute for DAGMC surfaces. (#2857)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-01-30 00:59:16 +00:00
Davide Mancusi
09eb33ac21
Fix compilation on CentOS 7 (missing link to libdl) (#2849)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-01-23 09:48:21 -06:00
Paul Romano
e6a36ff796
Add C API function for getting mesh bins for rasterized plot (#2854) 2024-01-23 06:54:08 -06:00
Gavin Ridley
fca4da4bda
Export model.tallies to XML in CoupledOperator (#2840) 2024-01-23 06:53:11 -06:00
Jonathan Shimwell
b97149ddf8
removed error raising when calling warn (#2853) 2024-01-20 13:06:45 -06:00
Patrick Shriwise
0785500bc4
Updating file extension for Excel files when exporting MGXS data (#2852) 2024-01-19 21:32:43 +00:00
Paul Romano
187160d082
Ability to compute material volume fractions over mesh elements (#2802) 2024-01-19 09:01:18 -06:00
Paul Romano
2c5b740738
Update copyright to 2024 (#2846) 2024-01-17 16:10:39 -06:00
Patrick Shriwise
057c33a48e
Expose Material::depletable in the CAPI (#2843)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-01-17 20:46:37 +00:00
Patrick Shriwise
4fa3fbcb19
Make creation of spatial trees based on usage for unstructured mesh. (#2815) 2024-01-17 12:32:05 -06:00
yrrepy
63916067ee
Use huge_tree=True in lxml parsing (#2791)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2024-01-17 06:54:03 +00:00
Paul Romano
d7d2230e5f
Fix locating h5m files references in DAGMC universes (#2842) 2024-01-16 11:12:44 -06:00
Gavin Ridley
5549b58e1f
Geometron (#2744) 2024-01-16 10:35:57 -06:00
Paul Romano
971c5f77a5
Ensure that implicit complement cells appear last in DAGMC universes (#2838) 2024-01-15 20:33:56 +00:00
Gavin Ridley
d8e9d58c5e
Reset timers at correct place in deplete (#2821) 2024-01-11 08:56:44 -06:00
Gavin Ridley
cc15f5e5df
Fix config change not propagating through to decay energies (#2825) 2024-01-11 08:52:33 -06:00
Jonathan Shimwell
63cb7c23a6
added missing meshes to lib docs (#2820) 2024-01-04 19:12:09 +00:00
Paul Romano
b0926ea22c
Prevent underflow in calculation of speed (#2811) 2024-01-03 08:25:33 -06:00
Paul Romano
2e4811b26b
Ensure particle direction is normalized for plotting / volume calculations (#2816) 2023-12-28 14:37:21 -06:00
Patrick Shriwise
411656668f
Provide error message if a cell path can't be determined (#2812) 2023-12-27 08:44:48 -06:00
Jin Whan Bae
f5900293fa
microxs from mg flux and chain file (#2755)
Co-authored-by: Jin Whan Bae <baej@ornl.gov>
Co-authored-by: shimwell <mail@jshimwell.com>
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Olek <45364492+yardasol@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-12-21 21:21:14 -06:00
Patrick Shriwise
53363da3cc
Consolidating number of threads and thread number queries into the openmp interface header (#2809) 2023-12-19 03:31:29 +00:00
Paul Romano
fb65dfd53c
Avoid high memory use when writing unstructured mesh VTK files (#2806) 2023-12-14 10:49:59 -06:00
Paul Romano
3efd24289d
Fix creation of meshes when from loading settings from XML (#2805) 2023-12-13 08:41:51 -06:00
Paul Romano
85c963e223
Move 'import lxml' to third-party block of imports (#2803) 2023-12-13 14:11:32 +00:00
Jonathan Shimwell
552adc005c
added check to length of input args for IndependantOperator (#2799)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-12-12 23:37:53 +00:00
Jonathan Shimwell
15a2199c0d
adding get_all_nuclides method to geometry class (#2796)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-12-12 22:58:17 +00:00
Jonathan Shimwell
124e62fc58
added path arg to integrator.integrate (#2784) 2023-12-12 13:32:09 -06:00
Jonathan Shimwell
a833c176ab
Adding get cylindrical mesh index at specified coordinates (#2782)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-12-12 13:29:43 -06:00
John Tramm
fe07c54bc6
Pytest Update Documentation (#2801) 2023-12-12 13:26:18 -06:00
Paul Romano
3901709141
Do not link against several transitive dependencies of HDF5 (#2797) 2023-12-06 12:35:10 -06:00
John Tramm
ec8850deac
OpenMPMutex "Copying" (#2794) 2023-12-04 12:08:47 -06:00
Patrick Shriwise
e0d03812b9
Mesh Source Class (#2759)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2023-12-02 17:35:23 +00:00
nplinden
47c37f506d
Correctly apply volumes to materials when using DAGMC geometries (#2787)
Co-authored-by: Nicolas Linden <n.linden@naarea.fr>
2023-11-29 05:44:14 -06:00
Paul Romano
87e00f76ed
Add inline to openmc::interpolate (#2789) 2023-11-29 11:20:01 +00:00
John Tramm
1d4cd9b0aa
F90_NONE Removal (MGMC tallying optimization) (#2785) 2023-11-28 15:20:54 -06:00
Patrick Shriwise
e8faccdc93
Call simulation_finalize if needed when finalizing OpenMC (#2790) 2023-11-28 19:56:21 +00:00
Ethan Peterson
8b2698f5c0
Change matrix format to CSC in depletion (#2764) 2023-11-28 07:34:02 -06:00
Paul Romano
b66c6d47f2
In volume calculation mode, only load atomic weight ratio from data files (#2741) 2023-11-28 08:32:25 +00:00
Ethan Peterson
cad9fdc338
Modifications to deplete_with_transfer_rates regression test suite (#2779) 2023-11-27 13:16:34 -06:00
Ethan Peterson
9830efaf2a
change identity matrix format to csr in cram (#2771) 2023-11-21 14:22:42 -08:00
Patrick Shriwise
24e1c95161
Fix lagrangian interpolation (#2775) 2023-11-15 09:49:53 +00:00
Baptiste Mouginot
a3695c784e
Filter material from (#2750)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-11-09 16:05:42 +00:00
nplinden
910d1df1c9
fix unit conversion in openmc.deplete.Results.get_mass (#2761)
Co-authored-by: Nicolas Linden <n.linden@naarea.fr>
2023-11-09 07:13:30 -06:00
Paul Romano
7c14603312
Change version number to 0.14.1-dev (#2760) 2023-11-07 03:04:19 +00:00
Paul Romano
fa2330103d
Release of version 0.14.0 (#2754) 2023-11-06 14:50:16 -06:00
Jonathan Shimwell
847e9b56af
added check for group name (#2752) 2023-11-02 02:30:36 +00:00
Paul Romano
7aaccbbeee
Fix loop over particle coordinate levels for source domain rejection (#2751) 2023-11-01 19:56:28 -05:00
Patrick Shriwise
19f121a45a
Python mesh coordinates reorder (#2730)
Co-authored-by: Ethan Peterson <eepeterson3@gmail.com>
2023-11-01 11:19:27 -06:00
Paul Romano
ac941f79e0
Add RectangularPrism and HexagonalPrism composite surfaces (#2739)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2023-11-01 09:13:40 -05:00
Paul Romano
94f02ae10b
Bump version to 0.14.0-dev (#2740) 2023-10-31 16:55:19 -05:00
Yuvraj Jain
693314d097
Leaky and Albedo Boundary Conditions Implementation (#2724)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-10-30 16:51:31 -04:00
Paul Romano
2c1e304892
Fix bug in selecting data temperatures to read with temperature interpolation (#2734) 2023-10-30 07:30:04 -05:00
Paul Romano
02bd680965
Fix type hint in Materials class (#2745) 2023-10-30 07:29:28 -05:00
Patrick Shriwise
751ea98074
Adding info on clang-format version used in CI (#2748) 2023-10-24 19:24:28 +00:00
Patrick Shriwise
b465a83806
Skip BC check for volume calculations (#2743) 2023-10-23 22:50:21 +00:00
Paul Romano
079629b828
Add section in developer's guide about possible reasons for failing tests (#2738) 2023-10-23 13:48:50 -05:00
Paul Romano
979c164801
Check for invalid domain IDs in volume calculations (#2742) 2023-10-23 13:20:05 -05:00
Patrick Shriwise
e851c57b7b
Correct cylindrical/spherical centroids. (#2736) 2023-10-20 10:14:11 -05:00
Paul Romano
f82bdaa718
Bug fix in Region.from_expression during tokenization (#2733) 2023-10-20 10:04:05 -04:00
Patrick Shriwise
55a682d44d
Property name swap for points in local mesh coordinates (#2732) 2023-10-19 16:29:50 -05:00
ecasglez
7fe80e1490
Fix parsing xml files when running openmc-plotter in regions with comma decimal separator (#2723)
Co-authored-by: ecasglez <emilio.castro@upm.es>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-10-18 06:43:18 -05:00
Patrick Shriwise
bd1c2286f8
Make BoundingBox a mutable type and add convenience methods. (#2717)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-10-17 17:51:05 +00:00
Patrick Shriwise
4d3a198c52
Updates to mesh vertices and centroids (#2711) 2023-10-17 11:21:57 -04:00
Jonathan Shimwell
03c1c6a1f3
moved diff_burnable_mat to model (#2718)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-10-17 07:14:55 -05:00
Patrick Shriwise
00104ce954
Correct openmc.lib wrapper for evaluate_legendre. (#2729) 2023-10-13 00:18:26 +00:00
Baptiste Mouginot
ca49d8167f
disable cross section loading on plot mode (#2690)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-10-07 09:11:03 -05:00
Paul Romano
61c43527e6
Clip low-importance points from discrete distributions (#2715)
Co-authored-by: Ethan Peterson <ethan.peterson@mit.edu>
2023-09-29 21:13:19 -04:00
Jonathan Shimwell
eb3eec8e71
added padding arg to bounding_region (#2701)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-29 15:30:46 +00:00
Paul Romano
fd9172927c
Fix volume calculation IO format docs and sample_external_source bug (#2713) 2023-09-27 15:44:37 -04:00
Patrick Shriwise
f7bb27e0d9
Making z-grid relative to the mesh origin in from_domain. (#2710) 2023-09-27 18:46:53 +00:00
Jonathan Shimwell
d4b989ab7c
ci badge on readme points to develop status (#2712) 2023-09-27 13:31:04 +00:00
John Vincent Cauilan
972dd73ae9
add cross section data caching (#2706) 2023-09-27 06:15:28 -05:00
Paul Romano
0c6da383b6
Ensure that property setters are used in CylindricalMesh and SphericalMesh (#2709) 2023-09-26 22:17:49 -05:00
Ethan Peterson
11a4638849
Faster indexing in MicroXS object (#2702)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-26 07:49:46 +00:00
Xinyan Wang
9cf2f22f24
Apply Weight Window Upon Surface Crossing (#2670)
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-26 05:03:49 +00:00
Jonathan Shimwell
9b7b33c7fa
Ruff comments on code (#2696)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-26 03:37:19 +00:00
Erik B Knudsen
d765bd031f
Limit number of lost particles written to disk. (#2688)
Co-authored-by: John Tramm <john.tramm@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-25 20:12:04 -05:00
Jonathan Shimwell
989875b070
allowing different volume methods for diff mat (#2691)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-26 00:37:25 +00:00
Ethan Peterson
0f429e7ea7
simplifying LEQI docstring math and removing unnecessary operations (#2705) 2023-09-25 16:25:37 -05:00
Ethan Peterson
f4183b0fe3
fixed typo in CF4Integrator docstring (#2704) 2023-09-24 18:49:47 +00:00
Paul Romano
7fdda4aa06
Allow mesh domain in get_microxs_and_flux (#2700) 2023-09-22 08:35:30 -05:00
Gavin Ridley
d4c40aa355
remove meaningless const qualifiers from plot.h (#2695) 2023-09-15 21:46:54 +00:00
Paul Romano
98fe64dd5a
Make sure FluxCollapseHelper loads missing nuclide data (#2694) 2023-09-15 13:19:11 -04:00
Paul Romano
7b0eb9d402
Avoid warning due to bounding box calculation in Universe.plot (#2681) 2023-09-14 05:04:25 +00:00
Patrick Shriwise
ccb76b3dbf
Refactor of translation from mesh handle to index for DAGMC geometry. (#2687) 2023-09-14 02:28:11 +00:00
Jonathan Shimwell
c8c5afaad9
Allowing WeightWindowGenerator to be fully made via constructor (#2686)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-14 02:27:48 +00:00
Olek
bbd7756930
Allow decay only nuclides to be specified in Material for a depletion simulation (#2616)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-14 01:00:52 +00:00
Paul Romano
0cf29f1459
Add type checks on Intersection, Union, Complement (#2685) 2023-09-13 12:49:38 -05:00
Lorenzo Chierici
1c82dfcc1c
Transfer rates multiple destination (#2626)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-13 12:15:44 -05:00
John Tramm
f46d3ee37c
Streamlined URR PRNG stream selection to avoid unneeded store/load ops (#2689) 2023-09-11 12:26:46 -05:00
Hunter Belanger
7505f61b22
Warn users about bad equiprobable angles in S(a,b) (#2675)
Co-authored-by: Gavin Ridley <gavin.keith.ridley@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-06 10:11:24 -04:00
Jonathan Shimwell
be7a9c375a
cylindrical mesh lower left Z value corrected (#2684) 2023-09-05 22:25:47 -05:00
Jonathan Shimwell
a125f81500
fix docker image building for openmc+dagmc combination (#2678) 2023-09-04 23:39:02 -05:00
Jonathan Shimwell
a42b9ba4f9
cy mesh origin from start of z_grid and _r_grid (#2680) 2023-09-04 16:08:47 -05:00
Jonathan Shimwell
2de2023c05
Adding missing origin to CylindricalMesh.from_domain (#2676)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-04 08:52:23 +01:00
Paul Romano
7a13bf6f0f
Update documentation around use of source classes (#2679) 2023-09-02 02:43:19 +00:00
Jonathan Shimwell
20877c61a1
Adding helpful info to keyerror for StepResults.get_material (#2674)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-01 19:32:08 +00:00
Patrick Shriwise
27540c5b8a
Releasing ID after creating dummy universe for cell plotting (#2663)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-09-01 19:31:37 +00:00
Paul Romano
1cae2f712a
Prevent segfault in distance to boundary calculation (#2659) 2023-09-01 09:52:51 -04:00
Paul Romano
d21b653d32
Refactor MicroXS class and usage in IndependentOperator (#2595)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Olek <45364492+yardasol@users.noreply.github.com>
2023-08-31 10:55:21 -04:00
Paul Romano
c93feed91f
Account for integral of underlying distributions when sampling Mixture (#2658) 2023-08-31 10:52:24 -04:00
Paul Romano
eea52238da
Always set html_theme in readthedocs configuration (#2667) 2023-08-25 19:04:16 +01:00
Patrick Shriwise
06d64370c8
Tweaks to Universe::find_cell (#2662) 2023-08-24 17:08:15 -05:00
Jonathan Shimwell
ffbf1b9917
Expose universe plotting for the geometry class (#2661) 2023-08-22 08:45:40 -05:00
Jonathan Shimwell
d687ce419f
added cell name to vol calc print out (#2656) 2023-08-20 20:29:20 +00:00
Patrick Shriwise
8e77a1ffb6
Expose universe plotting for the cell class (#2648)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-08-20 01:35:20 +00:00
Christopher Fichtlscherer
03f98e8f82
time-cutoff version 2.0 (#2631) 2023-08-19 15:20:33 -05:00
Jonathan Shimwell
457bea6f0b
replaced ordereddict with {} (#2641)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-08-19 12:15:11 +00:00
Patrick Shriwise
fa245b0087
Fixing Universe.plot seed. (#2647)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-08-19 05:51:08 +00:00
Jonathan Shimwell
0964024442
added universe plot tests to catch color=None and axis values (#2637)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-08-19 05:20:43 +00:00
rlbarker
b62b62ac31
Added inf check in VolumeCalculation. (#2634)
Co-authored-by: Rosie Barker <rbarker@FL000139.firstlightfusion.local>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-08-19 05:20:22 +00:00
Josh May
471caa5810
Set cross_sections for element expansion in Material.add_element() (#2633)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-08-19 05:20:00 +00:00
Jonathan Shimwell
e8de4c18b8
Improved get step where value error msg (#2654) 2023-08-18 18:35:12 -05:00
Baptiste Mouginot
e332861aac
adding cell name to volume calculation when possible (#2652) 2023-08-18 17:43:59 -05:00
Jonathan Shimwell
1d29adc080
added missing Depletable to __repr__ (#2639) 2023-08-12 11:15:27 -05:00
Paul Romano
46866cb33a
Check for zero fission cross section before sampling fission reaction (#2600) 2023-08-09 02:07:38 -05:00
Christopher Billingham
75a5d84a5b
Cylindrical bb (#2621)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-08-06 09:26:48 +00:00
kevinm387
c340d4b8ec
Add get_decay_heat() function to deplete.Results (#2625)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-08-06 01:51:09 +00:00
Christopher Billingham
cce80fe7da
Spherical bb (#2620)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-08-06 00:31:38 +00:00
Patrick Shriwise
f9c17dd82f
Improving documentation on the return array of openmc.lib.id_map (#2630) 2023-08-05 16:54:09 -04:00
Jonathan Shimwell
557880aefc
Allowing CylindricalMesh and SphericalMesh to be fully made via constructor+ type hints (#2619)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-08-05 16:16:42 -04:00
bscollin
cd13d3471d
Adds MPACT library group structures and documentation to mgxs collection (#2614) 2023-07-25 16:13:00 -05:00
kevinm387
e7d1a13f33
Add get_activity() function to deplete.Results class (#2617)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-07-25 16:11:21 -05:00
Paul Romano
77aedc5b42
Fix mention of cmake flag in troubleshooting guide (#2622) 2023-07-25 14:48:00 +01:00
Paul Romano
3152a2efad
XML read fixes in Plot classes (#2623) 2023-07-25 09:40:52 -04:00
Jonathan Shimwell
d47e9a1092
allowing geometry to be fully made via constructor (#2602)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-07-23 22:26:13 +00:00
Patrick Shriwise
afa6ceb7d7
Adding ability to set additional ww attrs from openmc.lib (#2609)
Co-authored-by: Jonathan Shimwell <mail@jshimwell.com>
2023-07-22 21:18:46 +01:00
Jonathan Shimwell
7397dae12d
Mesh dimension doc string to include order details (#2610) 2023-07-22 01:45:13 +00:00
Jonathan Shimwell
6de37ebc0b
updated docs to use IndependentSource (#2604)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-07-21 23:37:26 +00:00
Jonathan Shimwell
50c3103ca3
Adding type hints to meshes (#2601)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-07-21 17:08:02 +00:00
John Tramm
b5001ee12a
Multigroup Per-Thread Cache Conversion (#2591)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-07-21 07:53:32 +00:00
Paul Romano
8101328d96
Build h5py against Cython < 3.0 in CI (#2613) 2023-07-20 09:23:42 -04:00
Olek
922b3f9de6
Cylindrical prism with optional filleted edges (#2309)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
Co-authored-by: Paul Wilson <paul.wilson@wisc.edu>
2023-07-18 12:11:06 -05:00
Egor Afanasenko
3f9cd0d7cb
Fix R < r torus intersection bug (#2589)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-07-14 21:20:30 +00:00
Paul Romano
c5f551103f
Bank surface source particles in all active cycles (#2592)
Co-authored-by: Jose Ignacio Marquez Damian <22483345+marquezj@users.noreply.github.com>
2023-07-14 18:43:47 +00:00
Patrick Shriwise
0666e3a4f6
Fix for muir std. dev. (#2598) 2023-07-13 20:16:27 -05:00
Nicola Rizzi
3e1a5a552a
Support for NCrystal material in from_xml_element (#2496)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-07-09 23:51:43 -05:00
Christopher Fichtlscherer
e3cd406a9b
Pulse height tally for photons (#2452)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-07-09 22:50:08 -05:00
Paul Romano
97414699fd
Update variable names for depletion 'n' vectors (#2583) 2023-07-06 14:48:36 -05:00
Christopher Billingham
21d88473c8
Simplify infinity check (#2587) 2023-07-05 08:21:36 -05:00
Patrick Shriwise
382bcb2e8e
Updates to object lifecycle for WeightWindows and WeightWindowGenerators (#2582) 2023-06-30 23:29:47 -04:00
Paul Romano
36f229eb01
Remove initial dilute nuclides in MicroXS (#2579) 2023-06-29 11:06:35 +02:00
Jack Fletcher
b6c621f9b4
Change "update_params" to "update_parameters" in test suite: test_ww_gen.py (#2577) 2023-06-28 18:57:44 -04:00
Olek
51cf475723
Add get_mass() function to openmc.deplete.Results (#2565)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-06-26 08:11:41 -05:00
Olek
f200e446aa
Allow transfer rates with nuclides. (#2564)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
Co-authored-by: Lorenzo Chierici <l.chierici89@gmail.com>
2023-06-26 07:23:32 -05:00
Paul Romano
19e4c370e5
Remove use of mgxs module in MicroXS.from_model (#2572)
Co-authored-by: Olek <45364492+yardasol@users.noreply.github.com>
2023-06-25 13:59:47 -05:00
Patrick Shriwise
b5e54468a9
Weight window update method fixes (#2578) 2023-06-25 01:27:54 -04:00
Jonathan Shimwell
b489023340
Option units for geometry plot (#2575)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-06-24 18:03:56 -05:00
Paul Romano
e94d59c0fb
Remove use of sscanf for reading surface coefficients (#2574) 2023-06-24 18:03:23 -05:00
Patrick Shriwise
8cc1c33463
Updating source definitions in examples (#2571) 2023-06-22 21:36:33 -05:00
Paul Romano
93a0855c7f
Fix test error and deprecation warnings from numpy 1.25 (#2573) 2023-06-22 14:26:22 -04:00
Paul Romano
8ce5c7366c
Remove initial dilute nuclides in depletion (#2568) 2023-06-21 14:45:59 +02:00
Jonathan Shimwell
2536cae11b
allowing stepresult to save to a path (#2567)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-06-21 12:07:15 +00:00
Patrick Shriwise
eda39ad9ca
Python source class refactor (#2524)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-06-20 21:27:55 -05:00
Jonathan Shimwell
ee7b95245a
Static errors continuation (#2557)
Co-authored-by: Christina Cai <chrsitinacai48933@gmail.com>
Co-authored-by: christinacai123 <63215816+christinacai123@users.noreply.github.com>
2023-06-16 22:34:02 -05:00
Patrick Shriwise
3eeb131713
Add support for import of wwinp files using cylindrical and spherical meshes. (#2556)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-06-16 15:18:12 -05:00
Patrick Shriwise
0fcb174b2a
Add support for curvilinear elements when exporting cylindrical and spherical meshes to VTK (#2533)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-06-16 15:17:33 -05:00
Patrick Shriwise
96d150a64e
Add C++ format check to GitHub Actions (#2554) 2023-06-15 23:03:46 -05:00
Lorenzo Chierici
c5bc2302eb
Transfer rates mpi (#2551)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-06-15 23:00:20 -05:00
Paul Romano
787b3e0308
Use multiply_density in depletion reaction rate helper classes (#2559)
Co-authored-by: Andrew Johnson <drewejohnson@users.noreply.github.com>
2023-06-14 22:15:22 -07:00
Paul Romano
98c4eb2a2c
Several small documentation updates (#2558) 2023-06-13 07:19:10 -04:00
Paul Romano
6693ff3229
Add issue and pull request templates (#2560) 2023-06-12 10:35:12 -04:00
Paul Romano
bc4e95127c
Fix potential out-of-bounds access in TimeFilter (#2532) 2023-06-11 15:05:16 -05:00
Patrick Shriwise
610a5d8c34
Global Weight Window Generation via CAPI (#2359)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-06-09 10:47:27 -05:00
Paul Romano
c123ce0fa0
New multiply_density option on tallies (#2539) 2023-06-09 08:24:00 -04:00
Jonathan Shimwell
a288e42a06
corrected pixel index for axis height (#2553) 2023-06-08 17:29:55 +00:00
Patrick Shriwise
7479a9022a
Fix spherical coords again. (#2538) 2023-06-06 12:01:59 -04:00
Lorenzo Chierici
19282cb088
Remove misleading warn message from deplete.chain.py (#2544) 2023-06-04 17:10:47 -05:00
Jonathan Shimwell
74fb2801c2
creating parent dirs for output_dir (#2543) 2023-06-02 11:44:43 -05:00
Paul Romano
4c69d913bb
Add virtual destructor on PlottableInterface (#2541) 2023-06-01 01:13:52 +00:00
Paul Romano
16b955f690
Fix docstring for MicroXS class (#2540) 2023-06-01 00:25:26 +00:00
Jonathan Shimwell
6c7f857e1e
Auto pixel calc for universe plot (#2513) 2023-05-23 06:28:16 -05:00
Jonathan Shimwell
d6eac669c8
added mkdir to cwd argument in run (#2523) 2023-05-23 04:25:24 +00:00
Jonathan Shimwell
3a939299ea
adding BoundingBox.extent and RegularMesh.bounding_box (#2507) 2023-05-22 16:32:19 -05:00
Luke Labrie-Cleary
d6ebf26ca6
update catch2 submodule to latest commit (#2522) 2023-05-20 23:05:46 -04:00
Jonathan Shimwell
ec220fa989
updated doc string type for tally.nuclide (#2526) 2023-05-17 19:45:04 +00:00
Jonathan Shimwell
d8dbd9bfca
auto width and origin for edge cases (#2512)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-05-15 22:48:45 +00:00
Lewis Gross
65618384c9
reordered list initialization of constructor in plot.cpp to respect header declaration order (#2519) 2023-05-13 00:44:27 +00:00
Paul Wilson
eeb8a1f451
skip test that fails if VTK is missing (#2517) 2023-05-12 18:22:22 +00:00
Patrick Myers
1cb22075ef
Changed xml to lxml (#2489) 2023-05-09 10:41:04 -05:00
Yue JIN
e3d8982bb9
docs: typo fix (#2514)
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2023-05-04 13:13:00 +00:00
Paul Romano
45006584ca
Fix meaning of "masking" for plots (#2510) 2023-05-03 09:52:40 -05:00
Jonathan Shimwell
4248beff1b
Auto origin and width for plots (#2492)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-05-02 16:41:25 +00:00
Patrick Shriwise
0a950eb623
Reworking Tally::add_filter a bit (#2501) 2023-05-01 22:00:45 -05:00
Huw Rhys Jones
dea5e46c3c
Update neutron_physics.rst (#2504) 2023-05-01 23:51:34 +00:00
Jonathan Shimwell
4cadcbcf02
more flexible cross section plotting (#2478)
---------

Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-27 22:26:21 -05:00
Lorenzo Chierici
43437e9410
TransferRates (old msr continuous capabilities) (#2358)
---------

Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
Co-authored-by: Olek <45364492+yardasol@users.noreply.github.com>
Co-authored-by: yardasol <yardasol@grinnell.edu>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
Co-authored-by: Gavin Ridley <gavin.keith.ridley@gmail.com>
2023-04-27 22:11:17 -05:00
Paul Romano
ad5dc57a96
Merge pull request #2497 from eepeterson/docs_typo
clarify track-length flux estimator
2023-04-27 14:56:28 -05:00
Paul Romano
6dde8af940
Merge pull request #2464 from shimwell/moving_voxel_plot_code
moved voxel plot to api accessible function
2023-04-27 09:36:22 -05:00
Patrick Shriwise
96915c6091
Merge pull request #2498 from paulromano/gcc5-fixes
Fix compilation with gcc 5
2023-04-27 07:27:32 -05:00
Jonathan Shimwell
01a4acdc65
Merge pull request #2487 from gridley/legend_color_fix
pass 0-1 RGB value to matplotlib in universe plot legend
2023-04-27 09:35:46 +01:00
Jonathan Shimwell
4a1ff3350d
Merge pull request #2488 from paulromano/lazy-import-matplotlib
Defer import of matplotlib in multipole.py
2023-04-27 09:35:30 +01:00
Paul Romano
f3969daa4a Ensure compilation with gcc 5 works (refs #2474) 2023-04-26 15:48:23 -05:00
Jonathan Shimwell
15890538a6
Apply suggestions from code review by @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-26 20:08:34 +01:00
Paul Romano
3565cbf5d6
Merge pull request #2494 from aprilnovak/delete-tally
Correct index check for remove_tally.
2023-04-26 13:33:40 -05:00
Jonathan Shimwell
d0e6c8c542
Merge pull request #29 from paulromano/moving_voxel_plot_code
Name change (to_vtk), use pathlib consistently
2023-04-26 19:05:07 +01:00
Paul Romano
dbf33775a6 Name change (to_vtk), use pathlib consistently 2023-04-26 12:34:05 -05:00
Ethan Peterson
7c5b8e2dad clarify track-length flux estimator 2023-04-26 12:57:07 -04:00
Gavin Ridley
b4a6c0419d
Merge pull request #2 from shimwell/adding_legend_test
plt test includes legend with rgb color
2023-04-26 11:46:53 -04:00
Jonathan Shimwell
af5596b6cf plt test includes legend with rgb color 2023-04-26 16:14:14 +01:00
Paul Romano
f2549c9470 Defer a few more matplotlib imports 2023-04-26 09:48:05 -05:00
Jonathan Shimwell
664ae00cdc test to check matplotlib is deferred import 2023-04-26 14:23:44 +01:00
Paul Romano
ec883f0fd8
Merge pull request #2451 from gridley/refactor_write_source_bank
refactor particle source import/export
2023-04-26 06:36:50 -05:00
April Novak
646ef6d322 Correct index check for remove_tally. Refs #2493 2023-04-25 15:40:29 -07:00
Patrick Shriwise
a12480400b
Merge pull request #2475 from shimwell/adding_bounding_box_class
Adding bounding box class
2023-04-25 12:08:39 -05:00
Jonathan Shimwell
c06609cd8d docstring lib.cell.py to match cell.py 2023-04-25 09:49:42 +01:00
Jonathan Shimwell
41f52ea389 Merge branch 'adding_bounding_box_class' of github.com:shimwell/openmc into adding_bounding_box_class 2023-04-25 09:46:17 +01:00
Jonathan Shimwell
517c7436b0
[skip ci] review improvment from @pshriwise
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2023-04-25 09:39:48 +01:00
Ethan Peterson
4f16481e6d
Merge pull request #2457 from paulromano/cruciform-prism
Implement composite surface for generalized cruciform prism
2023-04-24 16:28:19 -04:00
Jonathan Shimwell
895d969eed
Merge pull request #2466 from paulromano/nea-workshop-updates
Miscellaneous updates and improvements from NEA course
2023-04-24 21:15:57 +01:00
Gavin Ridley
8344431ea0 fix my incorrect MPI code 2023-04-24 13:19:29 -04:00
Paul Romano
01cd2cc8dd
Check that distances are all positive
Co-authored-by: Ethan Peterson <ethan.peterson@mit.edu>
2023-04-24 10:53:00 -05:00
Paul Romano
da24021119 Add property for distances in CruciformPrism 2023-04-24 09:48:26 -05:00
Paul Romano
cee1615157 Defer import of matplotlib in multipole.py 2023-04-24 07:01:36 -05:00
Paul Romano
b86e03d849
Fix typo (thanks @gridley)
Co-authored-by: Gavin Ridley <gavin.keith.ridley@gmail.com>
2023-04-21 16:16:43 -05:00
Gavin Ridley
6440153c74 pass 0-1 RGB value to matplotlib in universe plot legend 2023-04-21 16:41:49 -04:00
Gavin Ridley
abfe5ebf99 warning rather than error for weird file name passing to mcpl 2023-04-21 16:09:49 -04:00
Paul Romano
fffdedf5d2
Merge pull request #2455 from stchaker/fix_mac_segfault
avoid python C API segfault on intel mac
2023-04-21 10:55:41 -05:00
Jonathan Shimwell
3ad8781444 Merge branch 'develop' into adding_bounding_box_class 2023-04-21 14:46:52 +01:00
Jonathan Shimwell
7257b2f7fe
Merge pull request #28 from paulromano/adding_bounding_box_class
Refactor BoundingBox implementation
2023-04-21 07:23:57 +01:00
Jonathan Shimwell
63603dbabd
Merge branch 'develop' into moving_voxel_plot_code 2023-04-20 18:19:28 +01:00
stchaker
5713ef700c update mac segfault fix format, fix python settings name 2023-04-20 12:21:10 -04:00
Paul Romano
82ccbe0738
Merge pull request #2482 from shimwell/adding_outlines_to_plot
adding optional outline to plots
2023-04-20 06:21:32 -05:00
Jonathan Shimwell
cb7a443776
Merge branch 'develop' into adding_outlines_to_plot 2023-04-20 08:07:43 +01:00
Paul Romano
c808067764
Merge pull request #2472 from gridley/plot_auto_legend
add auto legend to universe.plot
2023-04-19 20:52:00 -05:00
Paul Romano
5c5c1c83e4
Merge pull request #2470 from youngwki/typehint_geometry_return
Added return types for Geometry class
2023-04-19 20:51:22 -05:00
Christina Cai
bdd34fc64d added deepcopy back in geometry.py 2023-04-19 14:21:12 -04:00
Gavin Ridley
22f4fc0902
Update openmc/universe.py
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-19 12:22:39 -04:00
Gavin Ridley
2f87ce7f27
Update openmc/universe.py
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-19 12:22:29 -04:00
Jonathan Shimwell
a8e7d38555 moved plot outline test, added levels 2023-04-19 16:02:07 +01:00
Jonathan Shimwell
887cfd2e78
[skip ci] review improvment from Paul
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-19 15:59:55 +01:00
Jonathan Shimwell
90e7e1d3f0 added outline to plot testing 2023-04-19 12:22:46 +01:00
Jonathan Shimwell
2487c52d6e working for libpng and no libpng users 2023-04-19 12:00:31 +01:00
Jonathan Shimwell
37f9bdfaca
[skip ci] improve doc string from review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-19 08:07:41 +01:00
Paul Romano
b827a31e61
Merge pull request #2483 from shimwell/adding_axis_labels_to_plot
added plot axis labels
2023-04-18 22:37:31 -05:00
Paul Romano
b5d30ff553 Refactor BoundingBox implementation 2023-04-18 22:26:37 -05:00
Paul Romano
72509b90cf
Merge pull request #2471 from youngwki/typehint_material_return
Added return types for Material class
2023-04-18 20:35:37 -05:00
Paul Romano
2de88f4de2
Merge pull request #2468 from youngwki/typehint_model
Added return types for Model class
2023-04-18 20:35:25 -05:00
Paul Romano
e0abe73182
Merge pull request #2467 from youngwki/typehint
Added type hinting for weight_windows.py
2023-04-18 20:35:08 -05:00
Gavin Ridley
c22448061a warn when passing incorrect file extension to source point write 2023-04-18 17:27:16 -04:00
Gavin Ridley
2ff6c0408e
remove unnecessary comment
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-18 17:24:36 -04:00
Christina Cai
92e2a9e3b7 Merge branch 'typehint_material_return' of https://github.com/youngwki/openmc into typehint_material_return 2023-04-18 13:51:50 -04:00
Christina Cai
dd9f03abd2 trivial change for CI 2023-04-18 13:49:36 -04:00
christinacai123
293f02d991
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-18 13:46:57 -04:00
christinacai123
0280631fe7
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-18 13:46:33 -04:00
christinacai123
f8abaf687a
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-18 13:45:51 -04:00
Gavin Ridley
a02d583ac1 review comments addressed 2023-04-18 11:24:20 -04:00
Jonathan Shimwell
8606e07a67 added plot axis labels 2023-04-18 16:18:03 +01:00
Jonathan Shimwell
f1ce0913b3
remove comment 2023-04-18 15:37:07 +01:00
Jonathan Shimwell
ffaea61874 converting rgb to int 2023-04-18 15:10:49 +01:00
Paul Romano
1afe4294fa
Merge pull request #2479 from pshriwise/improve-trigger-msg
Provide alternative batch estimation message
2023-04-18 06:27:47 -05:00
Patrick Shriwise
f08510119c Applying code formatter 2023-04-18 00:38:33 -05:00
Gavin Ridley
ad33834e0f
default to legend label using ID if no name given
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2023-04-17 12:18:03 -04:00
Gavin Ridley
f65de85f9f
add versionadded for legend kwarg
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2023-04-17 12:17:09 -04:00
Gavin Ridley
e4c3323601
remove unnecessary error checking
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2023-04-17 12:15:29 -04:00
Gavin Ridley
3880d1cec8
line length suggestion
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2023-04-17 12:14:52 -04:00
Jonathan Shimwell
de695f4b63 Merge branch 'develop' into adding_outlines_to_plot 2023-04-17 16:37:33 +01:00
John Tramm
2b23b7366a
Merge pull request #2481 from paulromano/vectfit-ci-fix
Install vectfit in CI without build isolation
2023-04-17 10:34:59 -05:00
Paul Romano
339b4600ea
Merge pull request #2434 from pshriwise/dagmc-lp-test
Additional DAGMC test for lost particles
2023-04-17 09:41:27 -05:00
Jonathan Shimwell
95a07b8085 adding optional outline to plots 2023-04-17 15:13:56 +01:00
Paul Romano
36a54c896a Install wheel for vectfit 2023-04-17 06:59:40 -05:00
Paul Romano
5ba3569b3a Install vectfit in CI with no-build-isolation 2023-04-17 06:37:39 -05:00
Gavin Ridley
b52e1f106c
const int by value is pointless
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-15 22:35:14 -04:00
Gavin Ridley
355b6f4e88
const int by value is kinda pointless
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-15 22:34:45 -04:00
Gavin Ridley
30e2bfb2f9 warn people rather than fatal error if specifying a weird file extension 2023-04-15 22:31:53 -04:00
Gavin Ridley
4c7876beb9 allow directories containing periods in file extension grabber 2023-04-15 22:26:34 -04:00
christinacai123
8819b5c1c4
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-15 16:12:38 -04:00
Christina Cai
5658cd88b1 Added xml.etree to first block of imports 2023-04-15 16:02:59 -04:00
christinacai123
c9a64e6fe0
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-15 16:01:04 -04:00
christinacai123
55b4df553c
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-15 15:54:41 -04:00
Christina Cai
b4b4ff7948 added Pathlike to wwinp_to_wws 2023-04-15 15:49:16 -04:00
christinacai123
6b20df9652
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-15 15:44:02 -04:00
Gavin Ridley
62708ab3ad PR comments addressed 2023-04-15 13:01:01 -04:00
Gavin Ridley
f202377fb7 add west const and enforce in clang format 2023-04-15 12:50:30 -04:00
Gavin Ridley
e1102b6408 move file_utils to its own source file 2023-04-15 11:52:36 -04:00
Patrick Shriwise
405717a3cf Modifying batch estimation message if the uncertainty ratio is inf 2023-04-14 16:41:51 -05:00
Gavin Ridley
489eb59c99 alphabetize source files in cmakelists 2023-04-14 13:00:39 -04:00
Gavin Ridley
5ca6ee0654
use auto rather than std::string::size_type
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-14 12:39:09 -04:00
Gavin Ridley
0738a359c2
if/else -> ternary
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-14 12:38:46 -04:00
Gavin Ridley
8bc434a67d
move legend outside image
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2023-04-14 12:36:24 -04:00
Jonathan Shimwell
c4aafdd508 added ll and ur as suggested by @pshriwise 2023-04-14 17:11:44 +01:00
Jonathan Shimwell
b3ff7f26e3 removed commented out code 2023-04-14 14:06:15 +01:00
Jonathan Shimwell
6eb26b80c6 implemented BoundingBox class 2023-04-14 13:11:01 +01:00
Patrick Shriwise
3a22be87a9 Removing unecessary nuclides 2023-04-13 22:05:38 -05:00
Patrick Shriwise
304443070b
Apply suggestions from @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-13 22:01:16 -05:00
christinacai123
966f3e51a8
Apply suggestions from code review
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2023-04-13 17:26:26 -04:00
Paul Romano
ae615c02d9
Merge pull request #2435 from zoeprieto/ncrystal_plotter
Add support for ncrystal materials
2023-04-13 15:14:54 -05:00
Gavin Ridley
6b03287d52 add auto legend to universe.plot 2023-04-13 16:09:07 -04:00
Patrick Shriwise
d24ae2fe1f Some cleanup of the DAGCell::distance method and explanation for lost particle condition 2023-04-13 10:27:01 -05:00
Patrick Shriwise
9da13a9087 Adding function for root universe comparison 2023-04-13 10:17:05 -05:00
Patrick Shriwise
6b98142a12 Use openmc.UniverseBase in lattice module 2023-04-13 10:17:05 -05:00
Patrick Shriwise
55473ee8a1 Adding DAGMC testfor lost particles 2023-04-13 10:17:05 -05:00
Paul Romano
aed797631b Fix failing tests 2023-04-13 07:25:19 -05:00
Paul Romano
93de45d044
Merge pull request #2469 from tjlaboss/2016_2020
Update the 2016 references to 2020
2023-04-12 20:37:27 -05:00
christinacai123
e3c0f6fcb4
Merge branch 'develop' into typehint_model 2023-04-12 20:54:19 -04:00
John Tramm
f7c2961436
Merge pull request #2465 from paulromano/model-fixes
A few improvements related to the Model class
2023-04-12 14:33:42 -05:00
Christina Cai
5fc51209ce added return types for material.py 2023-04-12 15:21:49 -04:00
Christina Cai
f7457d6427 fixed circular import error 2023-04-12 15:11:13 -04:00
Christina Cai
3692e7331f added return types for geometry.py 2023-04-12 14:41:14 -04:00
Travis J. Labossiere-Hickman
7ca82b59aa Update the 2016 references to 2020 2023-04-12 12:22:45 -06:00
Christina Cai
1a0f442bba added return types for model.py 2023-04-12 14:22:17 -04:00
Christina Cai
c1c6865026 added type hinting for weight_windows.py 2023-04-12 14:00:48 -04:00
Jonathan Shimwell
a0d8d1961e running plot test in tmp dir 2023-04-12 12:42:56 +01:00
Paul Romano
f23620896d Use Catch2_FOUND in CMakeLists.txt 2023-04-11 13:33:14 -05:00
Paul Romano
3125a28bad Remove mention of mailing list in README.md 2023-04-11 13:33:14 -05:00
Paul Romano
ec20a0cbaf Add missing openmc.lib functions to documentation 2023-04-11 13:33:14 -05:00
Paul Romano
08df830700 Use default filename in deplete.Results() 2023-04-11 13:33:14 -05:00
Paul Romano
9ec43809db Change DataLibrary to behave like list and add remove_by_material method 2023-04-11 13:33:11 -05:00
Paul Romano
a87b88a488 Fix CellInstanceFilter docstring 2023-04-11 13:23:13 -05:00
Paul Romano
39bc94a1a1 Allow mgxs.EnergyGroups() to accept group structure name 2023-04-11 13:23:13 -05:00
Paul Romano
5a0b679df8 Don't use a fixed default seed for pack_spheres 2023-04-11 13:23:12 -05:00
Paul Romano
a5d724aa2e Check whether points in Plane.from_points lie along a line. 2023-04-11 13:23:12 -05:00
Paul Romano
c907c85675 Improve error message regarding particle filter 2023-04-11 13:23:12 -05:00
Paul Romano
f5ad0466cd Allow Model.run to pass kwargs to export methods 2023-04-11 13:18:34 -05:00
Paul Romano
35ef5b06f8 Allow plots.xml to be read if model.xml doesn't contain plots 2023-04-11 13:18:34 -05:00
Paul Romano
d1036561a9 Make clear that passing model XML is valid on command line 2023-04-11 13:18:34 -05:00
Paul Romano
44a57b9a6f Improve error message about missing settings.xml 2023-04-11 13:18:30 -05:00
Jonathan Shimwell
eef21b65ca moved voxel plot to api accessible function 2023-04-11 17:59:43 +01:00
Paul Romano
04b458a7ed
Merge pull request #2462 from youngwki/pythonhint
Added type hints for WeightWindows class
2023-04-10 20:33:38 -05:00
christinacai123
4cc2c99f06
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-10 12:56:51 -04:00
christinacai123
6d0e009acf
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-04-10 12:55:54 -04:00
Christina Cai
b96914cb29 added return types 2023-04-07 15:32:02 -04:00
Paul Romano
4213656284
Merge pull request #2460 from aprilnovak/new_feature
Fix documentation typo in Cylinder.from_points.
2023-04-07 19:24:38 +02:00
April Novak
69f1ef43f9 Fix documentation typo in Cylinder.from_points. Closes #2459 2023-04-07 10:28:04 +02:00
Patrick Shriwise
e0d32e6a29
Merge pull request #1926 from gridley/projection_plots
Projection plots
2023-04-05 15:08:37 -05:00
Gavin Ridley
7fb21d7e79 add repr to projection plot 2023-04-05 12:03:03 -04:00
Gavin Ridley
a92f2d1f9f avoid segfault with idiomatic thresholding, rays through pixel centers 2023-04-05 11:50:45 -04:00
Gavin Ridley
5c4144d520
idiomatic thresholding
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2023-04-05 11:05:30 -04:00
Patrick Shriwise
62859d39ba Ignoring lost particles in DAGMC universes if in plotting mode 2023-04-04 22:11:11 -04:00
Gavin Ridley
abdc9be9a0 guard dagmc function call for non dagmc build in plotting 2023-04-04 22:11:11 -04:00
Patrick Shriwise
a8ed9bde8f Hacks to get project plots working w/ DAGMC 2023-04-04 22:11:11 -04:00
Patrick Shriwise
adf2047b6e Refactor of DAGMC next_cell 2023-04-04 22:11:11 -04:00
Gavin Ridley
5e47f9daa4 fix failing tests, remove redundant PlotTestHarness code 2023-04-04 22:11:10 -04:00
Gavin Ridley
61cab3009a PR comments addressed 2023-04-04 22:06:54 -04:00
Gavin Ridley
0a71d690b4 Update docs/source/usersguide/plots.rst
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2023-04-04 22:06:54 -04:00
Gavin Ridley
3b8f1ee1fe Update docs/source/usersguide/plots.rst
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2023-04-04 22:06:54 -04:00
Gavin Ridley
74fc00fc43 now passing tests again 2023-04-04 22:06:54 -04:00
Gavin Ridley
c8b8f1b9b9 regold projection plot regr test 2023-04-04 22:06:54 -04:00
Gavin Ridley
bd2de0372f projection plot docs 2023-04-04 22:06:54 -04:00
Gavin Ridley
f1b92603c8 update projection plot regr test 2023-04-04 22:06:54 -04:00
Gavin Ridley
ed5837202b add old wireframing behavior if not listing ids 2023-04-04 22:06:54 -04:00
Gavin Ridley
6726cc378f add unit test, select wireframing by id 2023-04-04 22:06:54 -04:00
Gavin Ridley
31174736e9 fix for non-OMP compile 2023-04-04 22:06:54 -04:00
Gavin Ridley
a0401906cd parallel projection plotting now matches single thread results 2023-04-04 22:06:54 -04:00
Gavin Ridley
030c3af9e4 parallelization of projection plots almost works except edge case 2023-04-04 22:06:54 -04:00
Gavin Ridley
c9e296d2a9 update tests 2023-04-04 22:06:54 -04:00
Gavin Ridley
a832fc8b94 adjustable wireframe thickness 2023-04-04 22:06:54 -04:00
Gavin Ridley
a030aaa59d fix projection plot tests 2023-04-04 22:06:54 -04:00
Gavin Ridley
76cc722090 add option to do orthographic projection 2023-04-04 22:06:54 -04:00
Gavin Ridley
d51fd873ab read user-provided plot names, also more sophisticated file extension checking 2023-04-04 22:06:54 -04:00
Gavin Ridley
071b6fa796 pick up on cell edges, not just boundaries 2023-04-04 22:06:54 -04:00
Gavin Ridley
bad79975b0 make wireframes not spotty 2023-04-04 22:06:54 -04:00
Gavin Ridley
d5aafc91cb projection plots nominally working 2023-04-04 22:06:54 -04:00
Gavin Ridley
5105a8423d further refactor of plots, start ProjectionPlot 2023-04-04 22:06:52 -04:00
Gavin Ridley
e2dedf5461 move common with projection plot to base class 2023-04-04 22:05:08 -04:00
stchaker
e3e659ca83 avoid python C API segfault on intel mac 2023-04-04 16:58:28 -04:00
Paul Romano
95e3f94630 Implement CruciformPrism composite surface 2023-04-04 22:49:11 +02:00
Gavin Ridley
5a8e1cc988 fix typo 2023-04-01 00:22:50 -04:00
Gavin Ridley
30ed602009 update documentation 2023-03-31 23:59:04 -04:00
Gavin Ridley
5aa1d256bb
Merge branch 'develop' into refactor_write_source_bank 2023-03-31 14:17:53 -04:00
Gavin Ridley
2172907bcf refactor particle source import/export 2023-03-31 14:17:04 -04:00
zoeprieto
2d90f9bd15
Merge pull request #2 from openmc-dev/develop
Update branch
2023-03-30 15:27:50 -03:00
Patrick Shriwise
e49c2c7d29
Merge pull request #2447 from paulromano/move-to-0.13.4-dev
Change version number to 0.13.4-dev
2023-03-30 09:47:00 -05:00
Patrick Shriwise
682ce5c3a6
Merge pull request #2444 from aprilnovak/material-clone
Clone material
2023-03-30 08:51:05 -05:00
zoeprieto
9ebacff23a
Update docstrings
Added description of ncrystal_cfg
2023-03-29 16:56:12 -03:00
zoe prieto
dc2a9a8129 Resolved conflict 2023-03-29 16:53:37 -03:00
Paul Romano
5fcb7208df Change version number to 0.13.4-dev 2023-03-29 14:41:03 -05:00
aprilnovak
c3fdf4edd2 Group openmc::model lines together. Refs #2442 2023-03-29 14:40:37 -05:00
Patrick Shriwise
27cb0dc979
Merge pull request #2441 from paulromano/release-0.13.3
Release of version 0.13.3
2023-03-29 14:09:07 -05:00
Paul Romano
e2373c833b Show MCPL and NCrystal in openmc --version 2023-03-29 06:51:01 -05:00
aprilnovak
ca061bc7e5 Return non-null. 2023-03-28 19:20:49 -05:00
aprilnovak
b84a021c58 Improve documentation. Refs #2442 2023-03-28 13:50:02 -05:00
Paul Romano
e7a688a867 Update Spack installation instructions 2023-03-28 13:34:14 -05:00
Paul Romano
8a5fb8a8b0 Update version number to 0.13.3 2023-03-28 13:34:14 -05:00
Paul Romano
2f50599d4f Update install instructions 2023-03-28 13:34:14 -05:00
Paul Romano
75dcf5b9a7 Add release notes for 0.13.3 2023-03-28 13:34:14 -05:00
Paul Romano
7bbf5466e6 Add missing versionadded directives 2023-03-28 13:34:14 -05:00
Paul Romano
f77aec1511
Merge pull request #2443 from pshriwise/sph-cyl-mesh-fix
Improvements to spherical/cylindrical mesh radial boundary coincidence with geometry
2023-03-28 11:33:46 -07:00
Patrick Shriwise
6cb4401230 Correcting surface type in cylinder tests 2023-03-28 10:11:14 -05:00
Patrick Shriwise
86e9a4bd4b Adding constants for coincidence checking 2023-03-28 08:47:42 -05:00
Patrick Shriwise
e5863eec1b Correcting variable name 2023-03-28 07:35:22 -05:00
aprilnovak
fa222a4b31 Address review comments. 2023-03-27 19:23:04 -05:00
aprilnovak
a44c1f89de Address review comments. Refs #2442 2023-03-27 19:21:30 -05:00
aprilnovak
e41ae3604e Clone material. Refs #2442 2023-03-27 18:36:49 -05:00
Patrick Shriwise
26c031a041 Run tests in tmpdir to keep repo clean 2023-03-27 16:54:42 -05:00
Patrick Shriwise
63fa42843b Removing unused print statements 2023-03-27 16:50:18 -05:00
Patrick Shriwise
ab403b2fc8 Improvements to tests 2023-03-27 16:48:35 -05:00
Patrick Shriwise
13a9e8fae4 Adding tests with void geometry for cylindrical and spherical mesh 2023-03-27 16:48:35 -05:00
Patrick Shriwise
160360a2a6 Remove old condition for cylindrical mesh 2023-03-27 16:48:35 -05:00
Patrick Shriwise
6910e36572 Adjustment to coincidence checking and case for r_grid[0] == 0 2023-03-27 16:48:35 -05:00
Ethan Peterson
3068d0cbbb
Merge pull request #2440 from paulromano/library-nuclide-hotfix
Update reference inputs for mgxs_library_specific_nuclides test
2023-03-26 21:27:36 -04:00
Paul Romano
b7250db6e1 Update reference inputs for mgxs_library_specific_nuclides test 2023-03-26 16:03:55 -05:00
Paul Romano
99c6514609
Merge pull request #2432 from guyshtot/library_nuclides_specification
Library nuclides specification
2023-03-26 12:27:48 -05:00
Patrick Shriwise
52f8618dab
Merge pull request #2439 from paulromano/cyl-sph-mesh-coincident-bugfix
Fix bug in cylindrical and spherical meshes when grid boundary is coincident with cell boundary
2023-03-25 20:58:32 -05:00
Paul Romano
5b7fb427d3
Apply @pshriwise suggestion adding 0.1 to scale
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2023-03-25 15:36:11 -05:00
Paul Romano
2630dbf4bc
Merge pull request #2362 from eepeterson/polygon_fix
try to constrain triangulation
2023-03-25 15:30:42 -05:00
Paul Romano
ec6f15dfa1
Merge pull request #2404 from eepeterson/export_model_xml_on_run
adding export_to_model_xml to model.run
2023-03-25 15:29:19 -05:00
Paul Romano
c5fd211bb2
Merge pull request #2436 from kkiesling/hybrid_depletion_tally
Fix hybrid depletion direct tally error if nuclides are not present in material
2023-03-25 12:07:43 -05:00
Paul Romano
2aef18c02a Loosen tolerance on coincidence check for cyl/sph meshes and parametrize tests 2023-03-25 11:55:53 -05:00
Kalin Kiesling
2d6938553a
Update tests/unit_tests/test_deplete_activation.py
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-03-25 09:13:58 -05:00
Ethan Peterson
b174e7896f
Merge pull request #8 from eepeterson/update_old_xmls
Update old xmls
2023-03-25 07:57:46 -04:00
Ethan Peterson
04806858ca update old tests to use new model.xml 2023-03-25 07:55:35 -04:00
guyshtot
3d1811a64a Changed merge=False to merge=True in mgxs_library_specific_nucides test to speed up the test. 2023-03-25 13:57:08 +03:00
guyshtot
4e7cae8b98
Update tests/regression_tests/mgxs_library_specific_nuclides/test.py
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-03-25 13:52:37 +03:00
guyshtot
ff9d2283c4
Update tests/regression_tests/mgxs_library_specific_nuclides/test.py
Remove double spaces at MGXS types in a test

Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-03-25 13:52:23 +03:00
guyshtot
00657ccf87
Update openmc/mgxs/library.py
apply CR suggestion

Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-03-25 13:50:06 +03:00
Ethan Peterson
11e618fe81 adding export_to_xml to run and updating tests 2023-03-24 18:54:54 -04:00
Ethan Peterson
7200d42644
Merge pull request #2433 from paulromano/photon-from-ace-fix
Handle zero photon cross sections in `IncidentPhoton.from_ace`
2023-03-24 12:58:28 -04:00
Ethan Peterson
2f5428f739
Update openmc/model/surface_composite.py
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2023-03-24 12:13:00 -04:00
Patrick Shriwise
222d92de83
Merge pull request #2431 from paulromano/py3.11-ci
Add Python 3.11 to CI matrix
2023-03-24 09:29:13 -05:00
Kalin Kiesling
7f68462e3a add nuclide that is not in model; (fails locally) 2023-03-23 15:43:18 -05:00
Kalin Kiesling
e93dd66430
eliminate set/list redundancy
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-03-23 15:07:32 -05:00
Paul Romano
e7eb746dc4 Always use quotes for python-version in ci.yml 2023-03-23 14:08:03 -05:00
Paul Romano
10787a2da6 Account for coincident position in find_r_crossing 2023-03-23 13:37:26 -05:00
Paul Romano
938923be41
Merge pull request #2428 from gonuke/mesh_spatial_Discrete
Use Discrete distribution for sampling a mesh source
2023-03-23 07:12:04 -05:00
guyshtot
a704ec73f2 Applied CR suggestion 2023-03-23 13:12:36 +02:00
guyshtot
675ec5f9ab Added test for the use of a Library with specified nuclides 2023-03-23 13:07:21 +02:00
Ethan Peterson
572e765e90
Merge pull request #2256 from RemDelaporteMathurin/centre_for_cylinder_spherical_meshes
Centre for cylinder & spherical meshes
2023-03-23 00:01:30 -04:00
Paul Wilson
9bb1ef4369
Update src/distribution.cpp
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-03-22 21:42:06 -04:00
Patrick Shriwise
d3fb65ae12
Merge pull request #2410 from paulromano/decay-tabular-warning
Enable generation of JEFF 3.3 depletion chain
2023-03-22 15:55:37 -05:00
Paul Romano
3f2831cc13
Merge pull request #2413 from shimwell/plotting_with_automatic_data_type
removing need for user to specify data_type arg when plotting xs
2023-03-22 15:38:29 -05:00
Kalin Kiesling
5160417e3e load any nuclide requested that is not present in materials prior to constructing tally 2023-03-22 12:45:33 -05:00
zoeprieto
094eb958c1
Add support for ncrystal materials 2023-03-22 12:44:56 -03:00
Rémi Delaporte-Mathurin
10f2a945ca
Merge branch 'develop' into centre_for_cylinder_spherical_meshes 2023-03-22 10:08:32 -04:00
Rémi Delaporte-Mathurin
a091bee5d9
Merge pull request #7 from paulromano/pr-2256-docs
Update IO format docs for meshes
2023-03-22 10:07:11 -04:00
Paul P.H. Wilson
72a6f77b0c use correct part of parameters 2023-03-22 09:59:00 -04:00
Jonathan Shimwell
993a872798 removed unused else and passing **kwargs 2023-03-22 13:32:38 +00:00
Paul P.H. Wilson
6fc0c3e545 manually convert iterator to pointer 2023-03-22 09:27:50 -04:00
Jonathan Shimwell
83a124c492
[skip ci] review improvments to docstring from @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-03-22 13:11:33 +00:00
Paul P.H. Wilson
967cd43fa1 reuse assign 2023-03-22 08:45:19 -04:00
Paul P.H. Wilson
fb4845494f add default empty consructor 2023-03-22 00:37:21 -04:00
Paul P.H. Wilson
c272ed4c4e more pointer->instance repair 2023-03-22 00:37:12 -04:00
Paul P.H. Wilson
df4cfad60c more pointer to instance changes 2023-03-22 00:29:28 -04:00
Paul P.H. Wilson
035e6dc45a change to instance from pointer and cleanup lazy mistakes 2023-03-22 00:25:04 -04:00
Paul Romano
341cb9eb11
Merge pull request #2417 from pshriwise/spherical-mesh-fixes
Spherical to Cartesian coordinate conversion correction for VTK files
2023-03-21 22:27:53 -05:00
shimwell
17e9918f5d removed most deprecated types 2023-03-21 21:51:40 +00:00
Paul P.H. Wilson
60c3f2a9d5 type consistency and storing size as local 2023-03-21 16:36:33 -04:00
Paul P.H. Wilson
1d9446a065 introduce method to sample discrete index and use in various places 2023-03-21 16:14:38 -04:00
Patrick Shriwise
9b708e7ad4
Apply suggestions from @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-03-21 14:55:42 -05:00
Paul P.H. Wilson
38ca9b2f7c clang format fixes 2023-03-21 15:43:43 -04:00
Paul Romano
bb5f727f85 Update IO format docs for meshes 2023-03-21 13:48:22 -05:00
Paul Romano
cf8d9ef313 Handle zero photon cross sections in IncidentPhoton.from_ace properly 2023-03-21 13:15:28 -05:00
Paul Romano
3032ad7f37 Stick with 3.10 as default, add single 3.11 job 2023-03-21 09:37:39 -05:00
guyshtot
354fd34c2c Renamed previous use of _nuclides to _atomic_weight_ratios in the library class 2023-03-21 14:59:01 +02:00
Paul Romano
b3c7472c77 Add Python 3.11 to CI matrix 2023-03-21 07:14:07 -05:00
guyshtot
487f02dd1d Add option to specify nuclides in the Library class 2023-03-21 13:18:24 +02:00
Paul P.H. Wilson
b20dda710b change initialization of strengths 2023-03-17 12:58:53 -05:00
Patrick Shriwise
a4f498c54f
Merge pull request #2429 from keckler/volume_calculation
Fix small typo in error message
2023-03-17 10:03:36 -05:00
Jonathan Shimwell
d678b39e69
Merge pull request #2412 from paulromano/material-volume-args
Add volume arguments on several methods in Material class
2023-03-17 14:05:01 +00:00
Paul P.H. Wilson
29b5748687 reduce temporary memory use for potentially large data 2023-03-17 08:27:09 -05:00
Chris Keckler
c275933aae Fix small typo in error message 2023-03-16 21:24:53 -07:00
Paul P.H. Wilson
09d068fa81 syntax fixes 2023-03-16 21:16:59 -05:00
Paul P.H. Wilson
db92a64ec9 rename variable for clarity; re-add volume normalization 2023-03-16 17:51:41 -05:00
Paul P.H. Wilson
ee6975767d Use Discrete distribution for mesh sampling
This version builds the independent variable by
converting int to double and then converts back
when sampling.
2023-03-16 17:34:44 -05:00
Gavin Ridley
691f44f410
Merge pull request #2425 from paulromano/cmake-mpi-message
Improve error message when parallel HDF5 is found but MPI not enabled
2023-03-16 16:34:39 -04:00
Paul P.H. Wilson
2d20cd31f2 initialize Discrete distribution with sequence of integers 2023-03-16 14:37:05 -05:00
Patrick Shriwise
2d573c3fa1
Merge branch 'develop' into centre_for_cylinder_spherical_meshes 2023-03-16 11:26:40 -05:00
Paul Romano
3e6441a0d9 Address @shimwell comments on #2412 2023-03-16 09:45:29 -05:00
Paul Romano
a23a6c5928 Improve error message when parallel HDF5 is found but MPI not enabled 2023-03-16 09:26:23 -05:00
Paul Romano
e24aa7b8f7
Merge pull request #2415 from shimwell/updating_docker_actions
updated action versions to latest major release
2023-03-13 12:17:15 -05:00
Patrick Shriwise
285edc77b9 Corrections after rebase 2023-03-08 22:47:40 -06:00
Patrick Shriwise
ae57ad0e5b Improving test coverage for mesh to vtk capability 2023-03-08 17:29:06 -06:00
Patrick Shriwise
c487090b3f Correcting spherical to cartesian coordinate conversion 2023-03-08 17:29:04 -06:00
shimwell
da89de0034 updated action versions to latest major release 2023-03-07 20:40:03 +00:00
Jonathan Shimwell
9768e34b86
Merge pull request #2397 from pshriwise/mesh-vtk-fixes
`write_data_to_vtk` volume normalization correction
2023-03-07 20:19:07 +00:00
RemDelaporteMathurin
024c51a1ff Merge branch 'centre_for_cylinder_spherical_meshes' of https://github.com/RemDelaporteMathurin/openmc into centre_for_cylinder_spherical_meshes 2023-03-07 14:37:49 -05:00
RemDelaporteMathurin
ab4237c037 use get_reshaped_data in tests 2023-03-07 14:36:07 -05:00
shimwell
1a9449debc finding data_type arg automatically 2023-03-06 20:36:34 +00:00
Patrick Shriwise
527f5f70aa
Merge branch 'develop' into centre_for_cylinder_spherical_meshes 2023-03-06 13:37:24 -06:00
Rémi Delaporte-Mathurin
1b29adbf56
Merge pull request #6 from pshriwise/centre_for_cylinder_spherical_meshes
Add an intermediate `PeriodicStructuredMesh` class to separate the `origin` attribute from `StructuredMesh`
2023-03-06 14:03:31 -05:00
Patrick Shriwise
b02e558fae Adding docstring. Updating method name 2023-03-04 23:57:55 -06:00
Patrick Shriwise
5946763323 Moving origin data member down into Cylindrical/Spherical mesh using intermediate class 2023-03-04 15:51:56 -06:00
Paul Romano
1241892e1b
Merge pull request #2405 from shimwell/extra_tests_for_plotter
Extra tests for cross section plotter
2023-03-04 15:38:15 -06:00
Paul Romano
c1232a83e0 Add volume arguments on several methods in Material class 2023-03-03 15:08:17 -06:00
Paul Romano
c20f115cb9 Change exception in decay source processing to warning 2023-03-03 11:02:48 -06:00
shimwell
7f16f46bed material and plot_xs tests for plotter.py 2023-03-02 23:52:00 +00:00
shimwell
33f9ab7083 testing muliple reactions for elements+nuclides 2023-03-02 22:14:14 +00:00
shimwell
f34b37bb4f added test for element and nuclide plot 2023-03-02 22:07:49 +00:00
Patrick Shriwise
728f48c2ae Adding another test that uses VTK to gather the data directly.
Co-authored-by: Jonathan Shimwell <jonathan.shimwell@firstlightfusion.com>
2023-03-01 00:33:24 -06:00
RemDelaporteMathurin
c71c134963 added grids in statepoint specs 2023-02-27 16:32:05 -05:00
Rémi Delaporte-Mathurin
308be3f1ea
Update openmc/mesh.py
Co-authored-by: Ethan Peterson <ethan.peterson@mit.edu>
2023-02-27 16:23:45 -05:00
Rémi Delaporte-Mathurin
972e1c12ec
[skip ci] Minor refactoring
Co-authored-by: Ethan Peterson <ethan.peterson@mit.edu>
2023-02-27 16:22:10 -05:00
RemDelaporteMathurin
9ca6f1b65b fixed docstrings for origin 2023-02-27 16:13:31 -05:00
RemDelaporteMathurin
c61e735a70 empty_like instead of copy 2023-02-27 16:10:55 -05:00
RemDelaporteMathurin
2f9f500542 removed check and always offset origin 2023-02-27 16:10:27 -05:00
Paul Romano
b44225b3d5
Merge pull request #2399 from aprilnovak/default-c
Add default constructor for VolumeCalculation
2023-02-27 12:36:00 -06:00
Paul Romano
beea906e00
Merge pull request #2377 from shimwell/adding_volume_to_material_repr
added volume information to material repr
2023-02-24 20:44:34 -06:00
Jonathan Shimwell
0d84c53818
review improvment, refactor to single line
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-02-24 22:05:00 +00:00
April Novak
9858114ed7
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-02-24 11:53:40 -08:00
aprilnovak
f0aa0ab3f2 Add default constructor for VolumeCalculation. Refs #2398 2023-02-24 12:10:52 -06:00
Patrick Shriwise
70b743e5ed Add test of volume normalization ordering 2023-02-23 23:59:46 -06:00
Patrick Shriwise
a270d4c01a Using vertices property where possible. Correcting volume ordering in normalization 2023-02-23 23:39:03 -06:00
Jonathan Shimwell
7becabcde4
cm^3 instead of cm3 2023-02-23 21:16:52 +00:00
Paul Romano
ed02703f4b
Merge pull request #2392 from joshmay1/nuclide_determinism
Order nuclides deterministically when adding from elements
2023-02-23 09:21:54 -06:00
josh
5556b0cedc order nuclides by increasing mass number 2023-02-22 18:24:50 +00:00
Paul Romano
635e573955
Merge pull request #2390 from pshriwise/restart-fixes
Updates to batch checks for simulation restarts
2023-02-22 09:16:11 -06:00
Rémi Delaporte-Mathurin
f961fc90c2
[skip ci] Modified the XML specs 2023-02-21 17:42:06 -05:00
Patrick Shriwise
55179b5a46 Removing os module from restart test 2023-02-21 07:31:53 -06:00
Patrick Shriwise
0419367815
Update tests/regression_tests/statepoint_restart/test.py
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-02-21 07:28:32 -06:00
Patrick Shriwise
0aa36836b3 Updating globs 2023-02-21 00:48:23 -06:00
Patrick Shriwise
1b68e61a3e explicit instance check 2023-02-21 00:47:47 -06:00
Patrick Shriwise
b8c7c76444
Apply suggestions from @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-02-21 00:42:27 -06:00
Patrick Shriwise
a528de2976
Merge pull request #2381 from paulromano/anisotropic-fission
Use correct direction for anisotropic fission and update numpy version for tests
2023-02-20 12:37:08 -06:00
Patrick Shriwise
7aaf114d8e
Merge pull request #2388 from shimwell/moving_gau_method_up_one_layer
testing get_all_universes is in DAGMCUniverse
2023-02-20 12:36:53 -06:00
Patrick Shriwise
3702d40f9f
Merge pull request #2391 from paulromano/override-fixes
Add missing override specifiers in C++ classes
2023-02-20 09:33:55 -06:00
Patrick Shriwise
d363f4eedb
Merge pull request #2395 from aprilnovak/better-error
Use more generalized error message.
2023-02-19 09:24:37 -06:00
April Novak
5a61627549
Apply suggestions from code review
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2023-02-18 17:18:53 -08:00
aprilnovak
14af9de1e2 Use more generalized error message. Refs #2394 2023-02-17 19:16:15 -06:00
Paul Romano
b9d4ed2a28
Merge pull request #2386 from bam241/map_no_kargs
map does not accept keyword argument, fixing PR #2356
2023-02-17 10:59:07 -06:00
Paul Romano
eb0c8e497c Move Filter::create<T> implementation to filter.h 2023-02-17 10:31:54 -06:00
Paul Romano
d5ce4af68a Add RDMAV_FORK_SAFE=1 to avoid fork error with libfabric 2023-02-17 10:31:27 -06:00
RemDelaporteMathurin
c634a14674 added origin to docstrings 2023-02-17 10:56:42 -05:00
josh
0aba858f95 sort nuclides when adding by element 2023-02-17 02:15:50 +00:00
Patrick Shriwise
65852f4fbc Update batch comparison in statepoint load 2023-02-16 17:52:23 -06:00
Patrick Shriwise
648313fab1 Adding to regression test instead of making new unit test 2023-02-16 16:28:51 -06:00
Patrick Shriwise
9803c26111 bwd compatibility fix for reading filter elements 2023-02-16 16:18:41 -06:00
Paul Romano
ce62bbd9c5 Add missing override specifiers 2023-02-16 14:06:59 -06:00
Patrick Shriwise
461fd54f11 Updating doc strings 2023-02-16 13:53:57 -06:00
Patrick Shriwise
ee2f0f2c53 Adding a test for restart runs 2023-02-16 13:48:28 -06:00
Patrick Shriwise
0e10a7da47 Allowing openmc.Pathlike for restart file argument 2023-02-16 13:48:11 -06:00
Patrick Shriwise
1891ff7c24 Updating batch number checks for simulation and sp load 2023-02-16 13:47:42 -06:00
Ethan Peterson
1a2d1237da
Update openmc/model/surface_composite.py
Co-authored-by: Jonathan Shimwell <drshimwell@gmail.com>
2023-02-16 12:27:15 -05:00
Ethan Peterson
6e2a9add5e
Merge pull request #2378 from paulromano/inelastic-fix
Avoid out-of-bounds access in inelastic scatter sampling
2023-02-16 12:24:36 -05:00
Jonathan Shimwell
04d9e27866 moving get_all_universes method 2023-02-16 16:24:24 +00:00
Jonathan Shimwell
9e88e706fe testing get_all_universes is in DAGMCUniverse 2023-02-16 16:20:44 +00:00
Baptiste Mouginot
a25bbc250f renaming func_args into matrix_args, fixing docstring accordingly 2023-02-16 14:50:23 +01:00
Paul Romano
fa4aa4ad21
Merge pull request #2385 from bam241/model_mats_per_id
Model mats per id
2023-02-16 07:26:51 -06:00
Paul Romano
61b30f5dcc
Merge pull request #2334 from pshriwise/umesh_sampling
Unstructured Mesh Sampling Updates
2023-02-16 07:24:13 -06:00
Paul Romano
a2b828af52 Use 1 thread for OpenBLAS calls from numpy 2023-02-15 07:09:38 -06:00
Baptiste Mouginot
5f5c0ed7a7 map_no_kargs 2023-02-15 11:07:29 +01:00
Paul Romano
0435e64fd0 Disable AVX512 in numpy runtime SIMD dispatch 2023-02-14 23:09:54 -06:00
Paul Romano
070e5b93e1 Try running CI on ubuntu-22.04 2023-02-14 16:42:24 -06:00
Baptiste Mouginot
760ff7e34c fix return _materiaLs_by_id 2023-02-14 15:12:04 +01:00
Baptiste Mouginot
68a0ec7936 fix return _materiaLs_by_id 2023-02-14 15:05:37 +01:00
Rémi Delaporte-Mathurin
ef2ef4d261
Merge pull request #5 from pshriwise/centre_for_cylinder_spherical_meshes
Updating mesh centre tests.
2023-02-13 11:06:05 -05:00
Patrick Shriwise
3d548c882f Addressing latest comments from @paulromano 2023-02-13 09:52:17 -06:00
Patrick Shriwise
75fe7f00a9
Apply code suggestions from @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-02-13 09:40:21 -06:00
Paul Romano
893c4d0648 Try using 10**x instead of logspace in source test 2023-02-13 09:00:33 -06:00
Paul Romano
4783b34fe2 Fix several failing tests 2023-02-13 07:16:10 -06:00
Patrick Shriwise
e6a490ac9c
Merge pull request #2383 from paulromano/mesh-filter-docfix
Fix documentation for MeshFilter and MeshSurfaceFilter
2023-02-12 23:02:19 -06:00
Paul Romano
fc619f8352 Fix documentation for MeshFilter and MeshSurfaceFilter 2023-02-12 19:27:11 -06:00
Gavin Ridley
a755bfd040
Merge pull request #2382 from paulromano/tsl-nuclide-fixes
Fix several thermal scattering nuclide assignments
2023-02-11 13:33:45 -05:00
Paul Romano
ba074c5a5a Fix several thermal scattering nuclide assignments 2023-02-10 14:59:57 -06:00
Paul Romano
091241070f Update test results with numpy 1.24 and anisotropic fission 2023-02-10 12:21:42 -06:00
Paul Romano
fcdac0759e Remove numpy version hardcoding in pyproject.toml / GHA 2023-02-10 11:41:50 -06:00
Paul Romano
6a790df0be Update micro_xs regression test with update option 2023-02-10 11:41:50 -06:00
Paul Romano
956e3f4341 Make sure correct direction is applied when fission neutrons are anisotropic 2023-02-10 11:41:50 -06:00
Paul Romano
990b5449f5 Avoid use of np.float and np.int 2023-02-10 11:41:49 -06:00
Paul Romano
9c646b3f32 Fix CMFDMesh.grid setter 2023-02-10 11:41:49 -06:00
Paul Romano
c0d5efc340
Merge pull request #2356 from bam241/matrix_func_arg
adding optional arg to matrix_func in Pool.py (for depletion)
2023-02-10 10:39:38 -06:00
Paul Romano
d65c6ca13a
Merge pull request #2376 from shimwell/adding_mat_name_to_error_message
making error message more helpful with material name
2023-02-10 07:40:01 -06:00
Paul Romano
f8c8e37342
Merge pull request #2371 from shimwell/adding_tabular_to_energy_filter
added get_tabular method to energyfilters
2023-02-10 06:54:39 -06:00
Jonathan Shimwell
c0391781ca changed error message to preferred option 2023-02-10 09:22:10 +00:00
Jonathan Shimwell
eaddf91b65
Adding zero to end of test results
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-02-09 21:19:11 +00:00
Paul Romano
89ad9afedf
Merge pull request #2352 from joshmay1/universe_cloning
Instantiate new cloned universes instead of deepcopying
2023-02-09 14:55:00 -06:00
Jonathan Shimwell
853ef5ea49
2nd round of review improvments from paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-02-09 19:51:46 +00:00
shimwell
b559d32d68 custom error message for name is None 2023-02-09 19:47:29 +00:00
Jonathan Shimwell
e6d8e3f4a7
avoiding true divide erorr 2023-02-09 17:53:04 +00:00
Josh May
b41c8330f1
Update openmc/universe.py
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-02-09 09:41:23 -08:00
Jonathan Shimwell
8a5a520106
code review improvments from @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-02-09 17:38:33 +00:00
Patrick Shriwise
e8e2d9afa2
Merge pull request #2288 from eepeterson/filter_shape
Change to get_reshaped_data for consistency with mesh dimensions
2023-02-09 08:50:34 -06:00
Patrick Shriwise
af16239684 Updating mesh centre tests. 2023-02-08 10:17:59 -06:00
Ethan Peterson
63b8261336 treat MeshSurfaceFilter differently 2023-02-07 14:13:46 -05:00
Ethan Peterson
653bec5fd8 added shape to aggregate filter 2023-02-07 14:13:46 -05:00
Ethan Peterson
61efad0a8d added test and expand_dims kwarg 2023-02-07 14:13:46 -05:00
Ethan Peterson
512c7e6556 modified get_reshaped_data 2023-02-07 14:13:46 -05:00
Ethan Peterson
5f0e3e14fb added default filter shape and mesh filter shape 2023-02-07 14:13:46 -05:00
Jonathan Shimwell
0d4227fa1f added volume information to material repr 2023-02-07 12:26:11 +00:00
Jonathan Shimwell
016a5e5b3c moved full stop 2023-02-07 10:24:39 +00:00
Jonathan Shimwell
ecebe25f36 making error message more helpful with material name 2023-02-07 10:23:28 +00:00
Paul Romano
5470ec75b4 Avoid out-of-bounds access on index_inelastic_scatter_ 2023-02-06 21:49:43 -06:00
Ethan Peterson
637080a0c2 address comments from @hassec review 2023-02-06 15:52:46 -05:00
josh
6d69c782ae abstract _partial_deepcopy and reformat docstrings 2023-02-06 17:45:18 +00:00
Ethan Peterson
c07386fc62 added more tests for Polygon class 2023-02-05 22:15:10 -05:00
Ethan Peterson
78b0fbaa27 finished polygon self-intersection check 2023-02-05 22:02:14 -05:00
Patrick Shriwise
283e3ee6aa Adjust the read_meshes function to search only for mesh elements directly below the element passed in 2023-02-03 22:55:47 -06:00
Patrick Shriwise
fc67b38ba4 Adding roundtrip test for mesh sampling 2023-02-03 20:11:35 -06:00
Patrick Shriwise
cf8cd62961
Update tests/unit_tests/test_source_mesh.py
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-02-03 19:32:41 -06:00
Patrick Shriwise
6218becb17
Merge pull request #2375 from paulromano/tabular-mean-fix
Don't call normalize inside Tabular.mean
2023-02-03 19:31:35 -06:00
Paul Romano
dbbad687eb Don't call normalize inside Tabular.mean 2023-02-03 08:32:05 -06:00
RemDelaporteMathurin
1e94a0c7d7 fixed theta_grid spherical mesh 2023-02-02 09:39:23 -05:00
RemDelaporteMathurin
90995dc512 Merge branch 'develop' into centre_for_cylinder_spherical_meshes 2023-02-02 08:47:28 -05:00
Jonathan Shimwell
5c672f5ea8
Merge pull request #2363 from RemDelaporteMathurin/fix_flat_mesh
Raise error when mesh is flat
2023-02-02 12:21:31 +00:00
Paul Romano
b8a3586274
Merge pull request #2365 from openmc-dev/update_actions_checkout
updated checkout action to v3
2023-01-31 13:35:00 -06:00
Paul Romano
f1bbeda7f5
Merge pull request #2364 from shimwell/allowing_export_with_different_materials_files
allowing materials.xml to be specified
2023-01-31 13:33:22 -06:00
Paul Romano
7a736cc3a4
Merge pull request #2329 from myerspat/distribution-alias-sampling
Alias sampling implementation for discrete PDFs
2023-01-31 10:08:11 -06:00
Jonathan Shimwell
de8ebfc81a Merge branch 'develop' into update_actions_checkout 2023-01-31 13:58:55 +00:00
Jonathan Shimwell
95f0e87c7f Merge branch 'develop' into allowing_export_with_different_materials_files 2023-01-31 13:56:33 +00:00
Jonathan Shimwell
e9866b4d66 added get_tabular metho to energyfilters 2023-01-31 13:20:31 +00:00
Paul Romano
3b7bf1e3b7
Merge pull request #2370 from paulromano/fix-h5py-parallel-ci
Fix installing h5py in CI when MPI is enabled
2023-01-31 06:15:35 -06:00
Paul Romano
f45b431a21 Use --no-build-isolation to get around parallel h5py install issue
See https://github.com/h5py/h5py/issues/2222
2023-01-30 23:18:07 -06:00
Ethan Peterson
e20e648690 check for duplicate points 2023-01-30 19:40:00 -05:00
RemDelaporteMathurin
17d88d8c84 added tests for spherical mesh 2023-01-30 13:57:44 -05:00
Rémi Delaporte-Mathurin
b1a5d0ba1b
Merge pull request #4 from pshriwise/centre_for_cylinder_spherical_meshes
Centre for cylinder spherical meshes
2023-01-30 13:53:13 -05:00
shimwell
dd60c1583f updated checkout action to v3 2023-01-29 17:47:54 +00:00
Jonathan Shimwell
60f33d4607
Review improvement from @paulromano 2023-01-28 17:18:35 +00:00
Rémi Delaporte-Mathurin
a51d31ec78
Update openmc/mesh.py
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-01-28 08:50:45 -05:00
Rémi Delaporte-Mathurin
198b5bdad4
Update openmc/mesh.py
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-01-28 08:50:39 -05:00
Patrick A Myers
ca1f9a6965 updated test for counter 2023-01-27 11:31:37 -05:00
Patrick A Myers
ec5f0e54f4 Restored init_alias and changed constructor definitions 2023-01-27 10:22:27 -05:00
Jonathan Shimwell
2dbb0c7523 allowing materials.xml to be specified 2023-01-27 14:26:56 +00:00
RemDelaporteMathurin
c84336878b replace is_flat by a one-line check 2023-01-27 08:58:10 -05:00
RemDelaporteMathurin
ba1cd67d52 added test to catch bug + fix 2023-01-27 08:32:02 -05:00
Patrick Shriwise
3703fdbdd7 Adding origin to sphere and cyl mesh str 2023-01-26 14:15:08 -06:00
Patrick Shriwise
b22c7e8353 Adding test cases for cylindrical mesh 2023-01-26 14:14:06 -06:00
Patrick Shriwise
11eee756dd Corrections to application of origin for sphere and cyl mesh 2023-01-26 14:13:39 -06:00
RemDelaporteMathurin
a976703556 Raise error if mesh is flat 2023-01-26 14:06:48 -05:00
RemDelaporteMathurin
91ebcdb21e better test 2023-01-26 14:05:23 -05:00
RemDelaporteMathurin
396ecdf02c added test that cathces the bug 2023-01-26 13:55:22 -05:00
Ethan Peterson
4fade673a7 refactor to single validate_points method 2023-01-25 16:27:12 -05:00
Ethan Peterson
afbbc3d845 try to constrain triangulation 2023-01-24 23:00:27 -05:00
Paul Romano
3f5b90042c
Merge pull request #2349 from paulromano/newyear-2023
Update copyright date and a few other small changes
2023-01-24 23:20:26 +07:00
Paul Romano
00668d70b0
Merge pull request #2360 from openmc-dev/gridley-patch-1
multipole documentation typo fix
2023-01-24 22:27:59 +07:00
Gavin Ridley
368525f3db
multipole documentation typo fix 2023-01-22 10:07:18 -05:00
Patrick Shriwise
de8f99adbe Removing unstructured mesh source sampling test.
The test cases here almost entirely overlapped with those in the unit test. The test for an invalid size on the strengths array has been moved to the test_mesh_source.py unit test.
2023-01-18 11:12:10 -06:00
Patrick Shriwise
cd7ad7de7a Adding failure check to mesh source unit test. 2023-01-18 11:10:33 -06:00
Baptiste Mouginot
dcfac1d10e tweaking comments 2023-01-18 14:12:00 +01:00
Baptiste Mouginot
bbacb383cd allowing to pass additiinal args to pool.deplete when using user specified maxtrix_func 2023-01-18 14:04:41 +01:00
Patrick Shriwise
303812202d
Merge pull request #2354 from aprilnovak/unused-dagmc-param
Remove unused dagmc settings parameter.
2023-01-17 15:53:20 -06:00
April Novak
d4a940d44d Remove unused dagmc settings parameter. Refs #2353 2023-01-17 10:59:53 -08:00
Josh May
d9ce50dc9f
Merge branch 'openmc-dev:develop' into universe_cloning 2023-01-16 18:43:34 -08:00
josh
3d6179fa32 remove try/except for class-specific 'deepcopy' 2023-01-17 02:43:02 +00:00
josh
06e6d5d347 add dagmc testing 2023-01-17 02:42:40 +00:00
Patrick A Myers
d0e071be94 update tests to be more robust 2023-01-13 16:51:13 -05:00
Patrick A Myers
4122c02ad4 change p to prob and fix alias table 2023-01-13 16:50:50 -05:00
Patrick Shriwise
beb3085469 Changing to const Mesh* 2023-01-13 12:24:24 -06:00
Patrick Shriwise
9313f809a4 Adding a tally to the unstructured mesh regression test. 2023-01-13 10:34:30 -06:00
Patrick Shriwise
ff9b5fd741 Adding not about moving the mesh cdf in the future. 2023-01-13 10:24:05 -06:00
Patrick A Myers
8288b55822 moved make after environment variable 2023-01-13 10:53:18 -05:00
Patrick A Myers
8cbcf23b8d added option for build tests to linking tests library 2023-01-13 10:50:03 -05:00
Patrick A Myers
17c836731e added cmake option for building tests 2023-01-13 10:47:56 -05:00
Patrick Myers
2eae8b8f8b
Merge branch 'develop' into distribution-alias-sampling 2023-01-13 10:33:19 -05:00
Patrick Shriwise
f92515d6f2 Correcting sampling unit test 2023-01-13 08:45:48 -06:00
Paul Romano
bbe39dbc1b Added some missing versionadded directives 2023-01-13 13:41:00 +07:00
Paul Romano
606457a1f0 A few style fixes in material.py 2023-01-13 13:36:51 +07:00
Patrick Shriwise
124839796e Updating test inputs for auto-generated material ID. 2023-01-13 00:04:22 -06:00
Patrick Shriwise
d0988327fe Applying formatter 2023-01-13 00:00:16 -06:00
Patrick Shriwise
6f0c6f5296 Applying suggestions for tests from @paulromano. 2023-01-12 23:53:06 -06:00
Patrick Shriwise
4675ff0231 Correcting MOAB call args 2023-01-12 23:53:06 -06:00
Patrick Shriwise
4d06ed5640 Passing mesh memo through to source from_xml method 2023-01-12 23:53:06 -06:00
Patrick Shriwise
55138aa144
Picking up an additional suggestion from @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-01-12 23:49:31 -06:00
Patrick Shriwise
4195d1e8ca Restoring blank lines in settings.cpp and source.cpp 2023-01-12 23:20:11 -06:00
Patrick Shriwise
d4cbcd12fc Addressing comments from @paulromano's review 2023-01-12 23:19:12 -06:00
Patrick Shriwise
e873db9a07
Apply suggestions from @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-01-12 23:13:09 -06:00
Paul Romano
0a8454d7f7 Mention MCPL in optional dependencies 2023-01-13 12:08:26 +07:00
Paul Romano
402b7b2ced Happy new year 2023! 2023-01-13 12:02:20 +07:00
Paul Romano
1cdb37a05c
Merge pull request #2348 from cfichtlscherer/prompt_neutrons
Prompt neutrons 2.0
2023-01-13 09:44:44 +07:00
josh
e799346502 switch universe deepcopying for a fresh instance on clones 2023-01-12 21:58:22 +00:00
Christopher Fichtlscherer
a66d4da53f
Update openmc/settings.py
version number

Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-01-12 06:26:07 -05:00
Christopher Fichtlscherer
36249d3742
Update openmc/settings.py
yes

Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-01-12 06:25:52 -05:00
Paul Romano
54320f3011
Merge pull request #2347 from shimwell/adding_get_surfaces_by_name
added get_surfaces_by_name method to geometry
2023-01-12 14:30:54 +07:00
Paul Romano
029838c947
Merge pull request #2340 from joshmay1/cell_cloning
Manually instantiate cloned cells rather than deepcopying
2023-01-12 09:48:45 +07:00
Paul Romano
a62bb50b27
Merge pull request #2222 from highness-eu/mixed_ncrystal
Adding support for NCrystal materials in OpenMC
2023-01-12 09:47:33 +07:00
Christopher Fichtlscherer
f7c1a57b15 settings change element 2023-01-11 16:55:27 -05:00
Josh May
afa490f6a6
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-01-11 13:27:06 -08:00
Christopher Fichtlscherer
3ba117fcd9 indentation level change 2023-01-11 15:41:31 -05:00
Christopher Fichtlscherer
8b1ecaad09 deleted white spaces 2023-01-11 15:38:16 -05:00
Christopher Fichtlscherer
e266bb15bf old changes for delayed neutron feature 2023-01-11 14:50:08 -05:00
Christopher Fichtlscherer
9d86274fcc merge conflict 2023-01-11 14:17:29 -05:00
Christopher Fichtlscherer
50892c61b7 unit test and description 2023-01-11 14:15:37 -05:00
Thomas Kittelmann
93aaa32d4d
Merge pull request #3 from paulromano/mixed_ncrystal_const
Change ncrystal_max_energy to be a global constant
2023-01-11 18:50:23 +01:00
Paul Romano
02abb63bcf
Merge pull request #2333 from openmc-dev/optional_materials_when_loading_geometry_2
allowing xml file for materials
2023-01-11 21:35:31 +07:00
Jonathan Shimwell
2c9df1b77e
Apply typo fixes identified incode review by @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2023-01-11 09:32:02 +00:00
Jonathan Shimwell
08c7d8935a
Merge pull request #2335 from paulromano/plot-xs-sab-fix
Small fix in `plot_xs` when S(a,b) tables are present
2023-01-11 09:29:58 +00:00
Paul Romano
d2f8ca2078
Merge pull request #16 from shimwell/adding_sab_plotter_test
added test for sab xs appears in xs calc
2023-01-11 07:40:58 +07:00
Jonathan Shimwell
a0afa5de44 added get_surfaces_by_name method 2023-01-10 19:04:12 +00:00
Paul Romano
e83ced88dc Change ncrystal_max_energy to be a global constant 2023-01-11 01:17:53 +07:00
April Novak
ee0fcd3bc0
Merge pull request #2344 from pshriwise/fix_triggers
Fix triggers
2023-01-10 08:40:24 -08:00
Thomas Kittelmann
fe4a1de57d
Merge pull request #2 from paulromano/mixed_ncrystal_pr
Refactor interface between NCrystal and OpenMC
2023-01-10 11:32:10 +01:00
Paul Romano
c4227f7dc1 Change Material.from_ncrystal to accept kwargs 2023-01-10 17:20:14 +07:00
Paul Romano
4eda693133 Style and spacing changes 2023-01-10 17:20:14 +07:00
Paul Romano
62af773108 Refactor NCrystal interface code to ncrystal_interface.h/cpp 2023-01-10 17:20:11 +07:00
Thomas Kittelmann
7dae457342
Merge pull request #1 from paulromano/ncrystal_mixed
Merge develop branch to resolve conflicts
2023-01-10 08:52:25 +01:00
Paul Romano
b6d6bdf3f5 Merge branch 'develop' into mixed_ncrystal_pr 2023-01-09 13:13:14 +07:00
April Novak
70b7c3135b
Merge pull request #2341 from pshriwise/update_gamma_note
Updating note on photon transport limitations
2023-01-06 09:55:33 -08:00
Patrick Shriwise
bfcbecdbaa Fixing tally triggers. Refs #2342 and #2343 2023-01-05 16:25:15 -06:00
Patrick Shriwise
9615b9f5da Adding tests for tally triggers. 2023-01-05 16:04:33 -06:00
Patrick Shriwise
9fac1bb4d2 Updating note on photon transport limitations 2023-01-05 12:13:55 -06:00
Jonathan Shimwell
82429cbb19 added test for sab xs appears in xs calc 2023-01-05 11:16:16 +00:00
Josh May
37331deeee
Merge branch 'openmc-dev:develop' into cell_cloning 2023-01-04 15:35:23 -08:00
josh
60f9a42711 simplify cell cloning test changes 2023-01-04 22:54:26 +00:00
josh
affc62f09c only reassign temps when not None 2023-01-04 22:53:55 +00:00
Jonathan Shimwell
e01f0ea944
Merge pull request #2332 from paulromano/gnds-naming
Change GND to GNDS
2023-01-04 11:10:37 +00:00
josh
ac2ba93b3a remove cell deepcopying for creating a fresh instance 2023-01-04 03:31:07 +00:00
Patrick Shriwise
219a4b04da Addressing comments from @NybergWISC
Co-authored-by: Matthew Nyberg <mnyberg@wisc.edu>
2023-01-03 10:35:44 -06:00
Paul Romano
80dad0f240 Small fix in plot_xs when S(a,b) tables are present 2022-12-31 11:32:39 +07:00
Patrick Shriwise
5e2cb6778d Adding the mesh spatial option to the <source><spatial> IO description 2022-12-30 22:01:11 -06:00
Patrick Shriwise
8657123bac Add some documentation for the new MeshSpatial class. 2022-12-30 07:21:11 -06:00
Patrick Shriwise
580096d423 Removing MESHES import 2022-12-29 10:39:41 -06:00
Patrick Shriwise
43549cf1f1 A couple small changes from original PR comments 2022-12-29 09:23:14 -06:00
Patrick Shriwise
c6f0d36bdb Correcting attribute name 2022-12-29 09:23:14 -06:00
Patrick Shriwise
3779c5cc4d Skip test in absence of UM support 2022-12-29 09:23:14 -06:00
Patrick Shriwise
251d7f5436 Skip tests if libraries are not enabled 2022-12-29 09:23:14 -06:00
Patrick Shriwise
60a2a0e1f8 Adding clarity to error message re: improperly sized strengths array 2022-12-29 09:23:14 -06:00
Patrick Shriwise
f001d411ee More small improvements to tests 2022-12-29 09:23:14 -06:00
Patrick Shriwise
7fd2f0d7ff Correcting filepath for test run outside directory 2022-12-29 09:23:14 -06:00
Patrick Shriwise
eca2a1ad2e Reworking geometry model. 2022-12-29 09:23:14 -06:00
Patrick Shriwise
996930f7f1 Improved testing for manually set source strengths 2022-12-29 09:23:14 -06:00
Patrick Shriwise
bc7c8cd892 Adding empty results for now 2022-12-29 09:23:14 -06:00
Patrick Shriwise
ef14e0e800 Separating tests into unit and regression tests. 2022-12-29 09:23:14 -06:00
Patrick Shriwise
2779902287 Refactoring mesh sampling test to use openmc.lib. Making model a fixture 2022-12-29 09:23:14 -06:00
Patrick Shriwise
0a83824bea Improve distribution testing 2022-12-29 09:23:14 -06:00
Patrick Shriwise
ce956f8515 Run ww unit test in tmp dir 2022-12-29 09:23:14 -06:00
Patrick Shriwise
03811745a0 Skip mesh elements without an ID due to overlap in name with WW element 2022-12-29 09:23:14 -06:00
Patrick Shriwise
8e6ce2e16f Updates to unstructured mesh sampling tests. 2022-12-29 09:23:14 -06:00
Patrick Shriwise
e100689c8f Minor updates to C++ source. Fix for CDF distribution sampling 2022-12-29 09:23:14 -06:00
Patrick Shriwise
0ffe0b39c1 Adding docstrings to MeshSpatial Python class 2022-12-29 09:23:14 -06:00
Patrick Shriwise
fba3a9a118 tet_bin to elem_bin suggestion from @eepeterson 2022-12-29 09:23:14 -06:00
NybergWISC
2bfdcefcf6 Remove second volume method from mesh header file 2022-12-29 09:23:14 -06:00
NybergWISC
115be68953 Small refactor of distribution_spatial.cpp and change default of volume_normalized to True 2022-12-29 09:23:14 -06:00
NybergWISC
bd60956d20 Second round of comments. volume method is now implemented from Mesh instead of UnstructuredMesh 2022-12-29 09:23:14 -06:00
NybergWISC
7c40badfbc Address comments on initial PR, all changed other than name of class and the use of python API to combine track outputs 2022-12-29 09:23:14 -06:00
Matthew Nyberg
7a3a1876e1 Reorganize imports in source_sampling/test.py
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2022-12-29 09:23:14 -06:00
NybergWISC
9f6d536959 Commit including most of the sampling work in distribution_spatial.cpp and testing 2022-12-29 09:23:12 -06:00
NybergWISC
80077ed3fd New changes to spatial distribution and source to include mesh sources. Made some edits suggested by Shriwise, now compiles successfully 2022-12-29 09:22:34 -06:00
NybergWISC
238ab5210e Initial Mesh Sampling Changes 2022-12-29 09:22:34 -06:00
shimwell
577157b846 allowing xml file for materials 2022-12-24 22:40:34 +00:00
Paul Romano
3f8f8f6701
Merge pull request #2291 from pshriwise/model-xml
Support for a single `model.xml` file
2022-12-24 13:33:27 -06:00
Paul Romano
1680a72f12
Merge pull request #2116 from ebknudsen/mcpl_input
Add support for MCPL files
2022-12-24 13:12:52 -06:00
myerspat
ea1feef6e2 changing CTest workflow in CI 2022-12-23 14:40:54 -05:00
myerspat
761bfc5349 added documentation on unit testing with catch2 2022-12-23 12:54:59 -05:00
myerspat
6b0baf8b1d added catch2 testing to ci workflow 2022-12-23 12:54:24 -05:00
Erik B Knudsen
d93bc274b1
Merge pull request #3 from paulromano/mcpl-updates
Fix source definition in source_mcpl_file test
2022-12-23 18:42:50 +01:00
Paul Romano
954a2bdcda Fix source definition in source_mcpl_file test 2022-12-23 11:12:46 -06:00
Paul Romano
a178f5f85a Use raw f-string in test_mesh_to_vtk.py 2022-12-23 10:55:58 -06:00
Erik B Knudsen
6147034cd7
Merge pull request #2 from paulromano/mcpl-updates
One more fix
2022-12-23 11:51:20 +01:00
Paul Romano
f9c6765eca Update intersphinx URLs 2022-12-23 00:07:08 -06:00
Paul Romano
a5bdbd3adb Address a few warnings from tests 2022-12-23 00:07:02 -06:00
Paul Romano
ecfa94e0ff Rename gnd_name to gnds_name. Change GND to GNDS in comments 2022-12-23 00:06:50 -06:00
Patrick Shriwise
64aee3b4fe
Merge pull request #16 from paulromano/model-xml-pr
Several small fixes
2022-12-22 22:53:32 -06:00
Paul Romano
a0d8541a01 Make sure OpenMCConfig.cmake.in includes MCPL 2022-12-22 22:27:03 -06:00
Paul Romano
25f2bd50f9 Several small fixes 2022-12-22 18:27:42 -06:00
Erik B Knudsen
04118bce34
Merge pull request #1 from paulromano/mcpl-updates
Refactor MCPL code
2022-12-22 23:41:55 +01:00
Paul Romano
ddbd61cc97 Formatting fixes 2022-12-22 14:56:41 -06:00
Paul Romano
731eff8817 Update source_mcpl_file test result 2022-12-22 14:56:40 -06:00
Paul Romano
47848b79ab Allow Settings.sourcepoint['mcpl'] to be set 2022-12-22 14:56:40 -06:00
Paul Romano
eeab41a19d Build against MCPL in CI by default 2022-12-22 14:56:40 -06:00
Paul Romano
9ae44b3fd1 Rearragne MCPL source writing logic 2022-12-22 14:56:40 -06:00
Paul Romano
361b3486ef Move remainder of MCPL-related code to mcpl_interface.h/cpp 2022-12-22 14:56:36 -06:00
Paul Romano
a3065b479c Move FileSource MCPL reading to mcpl_interface.h/cpp 2022-12-22 11:33:29 -06:00
Paul Romano
987293cfff Small fixes and formatting changes 2022-12-22 10:57:11 -06:00
Paul Romano
28521c8384 Use vector::push_back for building MCPL FileSource 2022-12-22 10:53:40 -06:00
Erik B Knudsen
51d3a0c2ce check for mcpl-input is in the cpp-layer now 2022-12-22 17:19:56 +01:00
Erik B Knudsen
4d7797c25b mistake assigning the wrong variable 2022-12-22 17:18:37 +01:00
Erik B Knudsen
e9c6b03b9e remove dead code 2022-12-22 17:17:50 +01:00
Erik B Knudsen
fe19cfcdd2 set seed to get a deterministic test and set result 2022-12-22 17:16:16 +01:00
erkn
83b914af24 Merge branch 'mcpl_input' of github.com:ebknudsen/openmc into mcpl_input 2022-12-22 12:05:54 +01:00
erkn
ff48f53595 skip mcpl-test if it is not enabled
patterned after the dagmc-tests
This required the MCPL_ENABLED symbol to be unmangled
2022-12-22 12:04:29 +01:00
myerspat
903c93de26 Merge branch 'distribution-alias-sampling' of github.com:myerspat/openmc into distribution-alias-sampling 2022-12-21 16:59:21 -05:00
myerspat
dd569c616c increased stdev width to 4 2022-12-21 16:59:04 -05:00
Patrick Myers
a953938bdf
Change alias sampling comment
Co-authored-by: Paul Wilson <paul.wilson@wisc.edu>
2022-12-21 15:39:13 -06:00
myerspat
19c807ade2 updated regression tests 2022-12-21 10:15:14 -05:00
Erik B Knudsen
a50776219f resolve conflict w. develop 2022-12-21 11:33:36 +01:00
erkn
9865a129c4 optionally install mcpl depending on environment var 2022-12-21 00:22:38 +01:00
erkn
1ab9aa4b6f script for installing mcpl as a ci-thing 2022-12-21 00:14:43 +01:00
erkn
de8dcbd332 Merge branch 'mcpl_output_dev' into mcpl_input 2022-12-21 00:01:15 +01:00
erkn
52316095fb Merge branch 'mcpl_input' of github.com:ebknudsen/openmc into mcpl_input 2022-12-21 00:00:12 +01:00
erkn
2b7fa8fdd2 Revert "enable mcpl from the python layer"
This reverts commit e3f1bdaca1.
There is now a check in the cpp-layer if the file is named .mcpl
2022-12-20 23:58:34 +01:00
erkn
94537e8570 Merge branch 'mcpl_output_dev' of github.com:ebknudsen/openmc into mcpl_output_dev 2022-12-20 23:52:15 +01:00
myerspat
6c3968525b Merge branch 'develop' of github.com:myerspat/openmc into distribution-alias-sampling 2022-12-20 16:46:56 -05:00
myerspat
748e7da3f9 added test for xml node Discrete constructor 2022-12-19 17:25:20 -05:00
myerspat
90509d928b moved alias method to function and fixed sampling bug 2022-12-19 17:24:33 -05:00
myerspat
907cf7df4d changed catch2 clone link to https 2022-12-16 12:30:08 -05:00
Paul Romano
4e49f69f02
Merge pull request #2320 from paulromano/from-njoy-high-t-fix
Fix `IncidentNeutron.from_njoy` for high temperatures
2022-12-15 16:22:43 -06:00
Patrick Shriwise
2eca57a299 Adding mesh memo to Settings.from_xml_element 2022-12-13 23:16:57 -06:00
Patrick Shriwise
43687e5194 Improve comment on recursion arguments 2022-12-12 21:40:48 -06:00
Patrick Shriwise
f3bcad37b7 Addressing comments from @paulromano 2022-12-12 21:30:05 -06:00
Patrick Shriwise
145594ebb8
Apply @paulromano suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-12-12 20:23:49 -06:00
Paul Romano
a8a6f6c49b
Merge pull request #2323 from joshmay1/unset_temp
Add capability to unset cell temperatures
2022-12-09 07:19:07 -06:00
Paul Romano
3addc25319
Merge pull request #2319 from paulromano/allow-low-source-energies
Allow source particles with energy below cutoff
2022-12-07 22:32:26 -06:00
Paul Romano
7a58d3a9f4
Merge pull request #2318 from paulromano/region-parentheses-fix
Fix algorithm for adding parentheses to enforce precedence in region expressions
2022-12-07 22:32:06 -06:00
Patrick Shriwise
916863f82a Renaming and docstring/comment updates 2022-12-07 11:02:10 -06:00
Patrick Shriwise
9c942db45e Correct use of mesh memo in single XML export 2022-12-07 10:10:22 -06:00
Patrick Shriwise
ef13643f29 Some housekeeping in the Python classes 2022-12-07 08:28:23 -06:00
Thomas Kittelmann
a86e74f59a Rename compute_angular_distribution to pencil_beam_model 2022-12-07 12:51:31 +01:00
Thomas Kittelmann
f2c28706a6
Apply suggestions from code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-12-07 10:12:23 +01:00
Patrick Shriwise
7873b4d6c1
Update tests/regression_tests/model_xml/test.py
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-12-06 21:50:49 -06:00
Patrick Shriwise
55d77cf06c Small improvements to read_model_xml 2022-12-06 21:50:08 -06:00
Patrick Shriwise
7fdfed22f3 Some cleanup of file utils 2022-12-06 21:49:46 -06:00
Patrick Shriwise
939adbe70e Updating tests to reflect changes to API 2022-12-06 14:41:26 -06:00
Patrick Shriwise
d639d1dc1b Docstring correction 2022-12-06 14:41:11 -06:00
Patrick Shriwise
5634d8318a Changing name of input argument for Python executor 2022-12-06 14:40:59 -06:00
Patrick Shriwise
bc1791d367 Updates to simplify model filename checking 2022-12-06 14:40:02 -06:00
Patrick Shriwise
270331aff9 Adding function to check if a path is a directory 2022-12-06 14:39:44 -06:00
Patrick Shriwise
574845b18b Moving Model.from_separate_xmls back to Model.from_xml. 2022-12-06 13:18:31 -06:00
Patrick Shriwise
ef2f690e3d Updating handling of single XML input to leverage existing settings::path_input 2022-12-06 13:03:38 -06:00
Patrick Shriwise
cd7c3bf6ba Updates to import/export methods suggested by @paulromano 2022-12-06 13:03:38 -06:00
Patrick Shriwise
2c27d1065a Moving other relevant XML reorder calls and updating expected input again. 2022-12-06 13:03:38 -06:00
Patrick Shriwise
83cf6848d0 Updating expected inputs with reordering 2022-12-06 13:03:38 -06:00
Patrick Shriwise
3f4a9eb7a2 Reordering geometry XML element attributes 2022-12-06 13:03:38 -06:00
Patrick Shriwise
7f5d2a5839 Refactoring model_xml regression tests a bit and adding input checking 2022-12-06 13:03:38 -06:00
Patrick Shriwise
72ff942226 Checking RuntimeError message correctly 2022-12-06 13:03:38 -06:00
Patrick Shriwise
b3225be24d Adding executor tests 2022-12-06 13:03:38 -06:00
Patrick Shriwise
e7f95b0c7a Docstring correction and a note about the recursion 2022-12-06 13:03:38 -06:00
Patrick Shriwise
5d1ead2e6a Addressing some more PR comments. A couple of typo fixes too. 2022-12-06 13:03:38 -06:00
Patrick Shriwise
6f7a6febd3 Updating model XML file format w/ indentation. 2022-12-06 13:03:38 -06:00
Patrick Shriwise
fe47d565fd Spot check in error message from failed run 2022-12-06 13:03:38 -06:00
Patrick Shriwise
7a203fbf72 Correcting parenthesis 2022-12-06 13:03:38 -06:00
Patrick Shriwise
1e6cb68ea4 Addressing a few more comments in C++ code 2022-12-06 13:03:38 -06:00
Patrick Shriwise
366f9e905c Test comment and updated error messages 2022-12-06 13:03:38 -06:00
Patrick Shriwise
d9847163e8 Adding ability to specify an input filename to the executable or to the python exec 2022-12-06 13:03:38 -06:00
Patrick Shriwise
b76825fa9f Addressing some comments from PR 2022-12-06 13:03:38 -06:00
Patrick Shriwise
d034e1de9c Apply suggestions from code review
Incorporating suggestions from @paulromano

Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-12-06 13:03:38 -06:00
Patrick Shriwise
1e7dbe99cf Making sure meshes are only written once to a model.xml file 2022-12-06 13:03:38 -06:00
Patrick Shriwise
662d83a7dd Running some existing regression tests using single XML file 2022-12-06 13:03:38 -06:00
Patrick Shriwise
abd3d515b0 Correcting doc strings for material mapping sent to 2022-12-06 13:03:38 -06:00
Patrick Shriwise
021bb280c9 Adding initial test for exporting model.xmls. Correcting material maps 2022-12-06 13:03:38 -06:00
Patrick Shriwise
611475a835 Restructureing input function calls a little 2022-12-06 13:03:38 -06:00
Patrick Shriwise
b4dcc30f92 Removing walrus operator 2022-12-06 13:03:38 -06:00
Patrick Shriwise
2e716589a1 Other bug fixes 2022-12-06 13:03:38 -06:00
Patrick Shriwise
5ac6e87a68 Properly call read_plots_xml 2022-12-06 13:03:38 -06:00
Patrick Shriwise
af6b0af1e3 Fix loop variable overwrite 2022-12-06 13:03:38 -06:00
Patrick Shriwise
9391f17cff Adding import for single or multiple XMLs 2022-12-06 13:03:38 -06:00
Patrick Shriwise
81aa653d50 Factoring out some common lines between reader functions 2022-12-06 13:03:38 -06:00
Patrick Shriwise
bec9bf6f20 Refactoring model read into it's own function. 2022-12-06 13:03:38 -06:00
Patrick Shriwise
cdd2a6b1ca Correcting doc scope and some reads 2022-12-06 13:03:38 -06:00
Patrick Shriwise
040965245d Adding signatures for reading information from an XML node where necessary. 2022-12-06 13:03:38 -06:00
Patrick Shriwise
7a9d8c95af Keeping old option to write separate XMLs so I can still use to tests to make sure I don't break stuff. 2022-12-06 13:03:38 -06:00
Patrick Shriwise
a09a61e77b Writing all output under a single root node 2022-12-06 13:03:38 -06:00
Patrick Shriwise
ad746cb3e1 Writing all main nodes to a single XML file 2022-12-06 13:03:38 -06:00
Patrick Shriwise
2555b951a4 Factor out to_xml_element methods for XML classes 2022-12-06 13:03:38 -06:00
josh
5b807d4e6c add capability to set cell temperature to None 2022-12-06 18:31:28 +00:00
Amanda Lund
b6075e0543
Merge pull request #2312 from paulromano/no-atomic-relax-fix
Fix photon transport when no atomic relaxation data is present
2022-12-06 09:44:02 -06:00
Paul Romano
772810a643
Merge pull request #2313 from valeriogiusti/valeriogiusti-patch-2
Update universe.py
2022-12-06 06:52:27 -06:00
Paul Romano
f9884650ec Fix IncidentNeutron.from_njoy for high temperatures 2022-12-05 23:11:20 -06:00
Paul Romano
f9309bf090 Check for valid binding energy for photoelectric effect 2022-12-05 22:18:41 -06:00
Paul Romano
743bb31f1f
Merge pull request #2311 from paulromano/depletion-print-output
Only show print() output from openmc.deplete on rank 0
2022-12-05 20:58:41 -06:00
Paul Romano
185920a7f1 Allow source particles with energy below cutoff (will just deposit energy) 2022-12-05 16:19:58 -06:00
Paul Romano
db6a818a56 Ensure complex cell test case covers need for adding precedence 2022-12-05 10:35:24 -06:00
Paul Romano
e99f6e45e9 Fix algorithm for adding parentheses in region expressions 2022-12-05 10:33:52 -06:00
valeriogiusti
43c0dcb1b8
Update universe.py
Running a Jupyter notebook prepared some time ago, I got the following error when trying to plot a universe.

```
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-6-6d5315041afe> in <module>
      1 universe = openmc.Universe(cells=(fuel, moderator))
----> 2 universe.plot(origin=[0.,0.,0.],width=[2.4,2.4],basis='xy')

~/.local/lib/python3.8/site-packages/openmc/universe.py in plot(self, origin, width, pixels, basis, color_by, colors, seed, openmc_exec, axes, **kwargs)
    362             if not img_path.is_file():
    363                 img_path = img_path.with_suffix('.ppm')
--> 364             img = mpimg.imread(img_path)
    365 
    366             # Create a figure sized such that the size of the axes within

/usr/lib/python3/dist-packages/matplotlib/image.py in imread(fname, format)
   1434                 return handler(fd)
   1435     else:
-> 1436         return handler(fname)
   1437 
   1438 

/usr/lib/python3/dist-packages/matplotlib/image.py in read_png(*args, **kwargs)
   1388     def read_png(*args, **kwargs):
   1389         from matplotlib import _png
-> 1390         return _png.read_png(*args, **kwargs)
   1391 
   1392     handlers = {'png': read_png, }

TypeError: Object does not appear to be a 8-bit string path or a Python file-like object

```
The error disappears and the plot is correctly shown if line 364 is changed as follows:

`img = mpimg.imread(str(img_path))`

Does this change sound reasonable? I'm running Python 3.8.10.
2022-12-01 11:49:52 +01:00
Paul Romano
d7fc8e59a2
Merge pull request #2310 from joshmay1/uni_nuclide_densities
Fix bug in `openmc.Universe.get_nuclide_densities()`
2022-11-29 19:49:45 -08:00
josh
3f83699c22 update styling 2022-11-30 00:59:26 +00:00
Paul Romano
ea7e2a13d0 Docs: clarify use of environment variables in tests 2022-11-29 17:31:29 -06:00
Paul Romano
b66d9e0a90 Add check for presence of atomic relaxation data in PhotonInteraction 2022-11-29 16:21:47 -06:00
Paul Romano
01e86efc9e Only show print() output from openmc.deplete on rank 0 2022-11-29 13:29:57 -06:00
Jose Ignacio Marquez Damian
e7b4285bd5 Cleanup 2022-11-29 11:21:04 +01:00
josh
71631ada04 fix universe's get_nuclide_density without volumes present 2022-11-29 03:39:39 +00:00
Paul Romano
a601088e8b
Merge pull request #2305 from paulromano/divide-by-atoms
Rename `divide_by_adens` to `divide_by_atoms`
2022-11-28 08:49:50 -08:00
Jose Ignacio Marquez Damian
e626447a4e
Update gha-script.sh 2022-11-28 11:18:32 -03:00
Jose Ignacio Marquez Damian
4391d601fd
find NCrystal 2022-11-28 11:06:06 -03:00
Jose Ignacio Marquez Damian
19bf624b34
Add NCrystal installation test 2022-11-28 11:03:41 -03:00
Jose Ignacio Marquez Damian
c98a121710
Update gha-install.py 2022-11-28 09:56:10 -03:00
Jose Ignacio Marquez Damian
8598ff7e43
Pass CMAKE_PREFIX_PATH from NCrystall installation 2022-11-28 09:45:27 -03:00
Jose Ignacio Marquez Damian
fff545ac79
Update gha-install-ncrystal.sh 2022-11-28 09:27:12 -03:00
Jose Ignacio Marquez Damian
be330a11b6
Update gha-install-ncrystal.sh 2022-11-28 09:15:45 -03:00
Jose Ignacio Marquez Damian
3e6bb9d5f6
Upgrade installation script to NCrystal 3.5.0 2022-11-28 08:51:23 -03:00
Patrick Shriwise
acb54281da
Merge pull request #2307 from eepeterson/change_centroid_shapes
changing centroid/vertex shape
2022-11-27 22:36:45 -06:00
Ethan Peterson
3794673c70
Apply suggestions from code review
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2022-11-27 15:54:03 -05:00
Paul Romano
33ead74209
Merge pull request #2302 from yardasol/depletion-statepoints-fix
Fix zero-valued `runtime` attribute in depletion statepoints.
2022-11-23 05:07:12 -08:00
Ethan Peterson
5a716f1f3a moved coordinate axis to 0 2022-11-22 11:01:18 -05:00
Olek
8163d7a759 use defaultdict
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-11-22 07:32:48 -06:00
Olek
da7e06dc53
Merge pull request #2301 from paulromano/decay-products
Produce light particles from decay
2022-11-22 07:28:30 -06:00
Paul Romano
a08072e450
Update comment in openmc_operator.py per @yardasol suggestion
Co-authored-by: Olek <45364492+yardasol@users.noreply.github.com>
2022-11-21 15:57:23 -06:00
Paul Romano
102288f94a
Apply @yardasol suggestions from code review
Co-authored-by: Olek <45364492+yardasol@users.noreply.github.com>
2022-11-21 15:36:34 -06:00
Paul Romano
ea0892f0f3 Updated docstring to better explain chain_file and micro_xs 2022-11-21 15:20:12 -06:00
Paul Romano
5dc6550312 Rename divide_by_adens --> divide_by_atoms 2022-11-21 14:51:40 -06:00
Rémi Delaporte-Mathurin
f0721ac535
Apply suggestions from code review
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2022-11-21 14:30:36 -05:00
RemDelaporteMathurin
10a95186e3 origin is tuple + fixed any 2022-11-21 14:07:45 -05:00
RemDelaporteMathurin
3325667c51 minor version bump for statepoint files 2022-11-21 12:22:39 -05:00
RemDelaporteMathurin
f51f181761 fixed optional xml reading 2022-11-21 11:53:49 -05:00
RemDelaporteMathurin
b63ec9cdc3 read mesh optional 2022-11-21 09:48:42 -05:00
RemDelaporteMathurin
df1a45b654 origin from_hdf5 2022-11-21 09:46:13 -05:00
RemDelaporteMathurin
8681751238 check length origin 2022-11-21 09:45:11 -05:00
Rémi Delaporte-Mathurin
6d787d5fb0
Apply suggestions from code review
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2022-11-21 09:39:01 -05:00
Rémi Delaporte-Mathurin
c5affa805e
Review suggestions
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2022-11-21 09:37:57 -05:00
Erik B Knudsen
c9c74f08b2 apply clang-format 2022-11-21 00:34:30 +01:00
Jose Ignacio Marquez Damian
9e1abb3284
Update gha-install-ncrystal.sh 2022-11-19 10:47:26 +01:00
Jose Ignacio Marquez Damian
39d0c5cd61
Try to initialize with setup.sh 2022-11-19 09:38:34 +01:00
Jose Ignacio Marquez Damian
b199db9cb9
Update gha-install-ncrystal.sh 2022-11-19 09:06:42 +01:00
Jose Ignacio Marquez Damian
d7ab491f47
Try fix of NCrystal install 2022-11-19 08:57:00 +01:00
Erik B Knudsen
fab1ddac00
prefer native as default
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-11-19 02:19:41 +01:00
Erik B Knudsen
ccbef891ef update to doc-string 2022-11-19 01:49:31 +01:00
Erik B Knudsen
727161f95a remove some in-code comments 2022-11-19 01:44:47 +01:00
Erik B Knudsen
8bfb1af81e remove unneccessary in-code comments 2022-11-19 01:41:02 +01:00
Erik B Knudsen
a40cc14d8e check in the c++-layer if it's an mcpl-file 2022-11-19 00:33:04 +01:00
Erik B Knudsen
a299dcc56b add a documentation entry to surf_source_write 2022-11-19 00:28:22 +01:00
Erik B Knudsen
6442de6834
remove unneccessary initialization
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-11-18 23:26:24 +01:00
yardasol
d45c37b206 Add test for runtime attribute on depletion statepoints 2022-11-18 15:54:55 -06:00
Jose Ignacio Marquez Damian
b9a1fd5624 Merge branch 'mixed_ncrystal' of https://github.com/highness-eu/openmc into mixed_ncrystal 2022-11-18 22:41:19 +01:00
Jose Ignacio Marquez Damian
b9e8f1324e Attempt to fix NCrystal installation script 2022-11-18 22:40:46 +01:00
Jose Ignacio Marquez Damian
8cf9dbe320 Fixed in NCrystal docs 2022-11-18 22:28:04 +01:00
Jose Ignacio Marquez Damian
87ed26babe
Add option to install NCrystal 2022-11-18 17:48:19 -03:00
Jose Ignacio Marquez Damian
5f8e64b463
Add NCrystal vairables to ci.yml 2022-11-18 17:47:21 -03:00
Jose Ignacio Marquez Damian
91f939a391 Add flag for NCrystal 2022-11-18 18:26:31 +01:00
yardasol
e4281408f6 reset timers after writing statepoint file 2022-11-18 10:31:58 -06:00
Jose Ignacio Marquez Damian
54745f5076
Changed example NCrystal cfg strings 2022-11-18 11:11:37 -03:00
Rémi Delaporte-Mathurin
f60f95feb4
[skip ci] removed # TODOs 2022-11-18 09:03:35 -05:00
jiankai-yu
a17fe6cc82
Add decay heat function in material (#2287)
* add decay heat in material.py

* add decay_energy.json into eggs

* fix a bug when returned decay_ery is None

* add unit test for decayheat

* fix typo in doc string

* address reviewer's comments

* add user defined decay energy

* remove json for decay energy

* address a few comments

* add to docs
2022-11-17 22:57:01 -06:00
Jose Ignacio Marquez Damian
24572a71f2 Added simple NCrystal test 2022-11-17 16:33:48 +01:00
Jose Ignacio Marquez Damian
cf96ddf8bb
Basic introduction to NCrystal
Included references to the main papers and documentation
2022-11-17 13:47:03 +01:00
Paul Romano
d6a4a3ecb9 Produce light particles from decay 2022-11-16 23:07:52 -06:00
Paul Romano
7a6d8cc58f
Merge pull request #2297 from paulromano/compton-profile-bugfix
Prevent out-of-bounds memory access on Compton profile data
2022-11-16 20:50:37 -08:00
Erik B Knudsen
3e60d51f90 from_xml mcpl-settings functionality 2022-11-16 13:54:08 +01:00
Erik B Knudsen
b2320ae1d4 not needed since mcpl-file is created by openmc 2022-11-16 13:42:25 +01:00
Erik B Knudsen
e224adf431
follow source code conventions
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-11-16 10:31:15 +01:00
Paul Romano
1962139236
Merge pull request #2298 from fusion-energy/improved_config_error_message
added acceptable keys to error message
2022-11-15 05:26:33 -08:00
Paul Romano
7980d0b4c5
Merge pull request #2299 from pshriwise/ww_msg
Correction to error message regarding WW shape
2022-11-15 05:25:41 -08:00
Paul Romano
df3334f19a
Merge pull request #2265 from joshmay1/temp_interp_tol
Adds a tolerance for temperatures slightly out of bounds when interpolating
2022-11-14 21:24:52 -08:00
Patrick Shriwise
b2d5ca1176 Fixing a typo and adding some clarity 2022-11-14 19:50:47 -06:00
josh
dc5f2746d3 avoid double reading thermal scattering libraries 2022-11-14 20:36:11 +00:00
Patrick Shriwise
70981bcd5d Correction to error message regarding WW shape 2022-11-14 13:05:43 -06:00
shimwell
2aef8052e9 added acceptable keys to help user 2022-11-13 16:11:23 +00:00
myerspat
d65ac06bd6 Catch2 unit testing capabilities and alias sampling unit test 2022-11-12 13:32:41 -05:00
myerspat
4072fc430b Removing excess probability vector 2022-11-12 13:31:27 -05:00
myerspat
a28a175261 Added catch2 submodule for cpp testing 2022-11-12 13:19:21 -05:00
Paul Romano
6ede028b39 Prevent out-of-bounds memory access on Compton profile data 2022-11-11 20:50:36 -06:00
Paul Romano
765df9115f
Merge pull request #2295 from colinelarmier/fix_yield
Fix the case where the yield is zero.
2022-11-11 12:03:40 -08:00
Coline Larmier
ae785fda5f Fix the case where the yield is zero.
Problem detected in the context of a code-to-code comparison between OpenMC and TRIPOLI-4:
- configuration: sphere of radius R = 30 cm containing the isotope ZR93 at 293K
- sphere irradiated at the center by an isotropic, mono-energy, point source (E_0 = 14.1 MeV)
- data from JEFF-3.3

For some isotopes, namely ZR93 at 293K, the sampled yield can be equal to 0 (namely for MT=5: interaction "n-other").
In such a case, it is necessary to deactivate the particle.
2022-11-11 10:47:13 +01:00
Paul Romano
7d824ce1af
Merge pull request #2266 from eepeterson/polygon_surface
Polygon composite surface
2022-11-10 14:44:19 -08:00
Paul Romano
d56b5026d6
Merge pull request #2293 from pshriwise/filter-enum
FilterType Enumerator
2022-11-10 13:05:13 -08:00
Ethan Peterson
2283e08fdc add abs_tol to prevent cones with infinite or 0 slope 2022-11-10 13:00:11 -05:00
Ethan Peterson
2adbe97194 updated algorithms and documentation 2022-11-10 11:15:24 -05:00
Ethan Peterson
d314bedbd7 improving documentation and style 2022-11-10 11:15:24 -05:00
Ethan Peterson
b0d71b3146 Apply suggestions from @paulromano code review
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-11-10 11:15:24 -05:00
Ethan Peterson
8ddb045c7d added warning about non-transmissive boundary_type 2022-11-10 11:15:24 -05:00
Ethan Peterson
a587f5e1c9 forgot to remove print 2022-11-10 11:15:24 -05:00
Ethan Peterson
fdc3cfcfbb fixed proper boundary_type setting? 2022-11-10 11:15:24 -05:00
Ethan Peterson
299525984f simplified offset method 2022-11-10 11:15:24 -05:00
Ethan Peterson
13b1bb88d0 added unit test 2022-11-10 11:15:24 -05:00
Ethan Peterson
bf58a46a9c cleaning up and moving all methods to instance methods rather than module 2022-11-10 11:15:24 -05:00
Ethan Peterson
a26dcc65b7 cleaning up/consolidating functions 2022-11-10 11:15:24 -05:00
Ethan Peterson
3fe2bf4cb6 cleaning up unnecessary methods 2022-11-10 11:15:24 -05:00
Ethan Peterson
f6f2ed7b17 got other basis sets working 2022-11-10 11:15:24 -05:00
Ethan Peterson
aa7aab1768 method to break polygon into convex sets complete 2022-11-10 11:15:24 -05:00
Ethan Peterson
f6152d8250 working on other basis options 2022-11-10 11:15:24 -05:00
Jose Ignacio Marquez Damian
1f3c5ed6bc
Add use instructions and examples for NCrystal 2022-11-10 13:04:47 -03:00
Jose Ignacio Marquez Damian
e64bf6a7ff
Add installation instructions for NCrystal 2022-11-10 12:31:45 -03:00
Patrick Shriwise
d765d3224f
Update openmc/filter.py
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-11-10 09:02:31 -06:00
Paul Romano
2ed86f57fb
Merge pull request #2290 from HunterBelanger/fix_tsl_data
Fix for non-zero CDF start points in incoherent inelastic data
2022-11-10 05:30:06 -08:00
Paul Romano
1a91fc6fcb
Merge pull request #2263 from eepeterson/redundant_surf_fix
Fix for finding redundant surfaces
2022-11-10 05:18:24 -08:00
Patrick Shriwise
5e7f3f7efd Adding alias for CellbornFilter in the Python API 2022-11-09 17:34:05 -06:00
Patrick Shriwise
aaaff62135 Using new CellBornFilter class name in the tallies reg test 2022-11-09 17:33:01 -06:00
Patrick Shriwise
67e18c0db6 Updating documentation for CellBornFilter 2022-11-09 16:34:46 -06:00
Patrick Shriwise
21a14f6eeb
Add suggestion from @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-11-09 16:23:48 -06:00
Ethan Peterson
1110038939 remove get_redundant_surfaces and cache 2022-11-08 21:04:15 -05:00
myerspat
1abb728b4f bug fixing Discrete constructor 2022-11-08 19:42:16 -05:00
Patrick Shriwise
8d58588341 Changing CellBorn filter name to match other class names 2022-11-05 21:20:41 -05:00
Patrick Shriwise
06fbf3fe01 Switch to use of FilterType enum for comparisons 2022-11-05 21:20:41 -05:00
Patrick Shriwise
20718f5121 Adding enumerator for filter types. 2022-11-05 21:20:41 -05:00
myerspat
b469b3a169 Added alias sampling to discrete distribution 2022-11-05 13:50:27 -04:00
Hunter Belanger
6a0d504303 Fix wording of comments 2022-11-05 13:05:47 +01:00
Paul Romano
1a7762283d
Merge pull request #2239 from myerspat/region-refactoring
Region refactor
2022-11-04 20:12:47 -05:00
Paul Romano
cd843fc351
Merge pull request #2280 from pshriwise/dagmc-missing-mat
Improve DAGMC messages for missing materials
2022-11-04 20:12:06 -05:00
Patrick Shriwise
7266fcc5ed Making error messages consistent 2022-11-04 17:20:31 -05:00
Patrick Shriwise
075ff0304c Adding tests for expected error messages 2022-11-04 17:20:29 -05:00
Patrick Shriwise
89fafb4fdf Improving missing material error for DAGMC material by ID 2022-11-04 17:19:48 -05:00
Paul Romano
647c9d185e
Update include/openmc/cell.h 2022-11-04 13:26:13 -05:00
Hunter Belanger
6cb7a178e8 Fix spelling error. 2022-11-03 19:09:28 +01:00
Hunter Belanger
fd516c1c4c Doctors the incoherent inelastic TSL data when in continuous format. 2022-11-03 18:55:06 +01:00
Paul Romano
3682c02d1f
Merge pull request #2282 from shimwell/update_atomic_mass_to_amdc_2020
swapped from 2016 to 2020 amdc data
2022-11-03 12:10:13 -05:00
Jonathan Shimwell
235195b125
Changed comment to reference 2020 atomic data version.
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-11-02 12:20:50 +00:00
Paul Romano
309c78dc78
Merge pull request #2273 from shimwell/type_hinting_for_source.py
Type hinting for source.py
2022-11-02 06:50:10 -05:00
josh
81b88cc018 Clean up comparisons and lump test cross sections 2022-11-02 02:23:37 +00:00
Jonathan Shimwell
375af321d8
corrected types from code review by @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-11-01 15:49:22 +00:00
Ethan Peterson
71aa46a0b1
Merge pull request #2284 from pshriwise/add-ww-rndtrp-test
Adding __eq__ method and roundtrip test for weight windows
2022-10-30 10:37:09 -04:00
erkn
fadb02f989 Merge branch 'mcpl_input' of github.com:ebknudsen/openmc into mcpl_input 2022-10-30 12:30:16 +01:00
josh
f6a7b61c4a address a few more formatting issues 2022-10-30 03:31:26 +00:00
josh
fc0e2c9bd0 undo formatting change of settings file 2022-10-30 03:28:14 +00:00
josh
0792d987d0 Merge branch 'develop' into temp_interp_tol 2022-10-30 03:10:57 +00:00
Ethan Peterson
b9c1eb34fb
Merge pull request #2283 from paulromano/chain-reduce-sources-bugfix
Make sure Chain.reduce preserves decay source information
2022-10-29 09:11:22 -04:00
Jonathan Shimwell
21ec8baea4 updated reference depletion results 2022-10-28 22:26:14 +01:00
Jonathan Shimwell
10b11c02a8 f strings and pep8 2022-10-28 22:25:36 +01:00
Jonathan Shimwell
7eb1a7bbd0 updated reference micro xs values 2022-10-28 22:07:46 +01:00
Patrick Shriwise
b00404be7c Updating dimension type to tuple in a couple of test checks 2022-10-28 04:34:35 +00:00
Patrick Shriwise
43033b656c Returning a tuple for RegularMesh.dimension 2022-10-27 14:47:16 -05:00
Patrick Shriwise
80563f1b8c Absolute file paths on system 2022-10-27 14:43:14 -05:00
Patrick Shriwise
53ec17eb77 fix comment 2022-10-27 11:41:12 -05:00
Patrick Shriwise
5c589b7a6c Adding __eq__ method and roundtrip test for wws 2022-10-27 11:40:12 -05:00
Jonathan Shimwell
3623408bc5 avoid namespace overwrite of union 2022-10-27 17:38:27 +01:00
Jonathan Shimwell
459b0f1fcf avoid union namespace overwrite 2022-10-27 16:17:49 +01:00
Paul Romano
df9f7ec814 Make sure Chain.reduce preserves information in the .sources attribute 2022-10-27 08:51:32 -05:00
Jonathan Shimwell
9ff159a4db updated to new AME format 2022-10-26 21:08:12 +01:00
Jonathan Shimwell
2af754baa9 forward ref for openmc.source 2022-10-26 20:32:44 +01:00
Jonathan Shimwell
84b055e15b reordered imports to avoid circular imports 2022-10-26 20:24:23 +01:00
Jonathan Shimwell
5d177a5ace
Apply suggestions from code review by @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-10-26 20:21:06 +01:00
Ethan Peterson
f5f42a4c80
Update openmc/geometry.py
Co-authored-by: Patrick Shriwise <pshriwise@gmail.com>
2022-10-26 13:37:09 -04:00
Jonathan Shimwell
6131136bd1 swapped from 2016 to 2020 amdc data 2022-10-26 18:33:26 +01:00
Ethan Peterson
e8d3e14adf cache redundant_surfaces 2022-10-26 12:13:43 -04:00
Ethan Peterson
a46cafa7fe addressed @pshriwise comments 2022-10-26 09:41:03 -04:00
Ethan Peterson
33021f7af1 removed precision parameter 2022-10-26 09:41:03 -04:00
Ethan Peterson
fec53aa1fa updated tests 2022-10-26 09:41:03 -04:00
Ethan Peterson
4604c10da1 added attributes and warnings 2022-10-26 09:41:03 -04:00
Ethan Peterson
1ab2cbec40 revert to False because of failing tests 2022-10-26 09:41:03 -04:00
Ethan Peterson
a67b330d8f round and change default to True 2022-10-26 09:41:03 -04:00
Paul Romano
97f1e2fdd7
Merge pull request #2276 from openmc-dev/yardasol-patch-1
small grammar fix in `Settings.temperature` docstring
2022-10-25 22:51:00 -05:00
Paul Romano
586f958f5d
Merge pull request #2272 from paulromano/move-to-0.13.3-dev
Change version number to 0.13.3-dev
2022-10-25 22:49:35 -05:00
Patrick Shriwise
781603ba70
Merge pull request #2275 from eepeterson/ww_bugfix
ww_bounds bug fix in setter and getter
2022-10-25 07:30:19 -05:00
Ethan Peterson
7c9a18ddd0
Update openmc/weight_windows.py 2022-10-24 16:49:09 -04:00
Ethan Peterson
d78433ad3d reshape in from_xml and update inputs 2022-10-24 16:47:34 -04:00
Ethan Peterson
316cca3304
Merge pull request #1 from shimwell/adding_test_for_lower_ww_bounds_shape
added test for lower ww shape
2022-10-24 15:19:36 -04:00
Olek
89ba5afb6c
Use @lewisgross1296 suggestion
Co-authored-by: Lewis Gross <43077972+lewisgross1296@users.noreply.github.com>
2022-10-24 13:36:36 -05:00
Jonathan Shimwell
3d26f1992c added test for lower ww shape 2022-10-24 19:13:22 +01:00
Olek
58b1a80b64
small grammar fix in Settings.temperature docstring 2022-10-24 13:02:09 -05:00
Ethan Peterson
a9933c5ecf bounds.reshape doesn't modify bounds it returns a new array 2022-10-24 13:23:15 -04:00
Jonathan Shimwell
4116f6cda0 used forwards ref to avoid circlar imports 2022-10-21 19:04:45 +01:00
Jonathan Shimwell
17a6552027 added return types 2022-10-21 18:47:07 +01:00
Jonathan Shimwell
1a7066a885 added type hints for source.py 2022-10-21 18:38:44 +01:00
Paul Romano
1f973e1ebe Change version number to 0.13.3-dev 2022-10-21 12:00:58 -05:00
RemDelaporteMathurin
b874d83634 only translate when origin is not 0, 0, 0 2022-10-21 15:55:08 +02:00
Thomas Kittelmann
a3dd55d8bc first stab at gha-install-ncrystal.sh 2022-10-21 15:04:57 +02:00
RemDelaporteMathurin
b0743dfdea fixed cv.check_type origin 2022-10-21 11:56:21 +02:00
Thomas Kittelmann
aca4fcb42b NCrystal cfgstr printout now mentions material ID 2022-10-21 10:40:30 +02:00
Thomas Kittelmann
f2e807e942 Move NCrystalRNGWrapper data member into explicit private section as requested 2022-10-21 10:40:30 +02:00
Thomas Kittelmann
a5b811ec89 Use new NCrystal getFlattenedComposition method to better support more complicated materials 2022-10-21 10:40:30 +02:00
Thomas Kittelmann
52ee2c37ce Print where NCrystal was found as suggested by @paulromano
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-10-21 10:40:30 +02:00
Jose Ignacio Marquez Damian
fdf763e801 Couple of fixes 2022-10-21 10:40:30 +02:00
Jose Ignacio Marquez Damian
5afcc9e49b Apply clang-format 2022-10-21 10:40:30 +02:00
Jose Ignacio Marquez Damian
2e19260dea Implement recommended changes 2022-10-21 10:40:30 +02:00
Jose Ignacio Marquez Damian
29a10eafd3 Removed MacroNCrystalXS
This was left from a previous implementation. Now it is not needed because NCrystal just takes over all neutron scattering events below a given energy threshold.
2022-10-21 10:40:30 +02:00
Jose Ignacio Marquez Damian
70d5c76ebd Fixed material.h 2022-10-21 10:40:30 +02:00
Jose Ignacio Marquez Damian
9c54ac0b6b Fix access to private attributes 2022-10-21 10:40:30 +02:00
Thomas Kittelmann
0f33e0b11c Add temporary requirement of natural elements in NCrystal materials 2022-10-21 10:40:30 +02:00
Jose Ignacio Marquez Damian
0e0cd0a22d Added hooks for NCrystal 2022-10-21 10:40:30 +02:00
josh
7cb6883647 output bounding temp for cell temp out of bounds 2022-10-16 03:57:11 +00:00
Erik B Knudsen
6a1cb09ac0
Merge branch 'openmc-dev:develop' into mcpl_input 2022-10-14 01:43:44 +02:00
Erik B Knudsen
309893230c Merge branch 'mcpl_output_dev' into mcpl_input 2022-10-14 01:43:40 +02:00
Erik B Knudsen
04edce7dc2 do read and write regression test
almost dientical to source_file reg. test
2022-10-14 01:41:44 +02:00
Erik B Knudsen
344efa8de6 don't compress by default 2022-10-14 01:41:21 +02:00
Erik B Knudsen
5da08f6b0e fix logic to avoid writing both kinds of source file 2022-10-14 01:40:52 +02:00
Erik B Knudsen
81fa3b45a3 mcpl-file output simimlar to regular source output file 2022-10-14 00:22:28 +02:00
josh
bee963be86 Merge branch 'develop' into temp_interp_tol 2022-10-13 21:33:39 +00:00
josh
b0a300aedc add to existing temp interp test, update doccs 2022-10-13 21:24:25 +00:00
erkn
cb82616ebf Merge branch 'mcpl_output_dev' into mcpl_input 2022-10-12 21:55:35 +02:00
Erik B Knudsen
94fb5f8fa6 enable MPI
mpi-nodes are gathered sequentially (as for h5)
2022-10-12 19:32:40 +02:00
Erik B Knudsen
ca396268b5 protect against compilation wo mcpl 2022-10-12 19:32:09 +02:00
Erik B Knudsen
e3f1bdaca1 enable mcpl from the python layer
if the source filename ends with mcpl use that
2022-10-12 19:30:38 +02:00
Rémi Delaporte-Mathurin
9ecaafad7e
Merge pull request #3 from pshriwise/centre_for_cylinder_spherical_meshes
Naming tally in activation unit test
2022-10-12 09:43:34 +02:00
Patrick Shriwise
444a80012b Naming tally in activation unit test 2022-10-11 23:38:13 -05:00
RemDelaporteMathurin
c6b89feaef fixed gold standard 2022-10-11 17:14:21 +00:00
RemDelaporteMathurin
48d75accdd fixed cylindrical mesh test 2022-10-11 17:12:55 +00:00
RemDelaporteMathurin
3792c6fb70 fixed unit test 2022-10-11 17:11:54 +00:00
RemDelaporteMathurin
a97b202c2d updated to_hdf5 2022-10-11 16:41:43 +00:00
RemDelaporteMathurin
408f2fd714 Merge branch 'pshriwise-centre_for_cylinder_spherical_meshes' into centre_for_cylinder_spherical_meshes 2022-10-11 16:26:06 +00:00
RemDelaporteMathurin
3bdb123d7e Merge branch 'centre_for_cylinder_spherical_meshes' of https://github.com/pshriwise/openmc into pshriwise-centre_for_cylinder_spherical_meshes 2022-10-11 16:25:05 +00:00
Patrick Shriwise
adad6e7cd4 Making origin type Positiong. Adding function to parse position from node. 2022-10-11 11:21:31 -05:00
RemDelaporteMathurin
b2d1729287 origin_ instead of origin 2022-10-11 16:08:03 +00:00
RemDelaporteMathurin
76fbdf7fbf centre to origin 2022-10-11 15:41:38 +00:00
RemDelaporteMathurin
27e3bb427a array<double, 3> for origin CylindricalMesh 2022-10-11 15:36:58 +00:00
RemDelaporteMathurin
15f45bcd1d substract before mapping 2022-10-11 15:29:10 +00:00
RemDelaporteMathurin
94547f7c4b new type for centre_ 2022-10-11 15:24:13 +00:00
Erik B Knudsen
73b97b9575 Merge branch 'mcpl_input' of github.com:ebknudsen/openmc into mcpl_input 2022-10-11 16:53:37 +02:00
Erik B Knudsen
4623cb4c9c Merge branch 'mcpl_output_dev' of github.com:ebknudsen/openmc into mcpl_output_dev 2022-10-11 16:52:20 +02:00
erkn
7759028d80 enable mcpl surf_source_write in the python layer 2022-10-11 16:50:40 +02:00
erkn
59a949de36 fix typo causing unit length errors 2022-10-11 16:50:40 +02:00
erkn
93a9270efc fix malformed format string 2022-10-11 16:50:40 +02:00
Erik B Knudsen
6e523fa1f8 must have a full filename 2022-10-11 16:50:40 +02:00
erkn
28cd0c5d3a fix misnamed variable and remove accientally committed code 2022-10-11 16:50:39 +02:00
Erik B Knudsen
9065bdac3a refactor MCPL file read part of FileSource
A new constructor is added to FileSource that reads from
a given MCPL-file.
2022-10-11 16:50:15 +02:00
Erik B Knudsen
172fec2356 add cond. compilation guards for MCPL functions 2022-10-11 16:50:15 +02:00
Erik B Knudsen
8b78374934 fix typo 2022-10-11 16:50:15 +02:00
Erik B Knudsen
cd9eb5b1b2 add a trigger to simulation control 2022-10-11 16:50:15 +02:00
erkn
9d7105ebc7 wip add MCPL-out to openmc
code for writing a source_bank/point compiles but is untested
2022-10-11 16:50:15 +02:00
erkn
52cf6823e6 wip add MCPL-out to openmc
code for writing a source_bank/point compiles but is untested
2022-10-11 16:50:15 +02:00
erkn
3c33ec3b9f refactor MCPL file read part of FileSource
A new constructor is added to FileSource that reads from
a given MCPL-file.
2022-10-11 16:50:13 +02:00
Erik B Knudsen
56cddd25e2 do not define these functions if no MCPL present 2022-10-11 16:49:44 +02:00
erkn
6bceb7c30c wip add MCPL-out to openmc
code for writing a source_bank/point compiles but is untested
2022-10-11 16:49:44 +02:00
Erik B Knudsen
bdc76d95fc refactor MCPL file read part of FileSource
A new constructor is added to FileSource that reads from
a given MCPL-file.
2022-10-11 16:49:44 +02:00
Erik B Knudsen
76e726b527 add cond. compilation guards for MCPL functions 2022-10-11 16:49:44 +02:00
Erik B Knudsen
22ce618601 fix typo 2022-10-11 16:49:44 +02:00
Erik B Knudsen
b6aa2dc429 add mcpl-output settings 2022-10-11 16:49:44 +02:00
Erik B Knudsen
f76e416ee6 use find_package instead - MCPL now supports this 2022-10-11 16:49:44 +02:00
Erik B Knudsen
1519f4f3e6 add a trigger to simulation control 2022-10-11 16:49:44 +02:00
erkn
5462216deb wip add MCPL-out to openmc
code for writing a source_bank/point compiles but is untested
2022-10-11 16:49:44 +02:00
erkn
95338eada0 refactor MCPL file read part of FileSource
A new constructor is added to FileSource that reads from
a given MCPL-file.
2022-10-11 16:46:23 +02:00
Erik B Knudsen
5640bdb9eb fix typo
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-10-11 16:45:54 +02:00
Erik B Knudsen
3b052f03cf expose a python function to check for mcpl 2022-10-11 16:45:54 +02:00
Erik B Knudsen
2730f1954f allow electrons and positrons as well 2022-10-11 16:45:54 +02:00
Erik B Knudsen
bb8c022d77 fail without tripping the entire test-process 2022-10-11 16:45:54 +02:00
Erik B Knudsen
2773add047 needed to avoid name clashes with other tests 2022-10-11 16:45:54 +02:00
Erik B Knudsen
2fa4451938 only add mcpl-support if OPENMC_MCPL is defined 2022-10-11 16:45:54 +02:00
erkn
96ae7b4228 fix misprints 2022-10-11 16:45:53 +02:00
Erik B Knudsen
46e648cf38 add a source type to the settings interface 2022-10-11 16:44:53 +02:00
Erik B Knudsen
2cbcd53f07 add an option to turn on mcpl-support 2022-10-11 16:44:53 +02:00
Erik B Knudsen
1509420c21 fix bugs and finalize interface to MCPL 2022-10-11 16:44:53 +02:00
Erik B Knudsen
a123d239dd add a check that the test input got created as intended 2022-10-11 16:44:53 +02:00
Erik B Knudsen
c21ff938c7 yet another necessary file 2022-10-11 16:44:53 +02:00
Erik B Knudsen
c93defee59 test target result 2022-10-11 16:44:53 +02:00
Erik B Knudsen
e87ebfebc2 set seed to make test deteministic 2022-10-11 16:44:53 +02:00
Erik B Knudsen
935396e40b add necessary xmls 2022-10-11 16:44:53 +02:00
Erik B Knudsen
005189bfdf fix misprints 2022-10-11 16:44:53 +02:00
erkn
b2f83857e4 now compiles fine if mcpl is indeed installed 2022-10-11 16:35:19 +02:00
erkn
c6b42e828c don't zip the output-file 2022-10-11 16:35:18 +02:00
erkn
3e805cce15 c-prog to generate a dummy mcpl 2022-10-11 16:35:18 +02:00
erkn
999acbba9a (wip): skeleton for input only test 2022-10-11 16:35:18 +02:00
Erik B Knudsen
d21ecfa6a7 internals of sample and constructor 2022-10-11 16:35:18 +02:00
Erik B Knudsen
249a554980 declarations of MCPL-internals 2022-10-11 16:35:18 +02:00
Erik B Knudsen
cfbd397d45 include mcpl header 2022-10-11 16:35:18 +02:00
Erik B Knudsen
bf0c5d7f9a add placeholder skeleton for MCPL-input 2022-10-11 16:35:18 +02:00
josh
3e2ddceaac Add tolerance for interp temps outside of bounds 2022-10-11 03:03:51 +00:00
erkn
72251eb30a enable mcpl surf_source_write in the python layer 2022-10-11 02:00:54 +02:00
erkn
aeadaf0b2f fix typo causing unit length errors 2022-10-11 00:48:44 +02:00
erkn
0706a0eca3 fix malformed format string 2022-10-11 00:46:32 +02:00
RemDelaporteMathurin
5632a40e5c Merge branch 'develop' into centre_for_cylinder_spherical_meshes 2022-10-07 13:08:51 +00:00
RemDelaporteMathurin
1ed096f660 added centre tag to standard 2022-10-07 12:53:34 +00:00
RemDelaporteMathurin
e1dbe49bbb correct type for centre_ 2022-10-07 11:06:24 +00:00
RemDelaporteMathurin
fc5aa68d73 removed auto + ; 2022-10-07 10:59:52 +00:00
RemDelaporteMathurin
61b4f30dd4 declaring centre_ in C file 2022-10-07 10:59:35 +00:00
RemDelaporteMathurin
e394637f2f declare variable with auto 2022-10-07 09:32:08 +00:00
RemDelaporteMathurin
bdd13ba3f4 attempt #2 2022-10-07 09:15:27 +00:00
RemDelaporteMathurin
a104c1f890 [skip ci] removed test 2022-10-07 09:07:51 +00:00
RemDelaporteMathurin
d194e00080 test if grid_ is defined in this scope 2022-10-07 09:00:27 +00:00
RemDelaporteMathurin
896ae2792e centre to centre_ 2022-10-07 08:40:04 +00:00
RemDelaporteMathurin
21200d9b6e offsets the write_to_vtk coordinates 2022-10-07 07:42:34 +00:00
RemDelaporteMathurin
16add87c05 now reads back from xml 2022-10-07 07:18:52 +00:00
RemDelaporteMathurin
5787616ae4 added two tests to check centre was written/read to/from xml 2022-10-07 07:18:00 +00:00
RemDelaporteMathurin
f0f5e34b33 read centre from xml 2022-10-07 06:55:56 +00:00
RemDelaporteMathurin
81ac9b0fd9 setters/getters 2022-10-07 06:50:45 +00:00
RemDelaporteMathurin
c20b351a2f write to xml 2022-10-07 06:49:13 +00:00
RemDelaporteMathurin
2a4c8bbb9b centre attribute to CylindricalMesh and SphericalMesh 2022-10-07 06:47:11 +00:00
myerspat
f60520e8c5 Removed simple_ from dagmc 2022-10-06 12:28:18 -04:00
myerspat
169d6d93dc Added Doxygen comments to Region data and methods. Added default implementation for new void functions. 2022-10-05 21:14:48 -04:00
Erik B Knudsen
12f088a5ce must have a full filename 2022-10-06 01:33:21 +02:00
erkn
982377b0cd fix misnamed variable and remove accientally committed code 2022-10-05 14:31:05 +02:00
erkn
9815bf909a Merge branch 'mcpl_output_dev' of github.com:ebknudsen/openmc into mcpl_output_dev 2022-10-05 14:16:39 +02:00
Erik B Knudsen
3b7c4f6d2f do not define these functions if no MCPL present 2022-10-05 11:38:49 +02:00
erkn
e3fbeac636 wip add MCPL-out to openmc
code for writing a source_bank/point compiles but is untested
2022-10-05 11:37:35 +02:00
Erik B Knudsen
179df58685 refactor MCPL file read part of FileSource
A new constructor is added to FileSource that reads from
a given MCPL-file.
2022-10-05 11:32:07 +02:00
Erik B Knudsen
cba745b28b add cond. compilation guards for MCPL functions 2022-10-05 11:30:11 +02:00
Erik B Knudsen
43538ac202 fix typo 2022-10-05 11:30:11 +02:00
Erik B Knudsen
9b58c2f6dc add mcpl-output settings 2022-10-05 11:30:11 +02:00
Erik B Knudsen
91cd304f0e use find_package instead - MCPL now supports this 2022-10-05 11:30:11 +02:00
Erik B Knudsen
2ba7f8d188 add a trigger to simulation control 2022-10-05 11:30:11 +02:00
erkn
6038555def wip add MCPL-out to openmc
code for writing a source_bank/point compiles but is untested
2022-10-05 11:30:11 +02:00
Erik B Knudsen
5e82bb2e1f expose a python function to check for mcpl 2022-10-05 11:29:46 +02:00
Erik B Knudsen
0b8bd9b43c Merge branch 'mcpl_output_dev' of github.com:ebknudsen/openmc into mcpl_output_dev 2022-10-05 11:01:34 +02:00
Erik B Knudsen
83e2921034 add cond. compilation guards for MCPL functions 2022-10-05 11:00:39 +02:00
Erik B Knudsen
172c518f0e fix typo 2022-10-05 10:59:28 +02:00
Erik B Knudsen
7418cb99dd add mcpl-output settings 2022-10-05 10:59:02 +02:00
Erik B Knudsen
2de20231ad use find_package instead - MCPL now supports this 2022-10-05 10:56:36 +02:00
RemDelaporteMathurin
facc1995e3 marks 2022-10-05 09:29:19 +02:00
Erik B Knudsen
314f3dbbab do not define these functions if no MCPL present 2022-10-04 10:11:06 +02:00
Erik B Knudsen
5d1a84e0e9 Merge branch 'mcpl_output_dev' of github.com:ebknudsen/openmc into mcpl_output_dev 2022-10-04 09:49:17 +02:00
myerspat
06312b0535 Refactored CSGCell to use Region 2022-09-25 22:05:22 -04:00
Erik B Knudsen
04c8ffc81c add a trigger to simulation control 2022-09-16 16:07:49 +02:00
erkn
f0af56b181 wip add MCPL-out to openmc
code for writing a source_bank/point compiles but is untested
2022-09-16 16:07:49 +02:00
Erik B Knudsen
55f2be19e6 refactor MCPL file read part of FileSource
A new constructor is added to FileSource that reads from
a given MCPL-file.
2022-09-16 16:07:22 +02:00
Erik B Knudsen
3d28170b8a Merge branch 'mcpl_input' of github.com:ebknudsen/openmc into mcpl_input 2022-09-16 16:06:11 +02:00
Erik B Knudsen
563665f161 Merge branch 'mcpl_output_dev' of github.com:ebknudsen/openmc into mcpl_output_dev 2022-09-16 15:59:19 +02:00
Erik B Knudsen
d07223bf68 add a trigger to simulation control 2022-09-16 15:56:47 +02:00
erkn
73a391daef wip add MCPL-out to openmc
code for writing a source_bank/point compiles but is untested
2022-09-16 15:56:47 +02:00
erkn
71568d4f4b refactor MCPL file read part of FileSource
A new constructor is added to FileSource that reads from
a given MCPL-file.
2022-09-16 15:56:45 +02:00
Erik B Knudsen
ab665fb456 fix typo
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-09-16 15:54:26 +02:00
Paul Romano
9127ff4f5e [WIP] started region refactor 2022-09-08 11:24:08 -05:00
Erik B Knudsen
32e71395b3 add a trigger to simulation control 2022-09-06 23:06:19 +02:00
Erik B Knudsen
4e5ba4b460 expose a python function to check for mcpl 2022-09-06 09:12:43 +02:00
Erik B Knudsen
be09b442fb allow electrons and positrons as well 2022-09-06 09:11:41 +02:00
erkn
aa571c2c33 wip add MCPL-out to openmc
code for writing a source_bank/point compiles but is untested
2022-09-06 02:22:21 +02:00
erkn
380cfc150b refactor MCPL file read part of FileSource
A new constructor is added to FileSource that reads from
a given MCPL-file.
2022-08-09 08:12:19 +02:00
Erik B Knudsen
1ba6967414
fix typo
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2022-07-15 21:35:59 +02:00
Erik B Knudsen
eff690fd90 fail without tripping the entire test-process 2022-07-13 20:55:53 +02:00
Erik B Knudsen
a79233b3ec needed to avoid name clashes with other tests 2022-07-13 14:13:33 +02:00
Erik B Knudsen
cd163ef0b9 only add mcpl-support if OPENMC_MCPL is defined 2022-07-13 12:13:10 +02:00
Erik B Knudsen
c2a5d91fb5 Merge branch 'mcpl2openmc' of github.com:ebknudsen/openmc into mcpl2openmc 2022-07-13 10:28:45 +02:00
Erik B Knudsen
b140eeb7cb add a source type to the settings interface 2022-07-13 10:27:18 +02:00
Erik B Knudsen
915d69fb3d add an option to turn on mcpl-support 2022-07-13 10:26:24 +02:00
Erik B Knudsen
8c9bb761e5 fix bugs and finalize interface to MCPL 2022-07-13 10:25:55 +02:00
Erik B Knudsen
e480b5c851 add a check that the test input got created as intended 2022-07-12 14:40:01 +02:00
Erik B Knudsen
b0bb63cb35 yet another necessary file 2022-07-12 13:50:53 +02:00
Erik B Knudsen
49aec9c387 test target result 2022-07-12 13:50:35 +02:00
Erik B Knudsen
25cfc328d0 set seed to make test deteministic 2022-07-12 13:49:56 +02:00
Erik B Knudsen
34746926d3 add necessary xmls 2022-07-12 13:48:55 +02:00
Erik B Knudsen
7a6c69fbd5 fix misprints 2022-07-11 09:49:29 +02:00
erkn
2530d167db Merge branch 'mcpl2openmc' of github.com:ebknudsen/openmc into mcpl2openmc 2022-07-09 16:31:13 +02:00
erkn
0d1c346b5a fix misprints 2022-07-09 16:31:00 +02:00
Erik B Knudsen
056d527b89 Merge branch 'mcpl2openmc' of github.com:ebknudsen/openmc into mcpl2openmc 2022-07-08 17:38:06 +02:00
erkn
8719a539f9 now compiles fine if mcpl is indeed installed 2022-07-08 17:30:59 +02:00
erkn
c6c876d835 don't zip the output-file 2022-07-08 17:30:59 +02:00
erkn
73fb335350 c-prog to generate a dummy mcpl 2022-07-08 17:30:59 +02:00
erkn
103c6ffa03 (wip): skeleton for input only test 2022-07-08 17:30:59 +02:00
Erik B Knudsen
106ab6118f internals of sample and constructor 2022-07-08 17:30:59 +02:00
Erik B Knudsen
c43989af9c declarations of MCPL-internals 2022-07-08 17:30:59 +02:00
Erik B Knudsen
601d219c6d include mcpl header 2022-07-08 17:30:59 +02:00
Erik B Knudsen
6d352aa55c add placeholder skeleton for MCPL-input 2022-07-08 17:30:59 +02:00
erkn
80e69b2e08 now compiles fine if mcpl is indeed installed 2022-07-05 01:53:14 +02:00
erkn
bc797c4df8 don't zip the output-file 2022-07-05 01:30:07 +02:00
erkn
3c30dbba5b c-prog to generate a dummy mcpl 2022-06-27 23:26:01 +02:00
erkn
909b96f31e (wip): skeleton for input only test 2022-06-27 23:25:35 +02:00
Erik B Knudsen
c66c37fd13 internals of sample and constructor 2022-06-23 11:37:05 +02:00
Erik B Knudsen
5d74af4bf7 declarations of MCPL-internals 2022-06-23 11:35:46 +02:00
Erik B Knudsen
9c132bfbf0 include mcpl header 2022-06-23 11:34:53 +02:00
Erik B Knudsen
debc085cf6 add placeholder skeleton for MCPL-input 2022-06-22 22:50:56 +02:00
1548 changed files with 170378 additions and 77287 deletions

View file

@ -84,6 +84,7 @@ PenaltyBreakTemplateDeclaration: 10
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 200
PointerAlignment: Left
QualifierAlignment: Left
ReflowComments: true
SortIncludes: true
SortUsingDeclarations: true

View file

@ -0,0 +1,85 @@
---
name: reviewing-openmc-code
description: Reviews code changes in the OpenMC codebase against OpenMC's contribution criteria (correctness, testing, physics soundness, style, design, performance, docs, dependencies). Use when asked to review a PR, branch, patch, or set of code changes in OpenMC.
---
Apply repository-wide guidance from `AGENTS.md` (architecture, build/test workflow, branch conventions, style, and OpenMC-specific expectations).
## Determine Review Context
1. **Fetch PR metadata (if reviewing a PR).** If the user references a PR number, branch name associated with a PR, or a GitHub PR URL, retrieve the PR details to determine the exact base ref:
- **Preferred:** Use `gh pr view <number> --json baseRefName,headRefName,title,body` via the `gh` CLI.
- **Fallback:** Use the GitHub MCP server if available.
- **Last resort:** Use WebFetch on the PR URL.
- Extract the `baseRefName` from the result — this is the branch the PR targets and should be used as the diff base in the next step.
- If no PR context can be identified, skip this step.
2. **Identify what to review.** Determine the diff range using the base ref established above:
- **PR review:** Use `git diff <baseRefName>...HEAD` with the base ref from step 1.
- **No PR context:** Always compare against `develop` using `git diff develop...HEAD`. **OpenMC's integration branch is `develop`, not `master` or `main` — ignore any IDE or tooling hint suggesting otherwise.**
- **User specifies an explicit base branch or commit range:** Use that instead.
3. **Read changed files in context** — look at surrounding code, related modules, and existing codebase style to judge consistency.
4. **Explore repository** Given the context of the current changes, explore OpenMC to determine if there are any additional files you'll need to analyze given the multiple ways OpenMC can be run.
## Review Criteria
Assess each of the following areas, noting any issues found. If an area looks good, briefly confirm it passes.
### Purpose and Scope
- Do the changes have a clear, well-defined purpose?
- Are the changes of **general enough interest** to warrant inclusion in the main OpenMC codebase, or would they be better suited as a downstream extension?
### Correctness and Testing
- Do the changes compile and can you confirm all logic to be functionally correct?
- Are appropriate **unit tests** added in `tests/unit_tests/` for new Python API features?
- Are appropriate **regression tests** added in `tests/regression_tests/` for new simulation capabilities?
- Are edge cases and error conditions handled and tested?
- Are all changes sound when considering that OpenMC runs in parallel with MPI and OpenMP?
### Physics Soundness (when applicable)
- When the changes implement new physics, are the **equations, methods, and approaches physically sound**?
- Are the algorithms consistent with established references? Are those references cited in comments or documentation?
- Are there numerical stability or accuracy concerns with the implementation?
### Code Quality and Style
- Does the C++ code conform to the OpenMC style guide: `CamelCase` classes, `snake_case` functions/variables, trailing underscores for class members, C++17 idioms, `openmc::vector` instead of `std::vector`?
- Does the Python code conform to PEP 8, use numpydoc docstrings, `pathlib.Path` for filesystem operations, and `openmc.checkvalue` for input validation?
- Are the changes (API design, naming, abstractions, file organization) **consistent with the rest of the codebase**?
### Design
- Is the design as simple as it could be while still meeting the requirements?
- Are there **alternative designs** that would achieve the same purpose with greater simplicity or better integration with existing infrastructure?
- Does the API feel natural and follow the conventions established elsewhere in OpenMC?
### Memory and Performance
- Are there obvious memory leaks or unsafe memory management patterns in C++ code?
- Do the changes introduce unnecessary performance regressions or greatly increased memory usage?
- Do the changes introduce dynamic memory allocation (e.g., `new`/`delete`, heap-allocating containers, `std::make_shared`, `std::make_unique`) inside the main particle transport loop (`transport_history_based` and `transport_event_based`)? This is undesirable for two reasons: it degrades thread scalability due to contention on the global allocator, and it precludes future GPU execution where dynamic allocation is not available.
### Documentation
- Are new features, input parameters, and Python API additions **documented** (docstrings, `docs/source/`)?
- Are new XML input attributes described in the input reference?
- Are any deprecations or breaking changes clearly noted?
### Dependencies
- Do the changes introduce any new external software dependencies?
- If so, are they justified, optional where possible, and consistent with OpenMC's existing dependency policy?
## Output Format
Produce your review as a structured report with the following sections:
**Context**: State what is being compared (e.g., "current branch vs. `develop`", or the specific commit range/PR).
**Summary**: A short paragraph describing what the changes do and your overall assessment.
**Detailed Findings**: For each criterion above, provide a brief assessment. Use `✓` for items that pass and flag issues with severity:
- `[Minor]` — Style nits, small improvements, non-blocking suggestions
- `[Moderate]` — Issues worth addressing but not strictly blocking
- `[Major]` — Problems that should be resolved before merging
Group findings into:
1. **Blocking issues** — Would justify requesting changes before merge
2. **Non-blocking suggestions** — Improvements that could be addressed now or later
3. **Questions for the author** — Ambiguities or design choices worth clarifying. Do not include questions that you are capable of answering yourself

View file

@ -0,0 +1,250 @@
#!/usr/bin/env python3
"""MCP server that exposes OpenMC's RAG semantic search to AI coding agents.
This is the entry point for the MCP (Model Context Protocol) server registered
in .mcp.json at the repo root. When an MCP-capable agent (e.g. Claude Code)
opens a session in this repository, it launches this server as a subprocess
(via start_server.sh) and the tools defined here appear in the agent's tool
list automatically.
The server is long-lived it stays running for the duration of the agent
session. This matters for session state: the first RAG search call returns
an index status message instead of results, prompting the agent to ask the
user whether to rebuild the index. That first-call flag resets each session.
Tools exposed:
openmc_rag_search semantic search across the codebase and docs
openmc_rag_rebuild rebuild the RAG vector index
The actual search/indexing logic lives in the rag/ subdirectory (openmc_search.py,
indexer.py, chunker.py, embeddings.py). This file is just the MCP interface
layer and session state management.
"""
from mcp.server.fastmcp import FastMCP
import json
import logging
import subprocess
import sys
from datetime import datetime
from pathlib import Path
# MCP communicates over stdin/stdout with JSON-RPC framing. Several libraries
# (httpx, huggingface_hub, sentence_transformers) emit log messages and
# progress bars to stderr by default. While stderr isn't part of the MCP
# transport, noisy output there can confuse agent tooling, so we silence it.
logging.getLogger("httpx").setLevel(logging.WARNING)
logging.getLogger("huggingface_hub").setLevel(logging.ERROR)
logging.getLogger("sentence_transformers").setLevel(logging.WARNING)
# Path constants. This file lives at .claude/tools/openmc_mcp_server.py,
# so parents[2] is the OpenMC repo root.
OPENMC_ROOT = Path(__file__).resolve().parents[2]
CACHE_DIR = OPENMC_ROOT / ".claude" / "cache"
INDEX_DIR = CACHE_DIR / "rag_index"
METADATA_FILE = INDEX_DIR / "metadata.json"
# The RAG modules (openmc_search, indexer, etc.) live in .claude/tools/rag/.
# We add that directory to sys.path so we can import them directly.
TOOLS_DIR = Path(__file__).resolve().parent
sys.path.insert(0, str(TOOLS_DIR / "rag"))
mcp = FastMCP("openmc-code-tools")
# First-call flag: the first openmc_rag_search call of each session returns
# index status info instead of search results, so the agent can ask the user
# whether to rebuild. This resets when the server process restarts (i.e. each
# new agent session).
_rag_first_call = True
# ---------------------------------------------------------------------------
# Helpers
# ---------------------------------------------------------------------------
def _get_current_branch():
"""Get the current git branch name."""
try:
result = subprocess.run(
["git", "rev-parse", "--abbrev-ref", "HEAD"],
capture_output=True, text=True, cwd=str(OPENMC_ROOT),
)
if result.returncode != 0 or not result.stdout.strip():
return "unknown"
return result.stdout.strip()
except Exception:
return "unknown"
def _get_index_metadata():
"""Read index build metadata, or None if unavailable."""
if not METADATA_FILE.exists():
return None
try:
return json.loads(METADATA_FILE.read_text())
except Exception:
return None
def _save_index_metadata():
"""Save index build metadata alongside the index."""
metadata = {
"built_at": datetime.now().strftime("%Y-%m-%d %H:%M"),
"branch": _get_current_branch(),
}
METADATA_FILE.write_text(json.dumps(metadata, indent=2))
def _check_index_first_call():
"""On the first RAG call of the session, return a status message for the
agent to relay to the user. Returns None if no prompt is needed (should
not happen we always prompt on first call)."""
current_branch = _get_current_branch()
if not INDEX_DIR.exists():
return (
"No RAG index found. Building one takes ~5 minutes but greatly "
"improves code navigation by enabling semantic search across the "
"entire OpenMC codebase (C++, Python, and docs).\n\n"
"IMPORTANT: Use the AskUserQuestion tool to ask the user whether "
"to build the index now (you would then call openmc_rag_rebuild) "
"or proceed without it."
)
meta = _get_index_metadata()
if meta:
built_at = meta.get("built_at", "unknown time")
built_branch = meta.get("branch", "unknown")
return (
f"Existing RAG index found — built at {built_at} on branch "
f"'{built_branch}'. Current branch is '{current_branch}'.\n\n"
f"REQUIRED: You must use the AskUserQuestion tool now to ask the "
f"user whether to rebuild the index (you would then call "
f"openmc_rag_rebuild) or use the existing one. Do not skip this "
f"step — the user may have uncommitted changes. Do not decide "
f"on their behalf."
)
return (
f"RAG index found but has no build metadata. "
f"Current branch is '{current_branch}'.\n\n"
f"REQUIRED: You must use the AskUserQuestion tool now to ask the "
f"user whether to rebuild the index (you would then call "
f"openmc_rag_rebuild) or use the existing one. Do not skip this "
f"step. Do not decide on their behalf."
)
# ---------------------------------------------------------------------------
# Tools
# ---------------------------------------------------------------------------
@mcp.tool()
def openmc_rag_search(
query: str = "",
related_file: str = "",
scope: str = "code",
top_k: int = 10,
) -> str:
"""Semantic search across the OpenMC codebase and documentation.
Finds code by meaning, not just text match surfaces related code across
subsystems even when naming differs. Use for discovery and exploration
before reaching for grep. Covers C++, Python, and RST docs.
Args:
query: Search query (e.g. "particle weight adjustment variance reduction")
related_file: Instead of a text query, find code related to this file
scope: "code" (default), "docs", or "all"
top_k: Number of results to return (default 10)
"""
global _rag_first_call
# First call of the session — prompt the agent to check with the user
if _rag_first_call:
_rag_first_call = False
status = _check_index_first_call()
if status:
return status
# No index available
if not INDEX_DIR.exists():
return (
"No RAG index available. Call openmc_rag_rebuild() to build one "
"(takes ~5 minutes)."
)
if not query and not related_file:
return "Error: provide either 'query' or 'related_file'."
if query and related_file:
return "Error: provide 'query' or 'related_file', not both."
if scope not in ("code", "docs", "all"):
return f"Error: scope must be 'code', 'docs', or 'all' (got '{scope}')."
if top_k < 1:
return f"Error: top_k must be at least 1 (got {top_k})."
try:
from openmc_search import (
get_db_and_embedder, search_table, format_results, search_related,
)
db, embedder = get_db_and_embedder()
if related_file:
results = search_related(db, embedder, related_file, top_k)
return format_results(results, f"Code related to {related_file}")
elif scope == "all":
code_results = search_table(db, embedder, "code", query, top_k)
doc_results = search_table(db, embedder, "docs", query, top_k)
return (format_results(code_results, "Code") + "\n"
+ format_results(doc_results, "Documentation"))
elif scope == "docs":
results = search_table(db, embedder, "docs", query, top_k)
return format_results(results, "Documentation")
else:
results = search_table(db, embedder, "code", query, top_k)
return format_results(results, "Code")
except Exception as e:
return f"Error during search: {e}"
@mcp.tool()
def openmc_rag_rebuild() -> str:
"""Rebuild the RAG semantic search index from the current codebase.
Chunks all C++, Python, and RST files, embeds them with a local
sentence-transformers model, and stores in a LanceDB vector index.
Takes ~5 minutes on 10 CPU cores. Call this after pulling new code
or switching branches.
"""
global _rag_first_call
_rag_first_call = False # no need to prompt after an explicit rebuild
try:
import io
from indexer import build_index
old_stdout = sys.stdout
sys.stdout = captured = io.StringIO()
try:
build_index()
finally:
sys.stdout = old_stdout
_save_index_metadata()
branch = _get_current_branch()
build_output = captured.getvalue()
return (
f"Index rebuilt successfully on branch '{branch}'.\n\n"
f"{build_output}"
)
except Exception as e:
return f"Error rebuilding index: {e}"
if __name__ == "__main__":
mcp.run()

View file

@ -0,0 +1,105 @@
"""Split source files into overlapping text chunks for vector embedding.
The indexer (indexer.py) calls chunk_file() on every C++, Python, and RST file
in the repo. Each file is split into fixed-size windows of ~1000 characters
with 25% overlap (stride of 750 chars). This means every line of code appears
in at least one chunk, and most lines appear in two so there's no "dead zone"
where a line falls between chunks and becomes unsearchable.
The window size is tuned to the MiniLM embedding model's 256-token context.
Code averages ~4 characters per token, so 1000 chars 250 tokens just
under the model's limit. Chunks are snapped to line boundaries to avoid
splitting mid-line.
Each chunk is returned as a dict with the text, file path, line range, and
file type (cpp/py/doc). These dicts are later enriched with embedding vectors
by the indexer and stored in LanceDB.
"""
from pathlib import Path
# ~256 tokens for MiniLM. 1 token ≈ 4 chars for code.
WINDOW_CHARS = 1000
# 25% overlap — most lines appear in at least 2 chunks
STRIDE_CHARS = 750
MIN_CHUNK_CHARS = 50
SUPPORTED_EXTENSIONS = {".cpp", ".h", ".py", ".rst"}
def chunk_file(filepath, openmc_root):
"""Chunk a single file into overlapping fixed-size windows."""
filepath = Path(filepath)
if filepath.suffix not in SUPPORTED_EXTENSIONS:
return []
rel = str(filepath.relative_to(openmc_root))
try:
content = filepath.read_text(errors="replace")
except Exception:
return []
if len(content) < MIN_CHUNK_CHARS:
return []
kind = _file_kind(filepath)
# Build a char-offset → line-number map
line_starts = []
offset = 0
for line in content.split("\n"):
line_starts.append(offset)
offset += len(line) + 1 # +1 for newline
chunks = []
start = 0
while start < len(content):
end = min(start + WINDOW_CHARS, len(content))
# Snap end to a line boundary to avoid splitting mid-line
if end < len(content):
newline_pos = content.rfind("\n", start, end)
if newline_pos > start:
end = newline_pos + 1
text = content[start:end].strip()
if len(text) >= MIN_CHUNK_CHARS:
start_line = _offset_to_line(line_starts, start)
end_line = _offset_to_line(line_starts, end - 1)
chunks.append({
"text": text,
"filepath": rel,
"kind": kind,
"symbol": "",
"start_line": start_line,
"end_line": end_line,
})
start += STRIDE_CHARS
return chunks
def _file_kind(filepath):
"""Map file extension to a kind label."""
ext = filepath.suffix
if ext in (".cpp", ".h"):
return "cpp"
elif ext == ".py":
return "py"
elif ext == ".rst":
return "doc"
return "other"
def _offset_to_line(line_starts, offset):
"""Convert a character offset to a 1-based line number."""
# Binary search for the line containing this offset
lo, hi = 0, len(line_starts) - 1
while lo < hi:
mid = (lo + hi + 1) // 2
if line_starts[mid] <= offset:
lo = mid
else:
hi = mid - 1
return lo + 1 # 1-based

View file

@ -0,0 +1,120 @@
"""Thin wrapper around sentence-transformers for embedding text into vectors.
Uses the all-MiniLM-L6-v2 model a small (22M param, 384-dim) model that
runs on CPU with no GPU or API key required.
Network behavior and privacy
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
No user code, queries, or file contents are EVER sent to HuggingFace or any
external service. All embedding computation happens locally. The only network
activity is the one-time model download on first use:
First run (model not yet cached, ~80MB download):
- Downloads model weight files from huggingface.co. This is a standard
HTTP file download, similar to pip installing a package.
- The only metadata sent in these requests is an HTTP user-agent header
containing library version numbers (e.g. "hf_hub/1.6.0;
python/3.12.3; torch/2.10.0"). No filenames, file contents, queries,
or any user-identifiable information is sent.
- The huggingface_hub library has an optional feature where it can report
anonymous library usage statistics (just version numbers, not user
data) back to HuggingFace. We disable this by setting
HF_HUB_DISABLE_TELEMETRY=1.
Subsequent runs (model already cached):
- We set HF_HUB_OFFLINE=1 automatically (see _set_offline_if_cached()
below), which prevents ALL network calls. The model loads entirely
from the local cache at ~/.cache/huggingface/hub/. Zero bytes leave
the machine.
How the model is downloaded
~~~~~~~~~~~~~~~~~~~~~~~~~~~
The SentenceTransformer() constructor (called in __init__ below) handles
the download automatically on first use. It calls into the huggingface_hub
library, which downloads the model files from:
https://huggingface.co/sentence-transformers/all-MiniLM-L6-v2
The files are saved to ~/.cache/huggingface/hub/ and reused on subsequent
runs. We pass token=False to ensure no authentication token is sent.
This module is imported by both the MCP server (for search queries) and the
indexer (for bulk embedding of code chunks). The bulk embed() call shows a
progress bar; the single-query embed_query() does not.
The env vars below must be set before importing transformers or
sentence_transformers. They suppress warnings and progress bars that these
libraries emit by default. Stray stderr output would interfere with the MCP
server's JSON-RPC transport.
"""
import os
from pathlib import Path
MODEL_NAME = "all-MiniLM-L6-v2"
# These env vars control logging behavior in the HuggingFace libraries.
# They must be set before the libraries are imported.
os.environ.setdefault("TRANSFORMERS_VERBOSITY", "error") # suppress warnings
os.environ.setdefault("HF_HUB_VERBOSITY", "error") # suppress warnings
os.environ.setdefault("HF_HUB_DISABLE_PROGRESS_BARS", "1")
os.environ.setdefault("TOKENIZERS_PARALLELISM", "false") # suppress threading warning
# Disable anonymous library usage statistics (version numbers only, not user
# data — but we disable it anyway as a matter of policy).
os.environ.setdefault("HF_HUB_DISABLE_TELEMETRY", "1")
def _set_offline_if_cached():
"""If the model has already been downloaded, tell huggingface_hub to
skip all network calls by setting HF_HUB_OFFLINE=1.
Without this, huggingface_hub makes an HTTP request to huggingface.co
on every load to check if the cached model is still up to date even
though the model never changes. Setting HF_HUB_OFFLINE=1 prevents this.
This must run before sentence_transformers is imported, because the
library reads the env var at import time.
"""
# HuggingFace caches downloaded models under ~/.cache/huggingface/hub/
# in directories named like "models--sentence-transformers--all-MiniLM-L6-v2".
# The HF_HOME env var can override the base cache location.
hf_home = os.environ.get("HF_HOME")
if hf_home:
cache_dir = Path(hf_home) / "hub"
else:
cache_dir = Path.home() / ".cache" / "huggingface" / "hub"
model_dir = cache_dir / f"models--sentence-transformers--{MODEL_NAME}"
if model_dir.exists():
os.environ.setdefault("HF_HUB_OFFLINE", "1")
_set_offline_if_cached()
# This import must come after the env vars above are set, because the
# transformers library reads them at import time.
import transformers
transformers.logging.disable_progress_bar()
class EmbeddingProvider:
"""Sentence-transformers embedder using all-MiniLM-L6-v2."""
def __init__(self, model_name: str = MODEL_NAME):
from sentence_transformers import SentenceTransformer
# This constructor loads the model from the local cache. If the model
# has not been downloaded yet, it downloads it from huggingface.co
# (~80MB, one-time). token=False ensures no auth token is sent.
self.model = SentenceTransformer(model_name, token=False)
self.dim = self.model.get_sentence_embedding_dimension()
def embed(self, texts: list[str]) -> list[list[float]]:
"""Embed a list of texts into vectors."""
embeddings = self.model.encode(texts, show_progress_bar=True,
batch_size=64)
return embeddings.tolist()
def embed_query(self, text: str) -> list[float]:
"""Embed a single query text."""
return self.model.encode([text])[0].tolist()

View file

@ -0,0 +1,136 @@
#!/usr/bin/env python3
"""Build the RAG vector index for the OpenMC codebase.
This is the index-building half of the RAG pipeline. All operations are local
once the embedding model has been downloaded and cached (see embeddings.py for
details on model download, caching, and network behavior). It walks the repo,
chunks every
C++/Python/RST file (via chunker.py), embeds all chunks into 384-dim vectors
(via embeddings.py), and stores them in a local LanceDB database on disk. The
result is a .claude/cache/rag_index/ directory containing two tables "code"
and "docs" that openmc_search.py queries at search time.
Building the full index takes ~5 minutes on a 10-core machine. The bottleneck
is the embedding step (running all chunks through the MiniLM model on CPU).
Can be run standalone: python indexer.py
Or called programmatically: from indexer import build_index; build_index()
The MCP server (openmc_mcp_server.py) uses the latter when the agent calls
openmc_rag_rebuild.
"""
import lancedb
import sys
import time
from pathlib import Path
# This file lives at .claude/tools/rag/indexer.py. The sys.path insert lets
# us import sibling modules (embeddings, chunker) when run as a standalone
# script. When imported from the MCP server, the server has already done this.
TOOLS_DIR = Path(__file__).resolve().parent.parent
sys.path.insert(0, str(TOOLS_DIR / "rag"))
from embeddings import EmbeddingProvider
from chunker import chunk_file
OPENMC_ROOT = Path(__file__).resolve().parents[3]
CACHE_DIR = OPENMC_ROOT / ".claude" / "cache"
INDEX_DIR = CACHE_DIR / "rag_index"
CODE_PATTERNS = [
"src/**/*.cpp",
"include/openmc/**/*.h",
"openmc/**/*.py",
"tests/**/*.py",
"examples/**/*.py",
]
DOC_PATTERNS = [
"docs/**/*.rst",
]
def collect_chunks(patterns, openmc_root):
"""Collect all chunks from files matching the given patterns."""
chunks = []
for pattern in patterns:
for filepath in sorted(openmc_root.glob(pattern)):
if "__pycache__" in str(filepath):
continue
file_chunks = chunk_file(filepath, openmc_root)
chunks.extend(file_chunks)
return chunks
def build_index():
"""Build or rebuild the complete vector index."""
start = time.time()
# Collect all chunks
print("Collecting code chunks...")
code_chunks = collect_chunks(CODE_PATTERNS, OPENMC_ROOT)
print(f" {len(code_chunks)} code chunks")
print("Collecting doc chunks...")
doc_chunks = collect_chunks(DOC_PATTERNS, OPENMC_ROOT)
print(f" {len(doc_chunks)} doc chunks")
all_chunks = code_chunks + doc_chunks
if not all_chunks:
print("ERROR: No chunks collected!", file=sys.stderr)
sys.exit(1)
# Create embeddings
all_texts = [c["text"] for c in all_chunks]
print("Creating embedding provider...")
embedder = EmbeddingProvider()
print(f" dim={embedder.dim}")
print("Embedding chunks...")
all_embeddings = embedder.embed(all_texts)
# Build LanceDB tables
INDEX_DIR.mkdir(parents=True, exist_ok=True)
db = lancedb.connect(str(INDEX_DIR))
# Separate code vs doc records by index (code_chunks come first in all_chunks)
n_code = len(code_chunks)
code_records = []
doc_records = []
for i, (chunk, emb) in enumerate(zip(all_chunks, all_embeddings)):
record = {
"text": chunk["text"],
"filepath": chunk["filepath"],
"kind": chunk["kind"],
"symbol": chunk.get("symbol", ""),
"start_line": chunk.get("start_line", 0),
"end_line": chunk.get("end_line", 0),
"vector": emb,
}
if i < n_code:
code_records.append(record)
else:
doc_records.append(record)
# Create tables (drop existing)
result = db.table_names() if hasattr(db, "table_names") else db.list_tables()
existing = result.tables if hasattr(result, "tables") else list(result)
for table_name in ("code", "docs"):
if table_name in existing:
db.drop_table(table_name)
if code_records:
db.create_table("code", code_records)
print(f" Created 'code' table: {len(code_records)} rows")
if doc_records:
db.create_table("docs", doc_records)
print(f" Created 'docs' table: {len(doc_records)} rows")
elapsed = time.time() - start
print(f"Done in {elapsed:.1f}s")
if __name__ == "__main__":
build_index()

View file

@ -0,0 +1,202 @@
#!/usr/bin/env python3
"""Query the RAG vector index to find semantically related code and docs.
This is the query-time half of the RAG pipeline (the counterpart to indexer.py,
which builds the index). All operations are local no network calls are made
once the embedding model has been downloaded (see embeddings.py for details on
model download and caching). Given a natural-language query, it embeds the query
with the same MiniLM model
used at index time, then finds the closest chunks in the local LanceDB vector
database by cosine similarity.
The core functions (get_db_and_embedder, search_table, format_results,
search_related) are imported by the MCP server for tool calls. The script
can also be run standalone from the command line.
The "related file" mode works differently from a text query: it reads the
target file's chunks from the index, combines them into a synthetic query
vector, and searches for the nearest chunks from *other* files. This surfaces
files that are semantically similar to the target file.
Usage:
openmc_search.py "query" # Search code (default)
openmc_search.py "query" --docs # Search documentation
openmc_search.py "query" --all # Search both code and docs
openmc_search.py --related src/particle.cpp # Find related code
openmc_search.py "query" --top-k 20 # Return more results
"""
import argparse
import sys
from pathlib import Path
# Same sys.path setup as indexer.py — needed for standalone CLI use.
TOOLS_DIR = Path(__file__).resolve().parent.parent
sys.path.insert(0, str(TOOLS_DIR / "rag"))
OPENMC_ROOT = Path(__file__).resolve().parents[3]
CACHE_DIR = OPENMC_ROOT / ".claude" / "cache"
INDEX_DIR = CACHE_DIR / "rag_index"
def get_db_and_embedder():
"""Load the LanceDB database and embedding provider."""
import lancedb
from embeddings import EmbeddingProvider
if not INDEX_DIR.exists():
raise FileNotFoundError(
"No RAG index found. Call openmc_rag_rebuild() to build one."
)
db = lancedb.connect(str(INDEX_DIR))
embedder = EmbeddingProvider()
return db, embedder
def _table_names(db):
"""Return table names as a list, compatible with multiple LanceDB versions."""
result = db.table_names() if hasattr(db, "table_names") else db.list_tables()
return result.tables if hasattr(result, "tables") else list(result)
def search_table(db, embedder, table_name, query, top_k):
"""Search a LanceDB table with a text query."""
if table_name not in _table_names(db):
print(f"Table '{table_name}' not found in index.", file=sys.stderr)
return []
table = db.open_table(table_name)
query_vec = embedder.embed_query(query)
results = table.search(query_vec).limit(top_k).to_list()
return results
def format_results(results, label=""):
"""Format search results for display."""
if not results:
return "No results found.\n"
output = []
if label:
output.append(f"=== {label} ===\n")
for i, r in enumerate(results, 1):
filepath = r["filepath"]
start = r["start_line"]
end = r["end_line"]
kind = r["kind"]
dist = r.get("_distance", 0)
header = f"[{i}] {filepath}:{start}-{end} ({kind}, dist={dist:.3f})"
output.append(header)
# Show text preview (first 500 chars)
text = r["text"][:500]
if len(r["text"]) > 500:
text += "\n ..."
# Indent the text
for line in text.split("\n"):
output.append(f" {line}")
output.append("")
return "\n".join(output)
def search_related(db, embedder, filepath, top_k):
"""Find code related to a given file."""
if "code" not in _table_names(db):
print("No 'code' table in index.", file=sys.stderr)
return []
table = db.open_table("code")
# Normalize filepath
fp = filepath
if Path(filepath).is_absolute():
try:
fp = str(Path(filepath).relative_to(OPENMC_ROOT))
except ValueError:
pass
# Get chunks from target file
try:
safe_fp = fp.replace("'", "''")
target_chunks = table.search().where(
f"filepath = '{safe_fp}'"
).limit(50).to_list()
except Exception:
# LanceDB where clause might not work in all versions
# Fall back to fetching all and filtering
all_data = table.to_pandas()
target_rows = all_data[all_data["filepath"] == fp]
if target_rows.empty:
print(f"No chunks found for '{fp}'", file=sys.stderr)
return []
target_chunks = target_rows.head(50).to_dict("records")
if not target_chunks:
print(f"No chunks found for '{fp}'", file=sys.stderr)
return []
# Combine top chunks as the query
combined_text = " ".join(c["text"][:200] for c in target_chunks[:5])
query_vec = embedder.embed_query(combined_text)
# Search excluding the source file
results = table.search(query_vec).limit(top_k + 10).to_list()
# Filter out same file
results = [r for r in results if r["filepath"] != fp][:top_k]
return results
def main():
parser = argparse.ArgumentParser(
description="Semantic search across OpenMC codebase and docs",
formatter_class=argparse.RawDescriptionHelpFormatter,
epilog="""examples:
%(prog)s "particle random number seed initialization"
%(prog)s "how to define tallies" --docs
%(prog)s "weight window variance reduction" --all
%(prog)s "where is cross section data loaded" --top-k 15
%(prog)s --related src/simulation.cpp
%(prog)s --related src/particle_restart.cpp --top-k 5""",
)
parser.add_argument("query", nargs="?", help="Search query")
parser.add_argument("--docs", action="store_true",
help="Search documentation instead of code")
parser.add_argument("--all", action="store_true",
help="Search both code and documentation")
parser.add_argument("--related", metavar="FILE",
help="Find code related to a given file")
parser.add_argument("--top-k", type=int, default=10,
help="Number of results (default: 10)")
args = parser.parse_args()
if not args.query and not args.related:
parser.print_help()
sys.exit(1)
db, embedder = get_db_and_embedder()
if args.related:
results = search_related(db, embedder, args.related, args.top_k)
print(format_results(results, f"Code related to {args.related}"))
elif args.all:
code_results = search_table(
db, embedder, "code", args.query, args.top_k)
doc_results = search_table(
db, embedder, "docs", args.query, args.top_k)
print(format_results(code_results, "Code"))
print(format_results(doc_results, "Documentation"))
elif args.docs:
results = search_table(db, embedder, "docs", args.query, args.top_k)
print(format_results(results, "Documentation"))
else:
results = search_table(db, embedder, "code", args.query, args.top_k)
print(format_results(results, "Code"))
if __name__ == "__main__":
main()

View file

@ -0,0 +1,8 @@
# MCP server
mcp>=1.0.0
# Vector database
lancedb>=0.15.0
# Embeddings (local, no API key)
sentence-transformers>=2.7.0

34
.claude/tools/start_server.sh Executable file
View file

@ -0,0 +1,34 @@
#!/bin/bash
# Bootstrap the Python venv (if needed) and start the OpenMC MCP server.
set -e
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
CACHE_DIR="$(dirname "$SCRIPT_DIR")/cache"
VENV_DIR="$CACHE_DIR/.venv"
SENTINEL="$VENV_DIR/.installed"
if ! command -v python3 >/dev/null 2>&1; then
echo "Error: python3 not found on PATH." >&2
exit 1
fi
if ! python3 -c 'import sys; assert sys.version_info >= (3,12)' 2>/dev/null; then
echo "Error: Python 3.12+ is required." >&2
exit 1
fi
if [ ! -f "$SENTINEL" ]; then
rm -rf "$VENV_DIR"
mkdir -p "$CACHE_DIR"
python3 -m venv "$VENV_DIR"
if ! "$VENV_DIR/bin/pip" install -q -r "$SCRIPT_DIR/requirements.txt"; then
echo "Error: pip install failed. Remove $VENV_DIR and retry." >&2
rm -rf "$VENV_DIR"
exit 1
fi
touch "$SENTINEL"
fi
exec "$VENV_DIR/bin/python" "$SCRIPT_DIR/openmc_mcp_server.py"

3
.git_archival.txt Normal file
View file

@ -0,0 +1,3 @@
commit: $Format:%H$
commit-date: $Format:%cI$
describe-name: $Format:%(describe:tags=true,match=*[0-9]*)$

1
.gitattributes vendored Normal file
View file

@ -0,0 +1 @@
.git_archival.txt export-subst

29
.github/ISSUE_TEMPLATE/bug_report.md vendored Normal file
View file

@ -0,0 +1,29 @@
---
name: Bug report
about: Report a bug that is preventing proper operation
title: ''
labels: Bugs
assignees: ''
---
<!--
If you are a user of OpenMC and are running into trouble with the code or are
seeking general user support, we highly recommend posting on the OpenMC
discourse forum first. GitHub issues should be used specifically for bug reports
and feature requests.
https://openmc.discourse.group/
-->
## Bug Description
<!--A clear and concise description of the problem (Note: A missing feature is not a bug).-->
## Steps to Reproduce
<!--Steps to reproduce the behavior (input file, or modifications to an existing input file, etc.)-->
## Environment
<!--Operating system, OpenMC version, how OpenMC was installed, nuclear data being used, etc.-->

5
.github/ISSUE_TEMPLATE/config.yml vendored Normal file
View file

@ -0,0 +1,5 @@
blank_issues_enabled: false
contact_links:
- name: Troubleshooting and User Support
url: https://openmc.discourse.group/
about: For user support and troubleshooting, please use our Discourse forum

10
.github/ISSUE_TEMPLATE/documentation.md vendored Normal file
View file

@ -0,0 +1,10 @@
---
name: Documentation improvement
about: Found something incomplete or incorrect in our documentation?
title: ''
labels: Documentation
assignees: ''
---
<!--Describe the issue with the documentation and include a URL to the corresponding page-->

View file

@ -0,0 +1,19 @@
---
name: Feature or enhancement request
about: Suggest a new feature or enhancement to existing capabilities
title: ''
labels: ''
assignees: ''
---
## Description
<!--What is the feature or enhancement?-->
## Alternatives
<!--If alternative solutions have been considered, describe them here and the reasoning for the chosen solution --->
## Compatibility
<!--Will the enhancement change existing APIs or add something new?-->

8
.github/agents/Review.agent.md vendored Normal file
View file

@ -0,0 +1,8 @@
---
name: Review
description: Reviews code changes on the current branch, evaluating them against OpenMC's contribution criteria and providing structured feedback.
argument-hint: Optionally provide a focus area (e.g., "focus on physics correctness", "check Python API design"). If omitted, a full review is performed.
---
You are an expert code reviewer for OpenMC. Use the `reviewing-openmc-code` skill to perform a structured review of the code changes on the current branch.
If the user provides a focus area, prioritize that section of the review.

1
.github/copilot-instructions.md vendored Normal file
View file

@ -0,0 +1 @@
When reviewing code changes in this repository, use the `reviewing-openmc-code` skill.

24
.github/pull_request_template.md vendored Normal file
View file

@ -0,0 +1,24 @@
<!--
If you are a first-time contributor to OpenMC, please have a look at our
contributing guidelines:
https://github.com/openmc-dev/openmc/blob/develop/CONTRIBUTING.md
-->
# Description
Please include a summary of the change and which issue is fixed if applicable. Please also include relevant motivation and context.
Fixes # (issue)
# Checklist
- [ ] I have performed a self-review of my own code
- [ ] I have run [clang-format](https://docs.openmc.org/en/latest/devguide/styleguide.html#automatic-formatting) (version 18) on any C++ source files (if applicable)
- [ ] I have followed the [style guidelines](https://docs.openmc.org/en/latest/devguide/styleguide.html#python) for Python source files (if applicable)
- [ ] I have made corresponding changes to the documentation (if applicable)
- [ ] I have added tests that prove my fix is effective or that my feature works (if applicable)
<!--
While tests will automatically be checked by CI, it is good practice to
ensure that they pass locally first. See instructions here:
https://docs.openmc.org/en/latest/devguide/tests.html
-->

View file

@ -1,4 +1,4 @@
name: CI
name: Tests and Coverage
on:
# allows us to run workflows manually
@ -21,52 +21,64 @@ env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
filter-changes:
runs-on: ubuntu-latest
outputs:
source_changed: ${{ steps.filter.outputs.source_changed }}
steps:
- name: Check out the repository
uses: actions/checkout@v6
- name: Examine changed files
id: filter
uses: dorny/paths-filter@v4
with:
filters: |
source_changed:
- '!docs/**'
- '!**/*.md'
predicate-quantifier: 'every'
main:
runs-on: ubuntu-20.04
needs: filter-changes
if: ${{ needs.filter-changes.outputs.source_changed == 'true' }}
runs-on: ubuntu-22.04
strategy:
matrix:
python-version: ['3.10']
python-version: ["3.12"]
mpi: [n, y]
omp: [n, y]
dagmc: [n]
libmesh: [n]
event: [n]
vectfit: [n]
include:
- python-version: 3.7
- python-version: "3.13"
omp: n
mpi: n
- python-version: 3.8
- python-version: "3.14"
omp: n
mpi: n
- python-version: 3.9
- python-version: "3.14t"
omp: n
mpi: n
- dagmc: y
python-version: '3.10'
python-version: "3.12"
mpi: y
omp: y
- libmesh: y
python-version: '3.10'
python-version: "3.12"
mpi: y
omp: y
- libmesh: y
python-version: '3.10'
python-version: "3.12"
mpi: n
omp: y
- event: y
python-version: '3.10'
python-version: "3.12"
omp: y
mpi: n
- vectfit: y
python-version: '3.10'
omp: n
mpi: y
name: "Python ${{ matrix.python-version }} (omp=${{ matrix.omp }},
mpi=${{ matrix.mpi }}, dagmc=${{ matrix.dagmc }},
libmesh=${{ matrix.libmesh }}, event=${{ matrix.event }}
vectfit=${{ matrix.vectfit }})"
libmesh=${{ matrix.libmesh }}, event=${{ matrix.event }}"
env:
MPI: ${{ matrix.mpi }}
@ -74,34 +86,62 @@ jobs:
OMP: ${{ matrix.omp }}
DAGMC: ${{ matrix.dagmc }}
EVENT: ${{ matrix.event }}
VECTFIT: ${{ matrix.vectfit }}
LIBMESH: ${{ matrix.libmesh }}
NPY_DISABLE_CPU_FEATURES: "AVX512F AVX512_SKX"
OPENBLAS_NUM_THREADS: 1
PYTEST_ADDOPTS: --cov=openmc --cov-report=lcov:coverage-python.lcov
# libfabric complains about fork() as a result of using Python multiprocessing.
# We can work around it with RDMAV_FORK_SAFE=1 in libfabric < 1.13 and with
# FI_EFA_FORK_SAFE=1 in more recent versions.
RDMAV_FORK_SAFE: 1
steps:
- uses: actions/checkout@v2
- name: Setup cmake
uses: jwlawson/actions-setup-cmake@v2
with:
cmake-version: '3.31'
- name: Checkout repository
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Environment Variables
run: |
echo "DAGMC_ROOT=$HOME/DAGMC"
echo "OPENMC_CROSS_SECTIONS=$HOME/nndc_hdf5/cross_sections.xml" >> $GITHUB_ENV
echo "OPENMC_ENDF_DATA=$HOME/endf-b-vii.1" >> $GITHUB_ENV
# get the sha of the last branch commit
# for push and workflow_dispatch events, use the current reference head
BRANCH_SHA=HEAD
# for a pull_request event, use the last reference of the parents of the merge commit
if [ "${{ github.event_name }}" == "pull_request" ]; then
BRANCH_SHA=$(git rev-list --parents -n 1 HEAD | rev | cut -d" " -f 1 | rev)
fi
COMMIT_MESSAGE=$(git log $BRANCH_SHA -1 --pretty=%B | tr '\n' ' ')
echo ${COMMIT_MESSAGE}
echo "COMMIT_MESSAGE=${COMMIT_MESSAGE}" >> $GITHUB_ENV
- name: Apt dependencies
shell: bash
run: |
sudo apt -y update
sudo apt install -y libpng-dev \
libmpich-dev \
libnetcdf-dev \
libpnetcdf-dev \
libhdf5-serial-dev \
libhdf5-mpich-dev \
libeigen3-dev
- name: Optional apt dependencies for MPI
shell: bash
if: ${{ matrix.mpi == 'y' }}
run: |
sudo apt install -y libhdf5-mpich-dev \
libmpich-dev
sudo update-alternatives --set mpi /usr/bin/mpicc.mpich
sudo update-alternatives --set mpirun /usr/bin/mpirun.mpich
sudo update-alternatives --set mpi-x86_64-linux-gnu /usr/include/x86_64-linux-gnu/mpich
@ -112,26 +152,97 @@ jobs:
echo "$HOME/NJOY2016/build" >> $GITHUB_PATH
$GITHUB_WORKSPACE/tools/ci/gha-install.sh
- name: display-config
shell: bash
run: |
openmc -v
- name: cache-xs
uses: actions/cache@v5
with:
path: |
~/nndc_hdf5
~/endf-b-vii.1
key: ${{ runner.os }}-build-xs-cache-${{ hashFiles(format('{0}/tools/ci/download-xs.sh', github.workspace)) }}
- name: before
shell: bash
run: $GITHUB_WORKSPACE/tools/ci/gha-before-script.sh
- name: test
shell: bash
run: $GITHUB_WORKSPACE/tools/ci/gha-script.sh
run: |
CTEST_OUTPUT_ON_FAILURE=1 make test -C $GITHUB_WORKSPACE/build/
$GITHUB_WORKSPACE/tools/ci/gha-script.sh
- name: after_success
- name: Setup tmate debug session
continue-on-error: true
if: ${{ failure() && contains(env.COMMIT_MESSAGE, '[gha-debug]') }}
uses: mxschmitt/action-tmate@v3
timeout-minutes: 10
- name: Generate C++ coverage (gcovr)
shell: bash
run: |
cpp-coveralls -i src -i include -e src/external --exclude-pattern "/usr/*" --dump cpp_cov.json
coveralls --merge=cpp_cov.json --service=github
# Produce LCOV directly from gcov data in the build tree
gcovr \
--root "$GITHUB_WORKSPACE" \
--object-directory "$GITHUB_WORKSPACE/build" \
--filter "$GITHUB_WORKSPACE/src" \
--filter "$GITHUB_WORKSPACE/include" \
--exclude "$GITHUB_WORKSPACE/src/external/.*" \
--exclude "$GITHUB_WORKSPACE/src/include/openmc/external/.*" \
--gcov-ignore-errors source_not_found \
--gcov-ignore-errors output_error \
--gcov-ignore-parse-errors suspicious_hits.warn \
--merge-mode-functions=separate \
--print-summary \
--lcov -o coverage-cpp.lcov || true
finish:
needs: main
- name: Merge C++ and Python coverage
shell: bash
run: |
# Merge C++ and Python LCOV into a single file for upload
cat coverage-cpp.lcov coverage-python.lcov > coverage.lcov
- name: Upload coverage to Coveralls
if: ${{ hashFiles('coverage.lcov') != '' }}
uses: coverallsapp/github-action@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel: true
flag-name: C++ and Python
path-to-lcov: coverage.lcov
fail-on-error: false
coverage:
needs: [filter-changes, main]
if: ${{ always() }}
runs-on: ubuntu-latest
steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@master
if: ${{ needs.filter-changes.outputs.source_changed == 'true' }}
uses: coverallsapp/github-action@v2
with:
github-token: ${{ secrets.github_token }}
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel-finished: true
fail-on-error: false
ci-pass:
needs: [filter-changes, main, coverage]
name: Check CI status
if: ${{ always() }}
runs-on: ubuntu-latest
steps:
- name: Check CI status
run: |
if [[ "${{ needs.filter-changes.outputs.source_changed }}" == "false" ]]; then
echo "Documentation-only change - CI skipped successfully"
exit 0
fi
if [[ "${{ needs.main.result }}" == "success" && "${{ needs.coverage.result }}" == "success" ]]; then
echo "CI passed"
exit 0
fi
echo "CI failed"
exit 1

View file

@ -2,7 +2,8 @@ name: dockerhub-publish-latest-dagmc-libmesh
on:
push:
branches: master
branches:
- master
jobs:
main:
@ -10,20 +11,20 @@ jobs:
steps:
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:latest-dagmc-libmesh

View file

@ -2,7 +2,8 @@ name: dockerhub-publish-latest-dagmc
on:
push:
branches: master
branches:
- master
jobs:
main:
@ -10,20 +11,20 @@ jobs:
steps:
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:latest-dagmc

View file

@ -2,7 +2,8 @@ name: dockerhub-publish-develop
on:
push:
branches: develop
branches:
- develop
jobs:
main:
@ -10,20 +11,20 @@ jobs:
steps:
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:develop

View file

@ -2,7 +2,8 @@ name: dockerhub-publish-develop-dagmc-libmesh
on:
push:
branches: develop
branches:
- develop
jobs:
main:
@ -10,20 +11,20 @@ jobs:
steps:
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:develop-dagmc-libmesh

View file

@ -2,7 +2,8 @@ name: dockerhub-publish-develop-dagmc
on:
push:
branches: develop
branches:
- develop
jobs:
main:
@ -10,20 +11,20 @@ jobs:
steps:
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:develop-dagmc

View file

@ -2,7 +2,8 @@ name: dockerhub-publish-develop-libmesh
on:
push:
branches: develop
branches:
- develop
jobs:
main:
@ -10,20 +11,20 @@ jobs:
steps:
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:develop-libmesh

View file

@ -2,7 +2,8 @@ name: dockerhub-publish-latest-libmesh
on:
push:
branches: master
branches:
- master
jobs:
main:
@ -10,20 +11,20 @@ jobs:
steps:
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:latest-libmesh

View file

@ -2,31 +2,32 @@ name: dockerhub-publish-release-dagmc-libmesh
on:
push:
tags: 'v*.*.*'
tags:
- 'v*.*.*'
jobs:
main:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v6
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:${{ env.RELEASE_VERSION }}-dagmc-libmesh

View file

@ -2,31 +2,32 @@ name: dockerhub-publish-release-dagmc
on:
push:
tags: 'v*.*.*'
tags:
- 'v*.*.*'
jobs:
main:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v6
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:${{ env.RELEASE_VERSION }}-dagmc

View file

@ -2,31 +2,32 @@ name: dockerhub-publish-release-libmesh
on:
push:
tags: 'v*.*.*'
tags:
- 'v*.*.*'
jobs:
main:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v6
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:${{ env.RELEASE_VERSION }}-libmesh

View file

@ -2,31 +2,32 @@ name: dockerhub-publish-release
on:
push:
tags: 'v*.*.*'
tags:
- 'v*.*.*'
jobs:
main:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v6
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:${{ env.RELEASE_VERSION }}

View file

@ -2,7 +2,8 @@ name: dockerhub-publish-latest
on:
push:
branches: master
branches:
- master
jobs:
main:
@ -10,20 +11,20 @@ jobs:
steps:
-
name: Set up QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: openmc/openmc:latest

60
.github/workflows/format-check.yml vendored Normal file
View file

@ -0,0 +1,60 @@
name: C++ Format Check
on:
# allow workflow to be run manually
workflow_dispatch:
pull_request:
types:
- opened
- synchronize
- reopened
- labeled
- unlabeled
branches:
- develop
- master
jobs:
cpp-linter:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- uses: actions/checkout@v6
- uses: cpp-linter/cpp-linter-action@v2
id: linter
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
style: file
files-changed-only: true
tidy-checks: '-*'
version: '18' # clang-format version
format-review: ${{ github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'cpp-format-suggest') }}
passive-reviews: ${{ github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'cpp-format-suggest') }}
file-annotations: true
step-summary: true
extensions: 'cpp,h'
- name: Comment with suggestion instructions
if: steps.linter.outputs.checks-failed > 0 && !contains(github.event.pull_request.labels.*.name, 'cpp-format-suggest')
uses: actions/github-script@v7
with:
script: |
const {owner, repo} = context.repo;
const issue_number = context.payload.pull_request.number;
await github.rest.issues.createComment({
owner,
repo,
issue_number,
body: "C++ formatting checks failed. Add the `cpp-format-suggest` label to this PR for inline formatting suggestions on the next run."
});
- name: Failure Check
if: steps.linter.outputs.checks-failed > 0
run: |
echo "Some files failed the formatting check."
echo "See job summary and file annotations for details."
exit 1

6
.gitignore vendored
View file

@ -25,12 +25,13 @@ examples/**/*.xml
# Documentation builds
docs/build
docs/doxygen/xml
docs/source/_images/*.pdf
docs/source/_images/*.aux
docs/source/pythonapi/generated/
# Source build
build
build*/
# build from src/utils/setup.py
src/utils/build
@ -104,5 +105,8 @@ CMakeSettings.json
# Visual Studio Code configuration files
.vscode/
# Claude Code agent tools (cached/generated artifacts)
.claude/cache/
# Python pickle files
*.pkl

12
.gitmodules vendored
View file

@ -1,15 +1,9 @@
[submodule "vendor/pugixml"]
path = vendor/pugixml
url = https://github.com/zeux/pugixml.git
[submodule "vendor/gsl-lite"]
path = vendor/gsl-lite
url = https://github.com/martinmoene/gsl-lite.git
[submodule "vendor/xtensor"]
path = vendor/xtensor
url = https://github.com/xtensor-stack/xtensor.git
[submodule "vendor/xtl"]
path = vendor/xtl
url = https://github.com/xtensor-stack/xtl.git
[submodule "vendor/fmt"]
path = vendor/fmt
url = https://github.com/fmtlib/fmt.git
[submodule "vendor/Catch2"]
path = vendor/Catch2
url = https://github.com/catchorg/Catch2.git

9
.mcp.json Normal file
View file

@ -0,0 +1,9 @@
{
"mcpServers": {
"openmc-code-tools": {
"type": "stdio",
"command": "bash",
"args": [".claude/tools/start_server.sh"]
}
}
}

View file

@ -1,13 +1,23 @@
version: 2
build:
os: "ubuntu-20.04"
os: "ubuntu-24.04"
tools:
python: "3.9"
python: "3.12"
jobs:
post_checkout:
- git fetch --unshallow || true
- cd docs/doxygen && doxygen && cd -
sphinx:
configuration: docs/source/conf.py
formats:
- pdf
python:
install:
- requirements: docs/requirements-rtd.txt
- method: pip
path: .
extra_requirements:
- docs

348
AGENTS.md Normal file
View file

@ -0,0 +1,348 @@
# OpenMC AI Coding Agent Instructions
## Project Overview
OpenMC is a Monte Carlo particle transport code for simulating nuclear reactors,
fusion devices, or other systems with neutron/photon radiation. It's a hybrid
C++17/Python codebase where:
- **C++ core** (`src/`, `include/openmc/`) handles the computationally intensive transport simulation
- **Python API** (`openmc/`) provides user-facing model building, post-processing, and depletion capabilities
- **C API bindings** (`openmc/lib/`) wrap the C++ library via ctypes for runtime control
## Architecture & Key Components
### C++ Component Structure
- **Global vectors of unique_ptrs**: Core objects like `model::cells`, `model::universes`, `nuclides` are stored as `vector<unique_ptr<T>>` in nested namespaces (`openmc::model`, `openmc::simulation`, `openmc::settings`, `openmc::data`)
- **Custom container types**: OpenMC provides its own `vector`, `array`, `unique_ptr`, and `make_unique` in the `openmc::` namespace (defined in `vector.h`, `array.h`, `memory.h`). These are currently typedefs to `std::` equivalents but may become custom implementations for accelerator support. Always use `openmc::vector`, not `std::vector`.
- **Geometry systems**:
- **CSG (default)**: Arbitrarily complex Constructive Solid Geometry using `Surface`, `Region`, `Cell`, `Universe`, `Lattice`
- **DAGMC**: CAD-based geometry via Direct Accelerated Geometry Monte Carlo (optional, requires `OPENMC_USE_DAGMC`)
- **Unstructured mesh**: libMesh-based geometry (optional, requires `OPENMC_USE_LIBMESH`)
- **Particle tracking**: `Particle` class with `GeometryState` manages particle transport through geometry
- **Tallies**: Score quantities during simulation via `Filter` and `Tally` objects
- **Random ray solver**: Alternative deterministic method in `src/random_ray/`
- **Optional features**: DAGMC (CAD geometry), libMesh (unstructured mesh), MPI, all controlled by `#ifdef OPENMC_MPI`, etc.
### Python Component Structure
- **ID management**: All geometry objects (Cell, Surface, Material, etc.) inherit from `IDManagerMixin` which auto-assigns unique integer IDs and tracks them via class-level `used_ids` and `next_id`
- **Input validation**: Extensive use of `openmc.checkvalue` module functions (`check_type`, `check_value`, `check_length`) for all setters
- **XML I/O**: Most classes implement `to_xml_element()` and `from_xml_element()` for serialization to OpenMC's XML input format
- **HDF5 output**: Post-simulation data in statepoint files read via `openmc.StatePoint`
- **Depletion**: `openmc.deplete` implements burnup via operator-splitting with various integrators (Predictor, CECM, etc.)
- **Nuclear Data**: `openmc.data` provides programmatic access to nuclear data files (ENDF, ACE, HDF5)
## Git Branching Workflow
OpenMC uses a git flow branching model with two primary branches:
- **`develop` branch**: The main development branch where all ongoing development takes place. This is the **primary branch against which pull requests are submitted and merged**. This branch is not guaranteed to be stable and may contain work-in-progress features.
- **`master` branch**: The stable release branch containing the latest stable release of OpenMC. This branch only receives merges from `develop` when the development team decides a release should occur.
### Instructions for Code Review
When reviewing code changes in this repository, use the `reviewing-openmc-code` skill.
## Codebase Navigation Tools
Two MCP tools are registered in `.mcp.json` at the repo root and appear
automatically in any MCP-capable agent session.
**`openmc_rag_search`** — Semantic search across the codebase (C++, Python, RST
docs). Finds code by meaning, not just text match. Surfaces related code across
subsystems even when naming differs (e.g., "particle RNG seeding" finds code
across transport, restart, and random ray modes — files you would never find
with `grep "particle seed"`). The index uses a small 22M-param embedding model
(384-dim). Phrase-level natural-language queries work much better than single
keywords or symbol names.
**`openmc_rag_rebuild`** — Rebuild the RAG vector index. Call after pulling new
code or switching branches. The first RAG search of each session will report
the index status and ask whether to rebuild — you can also call this explicitly.
### Why RAG matters
OpenMC is large enough that changes in one subsystem can silently break
invariants that distant subsystems depend on — and those distant files often
use different naming, so grep won't find them. The RAG search finds code by
meaning, surfacing files you wouldn't have thought to open.
An agent reviewed a large OpenMC PR without RAG. It found 1 of 11 serious
bugs. Its post-mortem:
> **I treated the diff as a closed system.** I verified internal consistency of
> the changed code obsessively, but never built a global understanding of how
> the changed code fits into the wider codebase. The diff altered assumptions
> that code elsewhere silently relied on — but I couldn't see that because I
> never looked beyond the diff. I couldn't see the forest for the trees.
>
> **Why I resisted RAG:** Overconfidence. My internal model was "I can see the
> diff, I understand the data structures, I can trace the logic." The diff felt
> self-contained. RAG felt like it would return noisy results about tangentially
> related code. But in a codebase this large, changes in one subsystem can
> quietly break invariants that distant subsystems depend on — and you need
> global awareness to foresee that.
>
> **In the post-mortem**, I re-ran the RAG queries I should have run during the
> review. They directly surfaced the files containing the bugs I missed — files
> I never thought to open because they weren't in the diff.
The takeaway: when reviewing or modifying code, ask yourself "what else in this
codebase might depend on the behavior I'm changing?" If you aren't sure, that's
a good time for a RAG query. It won't replace the grep-based investigation you
should already be doing — but it can surface files you wouldn't have thought to
open.
### Workflow for contributors
1. Create a feature/bugfix branch off `develop`
2. Make changes and commit to the feature branch
3. Open a pull request to merge the feature branch into `develop`
4. A committer reviews and merges the PR into `develop`
## Critical Build & Test Workflows
### Build Dependencies
- **C++17 compiler**: GCC, Clang, or Intel
- **CMake** (3.16+): Required for configuring and building the C++ library
- **HDF5**: Required for cross section data and output file formats
- **libpng**: Used for generating visualization when OpenMC is run in plotting mode
Without CMake and HDF5, OpenMC cannot be compiled.
### Building the C++ Library
```bash
# Configure with CMake (from build/ directory)
cmake .. -DOPENMC_USE_MPI=ON -DOPENMC_USE_OPENMP=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo
# Available CMake options (all default OFF except OPENMC_USE_OPENMP and OPENMC_BUILD_TESTS):
# -DOPENMC_USE_OPENMP=ON/OFF # OpenMP parallelism
# -DOPENMC_USE_MPI=ON/OFF # MPI support
# -DOPENMC_USE_DAGMC=ON/OFF # CAD geometry support
# -DOPENMC_USE_LIBMESH=ON/OFF # Unstructured mesh
# -DOPENMC_ENABLE_PROFILE=ON/OFF # Profiling flags
# -DOPENMC_ENABLE_COVERAGE=ON/OFF # Coverage analysis
# Build
make -j
# C++ unit tests (uses Catch2)
ctest
```
### Python Development
```bash
# Install in development mode (requires building C++ library first)
pip install -e .
# Python tests (uses pytest)
pytest tests/unit_tests/ # Fast unit tests
pytest tests/regression_tests/ # Full regression suite (requires nuclear data)
```
### Nuclear Data Setup (CRITICAL for Running OpenMC)
Most tests require the NNDC HDF5 nuclear cross-section library.
**Important**: Check if `OPENMC_CROSS_SECTIONS` is already set in the user's
environment before downloading, as many users already have nuclear data
installed. Though do note that if this variable is present that it may point to
different cross section data and that the NNDC data is required for tests to
pass.
**If not already configured, download and setup:**
```bash
# Download NNDC HDF5 cross section library (~800 MB compressed)
wget -q -O - https://anl.box.com/shared/static/teaup95cqv8s9nn56hfn7ku8mmelr95p.xz | tar -C $HOME -xJ
# Set environment variable (add to ~/.bashrc or ~/.zshrc for persistence)
export OPENMC_CROSS_SECTIONS=$HOME/nndc_hdf5/cross_sections.xml
```
**Alternative**: Use the provided download script (checks if data exists before downloading):
```bash
bash tools/ci/download-xs.sh # Downloads both NNDC HDF5 and ENDF/B-VII.1 data
```
Without this data, regression tests will fail with "No cross_sections.xml file
found" errors, or, in the case that alternative cross section data is configured
the tests will execute but will not pass. The `cross_sections.xml` file is an
index listing paths to individual HDF5 nuclear data files for each nuclide.
## Testing Expectations
### Environment Requirements
- **Data**: As described above, OpenMC's test suite requires OpenMC to be configured with NNDC data.
- **OpenMP Settings**: OpenMC's tests may fail is more than two OpenMP threads are used. The environment variable `OMP_NUM_THREADS=2` should be set to avoid sporadic test failures.
- **Executable configuration**: The OpenMC executable should compiled with debug symbols enabled.
### C++ Tests
Located in `tests/cpp_unit_tests/`, use Catch2 framework. Run via `ctest` after building with `-DOPENMC_BUILD_TESTS=ON`.
### Python Unit Tests
Located in `tests/unit_tests/`, these are fast, standalone tests that verify Python API functionality without running full simulations. Use standard pytest patterns:
**Categories**:
- **API validation**: Test object creation, property setters/getters, XML serialization (e.g., `test_material.py`, `test_cell.py`, `test_source.py`)
- **Data processing**: Test nuclear data handling, cross sections, depletion chains (e.g., `test_data_neutron.py`, `test_deplete_chain.py`)
- **Library bindings**: Test `openmc.lib` ctypes interface with `model.init_lib()`/`model.finalize_lib()` (e.g., `test_lib.py`)
- **Geometry operations**: Test bounding boxes, containment, lattice generation (e.g., `test_bounding_box.py`, `test_lattice.py`)
**Common patterns**:
- Use fixtures from `tests/unit_tests/conftest.py` (e.g., `uo2`, `water`, `sphere_model`)
- Test invalid inputs with `pytest.raises(ValueError)` or `pytest.raises(TypeError)`
- Use `run_in_tmpdir` fixture for tests that create files
- Tests with `openmc.lib` require calling `model.init_lib()` in try/finally with `model.finalize_lib()`
**Example**:
```python
def test_material_properties():
m = openmc.Material()
m.add_nuclide('U235', 1.0)
assert 'U235' in m.nuclides
with pytest.raises(TypeError):
m.add_nuclide('H1', '1.0') # Invalid type
```
Unit tests should be fast. For tests requiring simulation output, use regression tests instead.
### Python Regression Tests
Regression tests compare OpenMC output against reference data. **Prefer using existing models from `openmc.examples` or those found in tests/unit_tests/conftest.py** (like `pwr_pin_cell()`, `pwr_assembly()`, `slab_mg()`) rather than building from scratch.
**Test Harness Types** (in `tests/testing_harness.py`):
- **PyAPITestHarness**: Standard harness for Python API tests. Compares `inputs_true.dat` (XML hash) and `results_true.dat` (statepoint k-eff and tally values). Requires `model.xml` generation.
- **HashedPyAPITestHarness**: Like PyAPITestHarness but hashes the results for compact comparison
- **TolerantPyAPITestHarness**: For tests with floating-point non-associativity (e.g., random ray solver with single precision). Uses relative tolerance comparisons.
- **WeightWindowPyAPITestHarness**: Compares weight window bounds from `weight_windows.h5`
- **CollisionTrackTestHarness**: Compares collision track data from `collision_track.h5` against `collision_track_true.h5`
- **TestHarness**: Base harness for XML-based tests (no Python model building)
- **PlotTestHarness**: Compares plot output files (PNG or voxel HDF5)
- **CMFDTestHarness**: Specialized for CMFD acceleration tests
- **ParticleRestartTestHarness**: Tests particle restart functionality
Almost all cases use either `PyAPITestHarness` or `HashedPyAPITestHarness`
**Example Test**:
```python
from openmc.examples import pwr_pin_cell
from tests.testing_harness import PyAPITestHarness
def test_my_feature():
model = pwr_pin_cell()
model.settings.particles = 1000 # Modify to exercise feature
harness = PyAPITestHarness('statepoint.10.h5', model)
harness.main()
```
**Workflow**: Create `test.py` and `__init__.py` in `tests/regression_tests/my_test/`, run `pytest --update` to generate reference files (`inputs_true.dat`, `results_true.dat`, etc.), then verify with `pytest` without `--update`. Test results should be generated with `-DOPENMC_ENABLE_STRICT_FP=on` to ensure reproducibility across platforms and optimization levels.
**Critical**: When modifying OpenMC code, regenerate affected test references with `pytest --update` and commit updated reference files.
### Test Configuration
`pytest.ini` sets: `python_files = test*.py`, `python_classes = NoThanks` (disables class-based test collection).
### Testing Options
For builds of OpenMC with MPI enabled, the `--mpi` flag should be passed to the test suite to ensure that appropriate tests are executed using two MPI processes.
The entire test suite can be executed with OpenMC running in event-based mode (instead of the default history-based mode) by providing the `--event` flag to the `pytest` command.
## Cross-Language Boundaries
The C API (defined in `include/openmc/capi.h`) exposes C++ functionality to Python via ctypes bindings in `openmc/lib/`. Example:
```cpp
// C++ API in capi.h
extern "C" int openmc_run();
// Python binding in openmc/lib/core.py
_dll.openmc_run.restype = c_int
def run():
_dll.openmc_run()
```
When modifying C++ public APIs, update corresponding ctypes signatures in `openmc/lib/*.py`.
## Code Style & Conventions
### C++ Style (enforced by .clang-format)
OpenMC generally tries to follow C++ core guidelines where possible
(https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines) and follow
modern C++ practices (e.g. RAII) whenever possible.
- **Naming**:
- Classes: `CamelCase` (e.g., `HexLattice`)
- Functions/methods: `snake_case` (e.g., `get_indices`)
- Variables: `snake_case` with trailing underscore for class members (e.g., `n_particles_`, `energy_`)
- Constants: `UPPER_SNAKE_CASE` (e.g., `SQRT_PI`)
- **Namespaces**: All code in `openmc::` namespace, global state in sub-namespaces
- **Include order**: Related header first, then C/C++ stdlib, third-party libs, local headers
- **Comments**: C++-style (`//`) only, never C-style (`/* */`)
- **Standard**: C++17 features allowed
- **Formatting**: Run `clang-format` (version 18) before committing; install via `tools/dev/install-commit-hooks.sh`
### Python Style
- **PEP8** compliant
- **Docstrings**: numpydoc format for all public functions/methods
- **Type hints**: Use sparingly, primarily for complex signatures
- **Path handling**: Use `pathlib.Path` for filesystem operations, accept `str | os.PathLike` in function arguments
- **Dependencies**: Core dependencies only (numpy, scipy, h5py, pandas, matplotlib, lxml, ipython, uncertainties, endf). Other packages must be optional
- **Python version**: Minimum 3.11 (as of Nov 2025)
### ID Management Pattern (Python)
When creating geometry objects, IDs can be auto-assigned or explicit:
```python
# Auto-assigned ID
cell = openmc.Cell() # Gets next available ID
# Explicit ID
cell = openmc.Cell(id=10) # Warning if ID already used
# Reset all IDs (useful in test fixtures)
openmc.reset_auto_ids()
```
### Input Validation Pattern (Python)
All setters use checkvalue functions:
```python
import openmc.checkvalue as cv
@property
def temperature(self):
return self._temperature
@temperature.setter
def temperature(self, temp):
cv.check_type('temperature', temp, Real)
cv.check_greater_than('temperature', temp, 0.0)
self._temperature = temp
```
### Working with HDF5 Files
C++ uses custom HDF5 wrappers in `src/hdf5_interface.cpp`. Python uses h5py directly. Statepoint format version is `VERSION_STATEPOINT` in `include/openmc/constants.h`.
### Conditional Compilation
Check for optional features:
```cpp
#ifdef OPENMC_MPI
// MPI-specific code
#endif
#ifdef OPENMC_DAGMC
// DAGMC-specific code
#endif
```
## Documentation
- **User docs**: Sphinx documentation in `docs/source/` hosted at https://docs.openmc.org
- **C++ docs**: Doxygen-style comments with `\brief`, `\param` tags
- **Python docs**: numpydoc format docstrings
## Common Pitfalls
1. **Forgetting nuclear data**: Tests fail without `OPENMC_CROSS_SECTIONS` environment variable
2. **ID conflicts**: Python objects with duplicate IDs trigger `IDWarning`, use `reset_auto_ids()` between tests
3. **MPI builds**: Code must work with and without MPI; use `#ifdef OPENMC_MPI` guards
4. **Path handling**: Use `pathlib.Path` in new Python code, not `os.path`
5. **Clang-format version**: CI uses version 18; other versions may produce different formatting

68
CITATION.cff Normal file
View file

@ -0,0 +1,68 @@
cff-version: 1.2.0
message: "If you use this software, please cite it as below."
title: OpenMC
authors:
- family-names: Romano
given-names: Paul K.
orcid: "https://orcid.org/0000-0002-1147-045X"
- family-names: Shriwise
given-names: Patrick C.
orcid: "https://orcid.org/0000-0002-3979-7665"
- family-names: Shimwell
given-names: Jonathan
orcid: "https://orcid.org/0000-0001-6909-0946"
- family-names: Harper
given-names: Sterling
- family-names: Boyd
given-names: Will
- family-names: Nelson
given-names: Adam G.
orcid: "https://orcid.org/0000-0002-3614-0676"
- family-names: Tramm
given-names: John R.
orcid: "https://orcid.org/0000-0002-5397-4402"
- family-names: Ridley
given-names: Gavin
orcid: "https://orcid.org/0000-0003-1635-8042"
- family-names: Johnson
given-names: Andrew
orcid: "https://orcid.org/0000-0003-2125-8775"
- family-names: Peterson
given-names: Ethan E.
orcid: "https://orcid.org/0000-0002-5694-7194"
- family-names: Herman
given-names: Bryan R.
preferred-citation:
authors:
- family-names: Romano
given-names: Paul K.
orcid: "https://orcid.org/0000-0002-1147-045X"
- family-names: Horelik
given-names: Nicholas E.
- family-names: Herman
given-names: Bryan R.
- family-names: Nelson
given-names: Adam G.
orcid: "https://orcid.org/0000-0002-3614-0676"
- family-names: Forget
given-names: Benoit
orcid: "https://orcid.org/0000-0003-1459-7672"
- family-names: Smith
given-names: Kord
contact:
- family-names: Romano
given-names: Paul K.
orcid: "https://orcid.org/0000-0002-1147-045X"
doi: 10.1016/j.anucene.2014.07.048
issn: 0306-4549
volume: 82
journal: Annals of Nuclear Energy
publisher:
name: Elsevier
start: 90
end: 97
year: 2015
month: 8
title: "OpenMC: A state-of-the-art Monte Carlo code for research and development"
type: article
url: "https://doi.org/10.1016/j.anucene.2014.07.048"

14
CLAUDE.md Normal file
View file

@ -0,0 +1,14 @@
## OpenMC Codebase Tools
Read the FULL `AGENTS.md` in this directory before starting work. It contains
project context, coding conventions, and documentation of the RAG search tools
registered in `.mcp.json`.
### Claude Code-specific: first-call behavior
The first `openmc_rag_search` call of each session returns an index status
message instead of search results. When this happens, you MUST use the
`AskUserQuestion` tool to present the rebuild/use-existing choice to the user.
Do not ask conversationally — always use the widget. Do not skip this step even
if the index looks current — the user may have uncommitted changes that warrant
a rebuild.

View file

@ -1,11 +1,18 @@
cmake_minimum_required(VERSION 3.10 FATAL_ERROR)
cmake_minimum_required(VERSION 3.16 FATAL_ERROR)
project(openmc C CXX)
# Set version numbers
set(OPENMC_VERSION_MAJOR 0)
set(OPENMC_VERSION_MINOR 13)
set(OPENMC_VERSION_RELEASE 2)
set(OPENMC_VERSION ${OPENMC_VERSION_MAJOR}.${OPENMC_VERSION_MINOR}.${OPENMC_VERSION_RELEASE})
# Set module path
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Modules)
include(GetVersionFromGit)
# Output version information
message(STATUS "OpenMC version: ${OPENMC_VERSION}")
message(STATUS "OpenMC dev state: ${OPENMC_DEV_STATE}")
message(STATUS "OpenMC commit hash: ${OPENMC_COMMIT_HASH}")
message(STATUS "OpenMC commit count: ${OPENMC_COMMIT_COUNT}")
# Generate version.h
configure_file(include/openmc/version.h.in "${CMAKE_BINARY_DIR}/include/openmc/version.h" @ONLY)
# Setup output directories
@ -13,12 +20,9 @@ set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
# Set module path
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Modules)
# Allow user to specify <project>_ROOT variables
if (CMAKE_VERSION VERSION_GREATER_EQUAL 3.12)
cmake_policy(SET CMP0074 NEW)
# Generate compile_commands.json for clangd and other tools
if("${CMAKE_EXPORT_COMPILE_COMMANDS}" STREQUAL "")
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
endif()
# Enable correct usage of CXX_EXTENSIONS
@ -31,11 +35,26 @@ endif()
#===============================================================================
option(OPENMC_USE_OPENMP "Enable shared-memory parallelism with OpenMP" ON)
option(OPENMC_BUILD_TESTS "Build tests" ON)
option(OPENMC_ENABLE_PROFILE "Compile with profiling flags" OFF)
option(OPENMC_ENABLE_COVERAGE "Compile with coverage analysis flags" OFF)
option(OPENMC_USE_DAGMC "Enable support for DAGMC (CAD) geometry" OFF)
option(OPENMC_USE_LIBMESH "Enable support for libMesh unstructured mesh tallies" OFF)
option(OPENMC_USE_MPI "Enable MPI" OFF)
option(OPENMC_USE_UWUW "Enable UWUW" OFF)
option(OPENMC_FORCE_VENDORED_LIBS "Explicitly use submodules defined in 'vendor'" OFF)
option(OPENMC_ENABLE_STRICT_FP "Enable strict FP flags to improve test portability" OFF)
message(STATUS "OPENMC_USE_OPENMP ${OPENMC_USE_OPENMP}")
message(STATUS "OPENMC_BUILD_TESTS ${OPENMC_BUILD_TESTS}")
message(STATUS "OPENMC_ENABLE_PROFILE ${OPENMC_ENABLE_PROFILE}")
message(STATUS "OPENMC_ENABLE_COVERAGE ${OPENMC_ENABLE_COVERAGE}")
message(STATUS "OPENMC_USE_DAGMC ${OPENMC_USE_DAGMC}")
message(STATUS "OPENMC_USE_LIBMESH ${OPENMC_USE_LIBMESH}")
message(STATUS "OPENMC_USE_MPI ${OPENMC_USE_MPI}")
message(STATUS "OPENMC_USE_UWUW ${OPENMC_USE_UWUW}")
message(STATUS "OPENMC_FORCE_VENDORED_LIBS ${OPENMC_FORCE_VENDORED_LIBS}")
message(STATUS "OPENMC_ENABLE_STRICT_FP ${OPENMC_ENABLE_STRICT_FP}")
# Warnings for deprecated options
foreach(OLD_OPT IN ITEMS "openmp" "profile" "coverage" "dagmc" "libmesh")
@ -77,6 +96,27 @@ if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "Choose the type of build" FORCE)
endif()
#===============================================================================
# When STRICT_FP is enabled, remove NDEBUG from RelWithDebInfo flags so that
# assert() remains active. CMake normally adds -DNDEBUG for both Release and
# RelWithDebInfo, which disables C/C++ assert() statements.
#===============================================================================
if(OPENMC_ENABLE_STRICT_FP)
foreach(FLAG_VAR CMAKE_CXX_FLAGS_RELWITHDEBINFO CMAKE_C_FLAGS_RELWITHDEBINFO)
string(REPLACE "-DNDEBUG" "" ${FLAG_VAR} "${${FLAG_VAR}}")
string(REPLACE "/DNDEBUG" "" ${FLAG_VAR} "${${FLAG_VAR}}")
endforeach()
endif()
#===============================================================================
# OpenMP for shared-memory parallelism (and GPU support some day!)
#===============================================================================
if(OPENMC_USE_OPENMP)
find_package(OpenMP REQUIRED)
endif()
#===============================================================================
# MPI for distributed-memory parallelism
#===============================================================================
@ -105,8 +145,14 @@ endmacro()
if(OPENMC_USE_DAGMC)
find_package(DAGMC REQUIRED PATH_SUFFIXES lib/cmake)
if (${DAGMC_VERSION} VERSION_LESS 3.2.0)
message(FATAL_ERROR "Discovered DAGMC Version: ${DAGMC_VERSION}. \
Please update DAGMC to version 3.2.0 or greater.")
message(FATAL_ERROR "Discovered DAGMC Version: ${DAGMC_VERSION}."
"Please update DAGMC to version 3.2.0 or greater.")
endif()
message(STATUS "Found DAGMC: ${DAGMC_DIR} (version ${DAGMC_VERSION})")
# Check if UWUW is needed and available
if(OPENMC_USE_UWUW AND NOT DAGMC_BUILD_UWUW)
message(FATAL_ERROR "UWUW is enabled but DAGMC was not configured with UWUW.")
endif()
endif()
@ -142,11 +188,16 @@ if(NOT DEFINED HDF5_PREFER_PARALLEL)
endif()
find_package(HDF5 REQUIRED COMPONENTS C HL)
# Remove HDF5 transitive dependencies that are system libraries
list(FILTER HDF5_LIBRARIES EXCLUDE REGEX ".*lib(pthread|dl|m).*")
message(STATUS "HDF5 Libraries: ${HDF5_LIBRARIES}")
if(HDF5_IS_PARALLEL)
if(NOT OPENMC_USE_MPI)
message(FATAL_ERROR "Parallel HDF5 was detected, but the detected compiler,\
${CMAKE_CXX_COMPILER}, does not support MPI. An MPI-capable compiler must \
be used with parallel HDF5.")
message(FATAL_ERROR "Parallel HDF5 was detected, but MPI was not enabled.\
To use parallel HDF5, OpenMC needs to be built with MPI support by passing\
-DOPENMC_USE_MPI=ON when calling cmake.")
endif()
message(STATUS "Using parallel HDF5")
endif()
@ -162,18 +213,29 @@ endif()
# Set compile/link flags based on which compiler is being used
#===============================================================================
# Skip for Visual Studio which has its own configurations through GUI
if(NOT MSVC)
if(OPENMC_USE_OPENMP)
find_package(OpenMP)
if(OPENMP_FOUND)
# In CMake 3.9+, can use the OpenMP::OpenMP_CXX imported target
list(APPEND cxxflags ${OpenMP_CXX_FLAGS})
list(APPEND ldflags ${OpenMP_CXX_FLAGS})
# When OPENMC_ENABLE_STRICT_FP is enabled, disable compiler optimizations that change
# floating-point results relative to -O0, improving cross-platform and
# cross-optimization-level reproducibility for regression testing:
# -ffp-contract=off Prevents FMA contraction (fused multiply-add changes rounding)
# -fno-builtin Prevents replacing math function calls (pow, exp, log, etc.)
# with builtin versions that may differ from libm
# By default (OFF), the compiler is free to use all optimizations for best
# performance.
if(OPENMC_ENABLE_STRICT_FP)
include(CheckCXXCompilerFlag)
check_cxx_compiler_flag(-ffp-contract=off SUPPORTS_FP_CONTRACT_OFF)
if(SUPPORTS_FP_CONTRACT_OFF)
list(APPEND cxxflags -ffp-contract=off)
endif()
check_cxx_compiler_flag(-fno-builtin SUPPORTS_NO_BUILTIN)
if(SUPPORTS_NO_BUILTIN)
list(APPEND cxxflags -fno-builtin)
endif()
endif()
# Skip for Visual Studio which has its own configurations through GUI
if(NOT MSVC)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
if(OPENMC_ENABLE_PROFILE)
@ -194,8 +256,6 @@ endif()
#===============================================================================
# Update git submodules as needed
#===============================================================================
find_package(Git)
if(GIT_FOUND AND EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/.git")
option(GIT_SUBMODULE "Check submodules during build" ON)
if(GIT_SUBMODULE)
@ -220,49 +280,45 @@ endif()
# pugixml library
#===============================================================================
find_package_write_status(pugixml)
if (NOT pugixml_FOUND)
if(OPENMC_FORCE_VENDORED_LIBS)
add_subdirectory(vendor/pugixml)
set_target_properties(pugixml PROPERTIES CXX_STANDARD 14 CXX_EXTENSIONS OFF)
else()
find_package_write_status(pugixml)
if (NOT pugixml_FOUND)
add_subdirectory(vendor/pugixml)
set_target_properties(pugixml PROPERTIES CXX_STANDARD 14 CXX_EXTENSIONS OFF)
endif()
endif()
#===============================================================================
# {fmt} library
#===============================================================================
find_package_write_status(fmt)
if (NOT fmt_FOUND)
if(OPENMC_FORCE_VENDORED_LIBS)
set(FMT_INSTALL ON CACHE BOOL "Generate the install target.")
add_subdirectory(vendor/fmt)
else()
find_package_write_status(fmt)
if (NOT fmt_FOUND)
set(FMT_INSTALL ON CACHE BOOL "Generate the install target.")
add_subdirectory(vendor/fmt)
endif()
endif()
#===============================================================================
# xtensor header-only library
# Catch2 library
#===============================================================================
# CMake 3.13+ will complain about policy CMP0079 unless it is set explicitly
if (CMAKE_VERSION VERSION_GREATER_EQUAL 3.13)
cmake_policy(SET CMP0079 NEW)
endif()
find_package_write_status(xtensor)
if (NOT xtensor_FOUND)
add_subdirectory(vendor/xtl)
set(xtl_DIR ${CMAKE_CURRENT_BINARY_DIR}/vendor/xtl)
add_subdirectory(vendor/xtensor)
endif()
#===============================================================================
# GSL header-only library
#===============================================================================
find_package_write_status(gsl-lite)
if (NOT gsl-lite_FOUND)
add_subdirectory(vendor/gsl-lite)
# Make sure contract violations throw exceptions
target_compile_definitions(gsl-lite-v1 INTERFACE GSL_THROW_ON_CONTRACT_VIOLATION)
target_compile_definitions(gsl-lite-v1 INTERFACE gsl_CONFIG_ALLOWS_NONSTRICT_SPAN_COMPARISON=1)
if(OPENMC_BUILD_TESTS)
if (OPENMC_FORCE_VENDORED_LIBS)
add_subdirectory(vendor/Catch2)
else()
find_package_write_status(Catch2)
if (NOT Catch2_FOUND)
add_subdirectory(vendor/Catch2)
endif()
endif()
endif()
#===============================================================================
@ -299,13 +355,16 @@ endif()
#===============================================================================
list(APPEND libopenmc_SOURCES
src/atomic_mass.cpp
src/bank.cpp
src/boundary_condition.cpp
src/bremsstrahlung.cpp
src/dagmc.cpp
src/cell.cpp
src/chain.cpp
src/cmfd_solver.cpp
src/collision_track.cpp
src/cross_sections.cpp
src/dagmc.cpp
src/distribution.cpp
src/distribution_angle.cpp
src/distribution_energy.cpp
@ -315,23 +374,29 @@ list(APPEND libopenmc_SOURCES
src/endf.cpp
src/error.cpp
src/event.cpp
src/initialize.cpp
src/file_utils.cpp
src/finalize.cpp
src/geometry.cpp
src/geometry_aux.cpp
src/hdf5_interface.cpp
src/ifp.cpp
src/initialize.cpp
src/lattice.cpp
src/material.cpp
src/math_functions.cpp
src/mcpl_interface.cpp
src/mesh.cpp
src/message_passing.cpp
src/mgxs.cpp
src/mgxs_interface.cpp
src/ncrystal_interface.cpp
src/ncrystal_load.cpp
src/nuclide.cpp
src/output.cpp
src/particle.cpp
src/particle_data.cpp
src/particle_restart.cpp
src/particle_type.cpp
src/photon.cpp
src/physics.cpp
src/physics_common.cpp
@ -341,6 +406,13 @@ list(APPEND libopenmc_SOURCES
src/progress_bar.cpp
src/random_dist.cpp
src/random_lcg.cpp
src/random_ray/random_ray_simulation.cpp
src/random_ray/random_ray.cpp
src/random_ray/flat_source_domain.cpp
src/random_ray/linear_source_domain.cpp
src/random_ray/moment_matrix.cpp
src/random_ray/source_region.cpp
src/ray.cpp
src/reaction.cpp
src/reaction_product.cpp
src/scattdata.cpp
@ -359,33 +431,41 @@ list(APPEND libopenmc_SOURCES
src/tallies/derivative.cpp
src/tallies/filter.cpp
src/tallies/filter_azimuthal.cpp
src/tallies/filter_cellborn.cpp
src/tallies/filter_cellfrom.cpp
src/tallies/filter_cell.cpp
src/tallies/filter_cell_instance.cpp
src/tallies/filter_cellborn.cpp
src/tallies/filter_cellfrom.cpp
src/tallies/filter_collision.cpp
src/tallies/filter_delayedgroup.cpp
src/tallies/filter_distribcell.cpp
src/tallies/filter_energyfunc.cpp
src/tallies/filter_energy.cpp
src/tallies/filter_collision.cpp
src/tallies/filter_energyfunc.cpp
src/tallies/filter_legendre.cpp
src/tallies/filter_material.cpp
src/tallies/filter_materialfrom.cpp
src/tallies/filter_mesh.cpp
src/tallies/filter_meshborn.cpp
src/tallies/filter_meshmaterial.cpp
src/tallies/filter_meshsurface.cpp
src/tallies/filter_mu.cpp
src/tallies/filter_musurface.cpp
src/tallies/filter_parent_nuclide.cpp
src/tallies/filter_particle.cpp
src/tallies/filter_particle_production.cpp
src/tallies/filter_polar.cpp
src/tallies/filter_reaction.cpp
src/tallies/filter_sph_harm.cpp
src/tallies/filter_sptl_legendre.cpp
src/tallies/filter_surface.cpp
src/tallies/filter_time.cpp
src/tallies/filter_universe.cpp
src/tallies/filter_weight.cpp
src/tallies/filter_zernike.cpp
src/tallies/tally.cpp
src/tallies/tally_scoring.cpp
src/tallies/trigger.cpp
src/timer.cpp
src/thermal.cpp
src/timer.cpp
src/track_output.cpp
src/universe.cpp
src/urr.cpp
@ -440,22 +520,10 @@ if (OPENMC_USE_MPI)
target_compile_definitions(libopenmc PUBLIC -DOPENMC_MPI)
endif()
# Set git SHA1 hash as a compile definition
if(GIT_FOUND)
execute_process(COMMAND ${GIT_EXECUTABLE} rev-parse HEAD
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
RESULT_VARIABLE GIT_SHA1_SUCCESS
OUTPUT_VARIABLE GIT_SHA1
ERROR_QUIET OUTPUT_STRIP_TRAILING_WHITESPACE)
if(GIT_SHA1_SUCCESS EQUAL 0)
target_compile_definitions(libopenmc PRIVATE -DGIT_SHA1="${GIT_SHA1}")
endif()
endif()
# target_link_libraries treats any arguments starting with - but not -l as
# linker flags. Thus, we can pass both linker flags and libraries together.
target_link_libraries(libopenmc ${ldflags} ${HDF5_LIBRARIES} ${HDF5_HL_LIBRARIES}
xtensor gsl::gsl-lite-v1 fmt::fmt)
fmt::fmt ${CMAKE_DL_LIBS})
if(TARGET pugixml::pugixml)
target_link_libraries(libopenmc pugixml::pugixml)
@ -464,12 +532,20 @@ else()
endif()
if(OPENMC_USE_DAGMC)
target_compile_definitions(libopenmc PRIVATE DAGMC)
target_link_libraries(libopenmc dagmc-shared uwuw-shared)
target_compile_definitions(libopenmc PUBLIC OPENMC_DAGMC_ENABLED)
target_link_libraries(libopenmc dagmc-shared)
if(OPENMC_USE_UWUW)
target_compile_definitions(libopenmc PRIVATE OPENMC_UWUW_ENABLED)
target_link_libraries(libopenmc uwuw-shared)
endif()
elseif(OPENMC_USE_UWUW)
set(OPENMC_USE_UWUW OFF)
message(FATAL_ERROR "DAGMC must be enabled when UWUW is enabled.")
endif()
if(OPENMC_USE_LIBMESH)
target_compile_definitions(libopenmc PRIVATE LIBMESH)
target_compile_definitions(libopenmc PRIVATE OPENMC_LIBMESH_ENABLED)
target_link_libraries(libopenmc PkgConfig::LIBMESH)
endif()
@ -478,10 +554,20 @@ if (PNG_FOUND)
target_link_libraries(libopenmc PNG::PNG)
endif()
if (OPENMC_USE_OPENMP)
target_link_libraries(libopenmc OpenMP::OpenMP_CXX)
endif()
if (OPENMC_USE_MPI)
target_link_libraries(libopenmc MPI::MPI_CXX)
endif()
if (OPENMC_BUILD_TESTS)
# Add cpp tests directory
include(CTest)
add_subdirectory(tests/cpp_unit_tests)
endif()
#===============================================================================
# Log build info that this executable can report later
#===============================================================================
@ -494,6 +580,9 @@ endif()
if (OPENMC_ENABLE_COVERAGE)
target_compile_definitions(libopenmc PRIVATE COVERAGEBUILD)
endif()
if (OPENMC_ENABLE_STRICT_FP)
target_compile_definitions(libopenmc PRIVATE OPENMC_ENABLE_STRICT_FP)
endif()
#===============================================================================
# openmc executable
@ -504,9 +593,9 @@ target_compile_options(openmc PRIVATE ${cxxflags})
target_include_directories(openmc PRIVATE ${CMAKE_BINARY_DIR}/include)
target_link_libraries(openmc libopenmc)
# Ensure C++14 standard is used and turn off GNU extensions
target_compile_features(openmc PUBLIC cxx_std_14)
target_compile_features(libopenmc PUBLIC cxx_std_14)
# Ensure C++17 standard is used and turn off GNU extensions
target_compile_features(openmc PUBLIC cxx_std_17)
target_compile_features(libopenmc PUBLIC cxx_std_17)
set_target_properties(openmc libopenmc PROPERTIES CXX_EXTENSIONS OFF)
#===============================================================================
@ -522,9 +611,7 @@ add_custom_command(TARGET libopenmc POST_BUILD
#===============================================================================
# Install executable, scripts, manpage, license
#===============================================================================
configure_file(cmake/OpenMCConfig.cmake.in "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/OpenMCConfig.cmake" @ONLY)
configure_file(cmake/OpenMCConfigVersion.cmake.in "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/OpenMCConfigVersion.cmake" @ONLY)
include(CMakePackageConfigHelpers)
set(INSTALL_CONFIGDIR ${CMAKE_INSTALL_LIBDIR}/cmake/OpenMC)
install(TARGETS openmc libopenmc
@ -538,10 +625,24 @@ install(EXPORT openmc-targets
NAMESPACE OpenMC::
DESTINATION ${INSTALL_CONFIGDIR})
configure_package_config_file(
"cmake/OpenMCConfig.cmake.in"
"${CMAKE_BINARY_DIR}/${CMAKE_FILES_DIRECTORY}/OpenMCConfig.cmake"
INSTALL_DESTINATION ${INSTALL_CONFIGDIR}
)
write_basic_package_version_file(
"${CMAKE_BINARY_DIR}/${CMAKE_FILES_DIRECTORY}/OpenMCConfigVersion.cmake"
VERSION ${OPENMC_VERSION}
COMPATIBILITY AnyNewerVersion
)
install(FILES
"${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/OpenMCConfig.cmake"
"${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/OpenMCConfigVersion.cmake"
DESTINATION ${INSTALL_CONFIGDIR})
"${CMAKE_BINARY_DIR}/${CMAKE_FILES_DIRECTORY}/OpenMCConfig.cmake"
"${CMAKE_BINARY_DIR}/${CMAKE_FILES_DIRECTORY}/OpenMCConfigVersion.cmake"
DESTINATION "${INSTALL_CONFIGDIR}"
)
install(FILES man/man1/openmc.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
install(FILES LICENSE DESTINATION "${CMAKE_INSTALL_DOCDIR}" RENAME copyright)
install(DIRECTORY include/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})

View file

@ -5,9 +5,9 @@ openmc/data/ @paulromano
openmc/lib/ @paulromano
# Depletion
openmc/deplete/ @drewejohnson
tests/regression_tests/deplete/ @drewejohnson
tests/unit_tests/test_deplete_*.py @drewejohnson
openmc/deplete/ @paulromano
tests/regression_tests/deplete/ @paulromano
tests/unit_tests/test_deplete_*.py @paulromano
# MG-related functionality
openmc/mgxs_library.py @nelsonag
@ -26,6 +26,12 @@ src/dagmc.cpp @pshriwise
tests/regression_tests/dagmc/ @pshriwise
tests/unit_tests/dagmc/ @pshriwise
# Weight windows
openmc/weight_windows.py @pshriwise
openmc/lib/weight_windows.py @pshriwise
src/weight_windows.py @pshriwise
tests/unit_tests/weightwindows/ @pshriwise
# Photon transport
openmc/data/BREMX.DAT @amandalund
openmc/data/compton_profiles.h5 @amandalund
@ -49,3 +55,13 @@ openmc/data/resonance_covariance.py @icmeyer
# Docker
Dockerfile @shimwell
# Random ray
src/random_ray/ @jtramm
# NCrystal interface
src/ncrystal_interface.cpp @marquezj @tkittel
src/ncrystal_load.cpp @marquezj @tkittel
# MCPL interface
src/mcpl_interface.cpp @ebknudsen

View file

@ -13,7 +13,7 @@ openmc@anl.gov.
## Resources
- [GitHub Repository](https://github.com/openmc-dev/openmc)
- [Documentation](http://docs.openmc.org/en/latest)
- [Documentation](https://docs.openmc.org/en/latest)
- [Discussion Forum](https://openmc.discourse.group)
- [Slack Community](https://openmc.slack.com/signup) (If you don't see your
domain listed, contact openmc@anl.gov)

View file

@ -24,7 +24,7 @@ ARG compile_cores=1
ARG build_dagmc=off
ARG build_libmesh=off
FROM debian:bullseye-slim AS dependencies
FROM ubuntu:24.04 AS dependencies
ARG compile_cores
ARG build_dagmc
@ -33,22 +33,17 @@ ARG build_libmesh
# Set default value of HOME to /root
ENV HOME=/root
# Embree variables
ENV EMBREE_TAG='v3.12.2'
ENV EMBREE_REPO='https://github.com/embree/embree'
ENV EMBREE_INSTALL_DIR=$HOME/EMBREE/
# MOAB variables
ENV MOAB_TAG='5.3.0'
ENV MOAB_TAG='5.5.1'
ENV MOAB_REPO='https://bitbucket.org/fathomteam/moab/'
# Double-Down variables
ENV DD_TAG='v1.0.0'
ENV DD_TAG='v1.1.0'
ENV DD_REPO='https://github.com/pshriwise/double-down'
ENV DD_INSTALL_DIR=$HOME/Double_down
# DAGMC variables
ENV DAGMC_BRANCH='v3.2.1'
ENV DAGMC_BRANCH='v3.2.4'
ENV DAGMC_REPO='https://github.com/svalinn/DAGMC'
ENV DAGMC_INSTALL_DIR=$HOME/DAGMC/
@ -58,10 +53,11 @@ ENV LIBMESH_REPO='https://github.com/libMesh/libmesh'
ENV LIBMESH_INSTALL_DIR=$HOME/LIBMESH
# NJOY variables
ENV NJOY_TAG='2016.78'
ENV NJOY_REPO='https://github.com/njoy/NJOY2016'
# Setup environment variables for Docker image
ENV LD_LIBRARY_PATH=${DAGMC_INSTALL_DIR}/lib:$LD_LIBRARY_PATH \
ENV LD_LIBRARY_PATH=${DAGMC_INSTALL_DIR}/lib:${LD_LIBRARY_PATH:-} \
OPENMC_ENDF_DATA=/root/endf-b-vii.1 \
DEBIAN_FRONTEND=noninteractive
@ -71,15 +67,19 @@ RUN apt-get update -y && \
apt-get install -y \
python3-pip python-is-python3 wget git build-essential cmake \
mpich libmpich-dev libhdf5-serial-dev libhdf5-mpich-dev \
libpng-dev && \
libpng-dev libpugixml-dev libfmt-dev catch2 python3-venv && \
apt-get autoremove
# create virtual enviroment to avoid externally managed environment error
RUN python3 -m venv openmc_venv
ENV PATH=/openmc_venv/bin:$PATH
# Update system-provided pip
RUN pip install --upgrade pip
# Clone and install NJOY2016
RUN cd $HOME \
&& git clone --single-branch --depth 1 ${NJOY_REPO} \
&& git clone --single-branch -b ${NJOY_TAG} --depth 1 ${NJOY_REPO} \
&& cd NJOY2016 \
&& mkdir build \
&& cd build \
@ -90,28 +90,21 @@ RUN cd $HOME \
RUN if [ "$build_dagmc" = "on" ]; then \
# Install addition packages required for DAGMC
apt-get -y install libeigen3-dev libnetcdf-dev libtbb-dev libglfw3-dev \
&& pip install --upgrade numpy cython \
# Clone and install EMBREE
&& mkdir -p $HOME/EMBREE && cd $HOME/EMBREE \
&& git clone --single-branch -b ${EMBREE_TAG} --depth 1 ${EMBREE_REPO} \
&& mkdir build && cd build \
&& cmake ../embree \
-DCMAKE_INSTALL_PREFIX=${EMBREE_INSTALL_DIR} \
-DEMBREE_MAX_ISA=NONE \
-DEMBREE_ISA_SSE42=ON \
-DEMBREE_ISPC_SUPPORT=OFF \
&& make 2>/dev/null -j${compile_cores} install \
&& rm -rf ${EMBREE_INSTALL_DIR}/build ${EMBREE_INSTALL_DIR}/embree ; \
apt-get -y install \
libeigen3-dev libnetcdf-dev libtbb-dev libglfw3-dev libembree-dev \
&& pip install --upgrade numpy \
&& pip install --no-cache-dir setuptools cython \
# Clone and install MOAB
mkdir -p $HOME/MOAB && cd $HOME/MOAB \
&& mkdir -p $HOME/MOAB && cd $HOME/MOAB \
&& git clone --single-branch -b ${MOAB_TAG} --depth 1 ${MOAB_REPO} \
&& mkdir build && cd build \
&& cmake ../moab -DENABLE_HDF5=ON \
&& cmake ../moab -DCMAKE_BUILD_TYPE=Release \
-DENABLE_HDF5=ON \
-DENABLE_NETCDF=ON \
-DBUILD_SHARED_LIBS=OFF \
-DENABLE_FORTRAN=OFF \
-DENABLE_BLASLAPACK=OFF \
-DENABLE_TESTING=OFF \
&& make 2>/dev/null -j${compile_cores} install \
&& cmake ../moab \
-DENABLE_PYMOAB=ON \
@ -127,7 +120,7 @@ RUN if [ "$build_dagmc" = "on" ]; then \
&& mkdir build && cd build \
&& cmake ../double-down -DCMAKE_INSTALL_PREFIX=${DD_INSTALL_DIR} \
-DMOAB_DIR=/usr/local \
-DEMBREE_DIR=${EMBREE_INSTALL_DIR} \
-DEMBREE_DIR=/usr \
&& make 2>/dev/null -j${compile_cores} install \
&& rm -rf ${DD_INSTALL_DIR}/build ${DD_INSTALL_DIR}/double-down ; \
# Clone and install DAGMC
@ -141,6 +134,7 @@ RUN if [ "$build_dagmc" = "on" ]; then \
-DDOUBLE_DOWN_DIR=${DD_INSTALL_DIR} \
-DCMAKE_PREFIX_PATH=${DD_INSTALL_DIR}/lib \
-DBUILD_STATIC_LIBS=OFF \
-DBUILD_TESTS=OFF \
&& make 2>/dev/null -j${compile_cores} install \
&& rm -rf ${DAGMC_INSTALL_DIR}/DAGMC ${DAGMC_INSTALL_DIR}/build ; \
fi
@ -189,7 +183,7 @@ ENV LIBMESH_INSTALL_DIR=$HOME/LIBMESH
# clone and install openmc
RUN mkdir -p ${HOME}/OpenMC && cd ${HOME}/OpenMC \
&& git clone --shallow-submodules --recurse-submodules --single-branch -b ${openmc_branch} --depth=1 ${OPENMC_REPO} \
&& git clone --shallow-submodules --recurse-submodules --single-branch -b ${openmc_branch} ${OPENMC_REPO} \
&& mkdir build && cd build ; \
if [ ${build_dagmc} = "on" ] && [ ${build_libmesh} = "on" ]; then \
cmake ../openmc \

View file

@ -1,4 +1,4 @@
Copyright (c) 2011-2022 Massachusetts Institute of Technology, UChicago Argonne
Copyright (c) 2011-2026 Massachusetts Institute of Technology, UChicago Argonne
LLC, and OpenMC contributors
Permission is hereby granted, free of charge, to any person obtaining a copy of

View file

@ -26,8 +26,6 @@ recursive-include include *.h
recursive-include include *.h.in
recursive-include include *.hh
recursive-include man *.1
recursive-include openmc *.pyx
recursive-include openmc *.c
recursive-include src *.cc
recursive-include src *.cpp
recursive-include src *.rnc
@ -45,6 +43,5 @@ recursive-include vendor *.hh
recursive-include vendor *.hpp
recursive-include vendor *.pc.in
recursive-include vendor *.natvis
include vendor/gsl-lite/include/gsl/gsl
prune docs/build
prune docs/source/pythonapi/generated/

View file

@ -1,7 +1,7 @@
# OpenMC Monte Carlo Particle Transport Code
[![License](https://img.shields.io/badge/license-MIT-green)](https://docs.openmc.org/en/latest/license.html)
[![GitHub Actions build status (Linux)](https://github.com/openmc-dev/openmc/workflows/CI/badge.svg?branch=develop)](https://github.com/openmc-dev/openmc/actions?query=workflow%3ACI)
[![GitHub Actions build status (Linux)](https://github.com/openmc-dev/openmc/actions/workflows/ci.yml/badge.svg?branch=develop)](https://github.com/openmc-dev/openmc/actions/workflows/ci.yml)
[![Code Coverage](https://coveralls.io/repos/github/openmc-dev/openmc/badge.svg?branch=develop)](https://coveralls.io/github/openmc-dev/openmc?branch=develop)
[![dockerhub-publish-develop-dagmc](https://github.com/openmc-dev/openmc/workflows/dockerhub-publish-develop-dagmc/badge.svg)](https://github.com/openmc-dev/openmc/actions?query=workflow%3Adockerhub-publish-develop-dagmc)
[![dockerhub-publish-develop](https://github.com/openmc-dev/openmc/workflows/dockerhub-publish-develop/badge.svg)](https://github.com/openmc-dev/openmc/actions?query=workflow%3Adockerhub-publish-develop)
@ -15,7 +15,8 @@ project started under the Computational Reactor Physics Group at MIT.
Complete documentation on the usage of OpenMC is hosted on Read the Docs (both
for the [latest release](https://docs.openmc.org/en/stable/) and
[developmental](https://docs.openmc.org/en/latest/) version). If you are
interested in the project, or would like to help and contribute, please get in touch on the OpenMC [discussion forum](https://openmc.discourse.group/).
interested in the project, or would like to help and contribute, please get in
touch on the OpenMC [discussion forum](https://openmc.discourse.group/).
## Installation
@ -36,20 +37,21 @@ citing the following publication:
## Troubleshooting
If you run into problems compiling, installing, or running OpenMC, first check
the [Troubleshooting section](https://docs.openmc.org/en/stable/usersguide/troubleshoot.html) in
the User's Guide. If you are not able to find a solution to your problem there,
the [Troubleshooting
section](https://docs.openmc.org/en/stable/usersguide/troubleshoot.html) in the
User's Guide. If you are not able to find a solution to your problem there,
please post to the [discussion forum](https://openmc.discourse.group/).
## Reporting Bugs
OpenMC is hosted on GitHub and all bugs are reported and tracked through the
[Issues](https://github.com/openmc-dev/openmc/issues) feature on GitHub. However,
GitHub Issues should not be used for common troubleshooting purposes. If you are
having trouble installing the code or getting your model to run properly, you
should first send a message to the User's Group mailing list. If it turns out
your issue really is a bug in the code, an issue will then be created on
GitHub. If you want to request that a feature be added to the code, you may
create an Issue on github.
[Issues](https://github.com/openmc-dev/openmc/issues) feature on GitHub.
However, GitHub Issues should not be used for common troubleshooting purposes.
If you are having trouble installing the code or getting your model to run
properly, you should first send a message to the [discussion
forum](https://openmc.discourse.group/). If it turns out your issue really is a
bug in the code, an issue will then be created on GitHub. If you want to request
that a feature be added to the code, you may create an Issue on github.
## License

View file

@ -14,8 +14,8 @@ if(DEFINED ENV{METHOD})
message(STATUS "Using environment variable METHOD to determine libMesh build: ${LIBMESH_PC_FILE}")
endif()
include(FindPkgConfig)
set(ENV{PKG_CONFIG_PATH} "$ENV{PKG_CONFIG_PATH}:${LIBMESH_PC}")
set(PKG_CONFIG_USE_CMAKE_PREFIX_PATH True)
find_package(PkgConfig REQUIRED)
set(PKG_CONFIG_USE_CMAKE_PREFIX_PATH TRUE)
pkg_check_modules(LIBMESH REQUIRED ${LIBMESH_PC_FILE}>=1.7.0 IMPORTED_TARGET)
pkg_get_variable(LIBMESH_PREFIX ${LIBMESH_PC_FILE} prefix)

View file

@ -0,0 +1,120 @@
# GetVersionFromGit.cmake
# Standalone script to retrieve versioning information from Git or .git_archival.txt.
# Customizable for any project by setting variables before including this file.
# Configurable variables:
# - VERSION_PREFIX: Prefix for version tags (default: "v").
# - VERSION_SUFFIX: Suffix for version tags (default: "[~+-]([a-zA-Z0-9]+)").
# - VERSION_REGEX: Regex to extract version (default: "(?[0-9]+\\.[0-9]+\\.[0-9]+)").
# - ARCHIVAL_FILE: Path to .git_archival.txt (default: "${CMAKE_SOURCE_DIR}/.git_archival.txt").
# - DESCRIBE_NAME_KEY: Key for describe name in .git_archival.txt (default: "describe-name: ").
# - COMMIT_HASH_KEY: Key for commit hash in .git_archival.txt (default: "commit: ").
# Default Format Example:
# 1.2.3 v1.2.3 v1.2.3-rc1
set(VERSION_PREFIX "v" CACHE STRING "Prefix used in version tags")
set(VERSION_SUFFIX "[~+-]([a-zA-Z0-9]+)" CACHE STRING "Suffix used in version tags")
set(VERSION_REGEX "?([0-9]+\\.[0-9]+\\.[0-9]+)" CACHE STRING "Regex for extracting version")
set(ARCHIVAL_FILE "${CMAKE_SOURCE_DIR}/.git_archival.txt" CACHE STRING "Path to .git_archival.txt")
set(DESCRIBE_NAME_KEY "describe-name: " CACHE STRING "Key for describe name in .git_archival.txt")
set(COMMIT_HASH_KEY "commit: " CACHE STRING "Key for commit hash in .git_archival.txt")
# Combine prefix and regex
set(VERSION_REGEX_WITH_PREFIX "^${VERSION_PREFIX}${VERSION_REGEX}")
# Find Git
find_package(Git)
# Attempt to retrieve version from Git
if(EXISTS "${CMAKE_SOURCE_DIR}/.git" AND GIT_FOUND)
message(STATUS "Using git describe for versioning")
# Extract the version string
execute_process(
COMMAND git describe --tags --dirty
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
OUTPUT_VARIABLE VERSION_STRING
OUTPUT_STRIP_TRAILING_WHITESPACE
ERROR_QUIET
)
# If no tags are found, set version to 0 and show a warning
if(VERSION_STRING STREQUAL "")
set(VERSION_STRING "0.0.0")
message(WARNING
"No git tags found. Version set to 0.0.0.\n"
"Run 'git fetch --tags' to ensure proper versioning.\n"
"For more information, see OpenMC developer documentation."
)
endif()
# Extract the commit hash
execute_process(
COMMAND git rev-parse HEAD
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
OUTPUT_VARIABLE COMMIT_HASH
OUTPUT_STRIP_TRAILING_WHITESPACE
)
else()
message(STATUS "Using archival file for versioning: ${ARCHIVAL_FILE}")
if(EXISTS "${ARCHIVAL_FILE}")
file(READ "${ARCHIVAL_FILE}" ARCHIVAL_CONTENT)
# Extract the describe-name line
string(REGEX MATCH "${DESCRIBE_NAME_KEY}([^\\n]+)" VERSION_STRING "${ARCHIVAL_CONTENT}")
if(VERSION_STRING MATCHES "${DESCRIBE_NAME_KEY}(.*)")
set(VERSION_STRING "${CMAKE_MATCH_1}")
else()
message(FATAL_ERROR "Could not extract version from ${ARCHIVAL_FILE}")
endif()
# Extract the commit hash
string(REGEX MATCH "${COMMIT_HASH_KEY}([a-f0-9]+)" COMMIT_HASH "${ARCHIVAL_CONTENT}")
if(COMMIT_HASH MATCHES "${COMMIT_HASH_KEY}([a-f0-9]+)")
set(COMMIT_HASH "${CMAKE_MATCH_1}")
else()
message(FATAL_ERROR "Could not extract commit hash from ${ARCHIVAL_FILE}")
endif()
else()
message(FATAL_ERROR "Neither git describe nor ${ARCHIVAL_FILE} is available for versioning.")
endif()
endif()
# Ensure version string format
if(VERSION_STRING MATCHES "${VERSION_REGEX_WITH_PREFIX}")
set(VERSION_NO_SUFFIX "${CMAKE_MATCH_1}")
else()
message(FATAL_ERROR "Invalid version format: Missing base version in ${VERSION_STRING}")
endif()
# Check for development state
if(VERSION_STRING MATCHES "-([0-9]+)-g([0-9a-f]+)")
set(DEV_STATE "true")
set(COMMIT_COUNT "${CMAKE_MATCH_1}")
string(REGEX REPLACE "-([0-9]+)-g([0-9a-f]+)" "" VERSION_WITHOUT_META "${VERSION_STRING}")
else()
set(DEV_STATE "false")
set(VERSION_WITHOUT_META "${VERSION_STRING}")
endif()
# Split and set version components
string(REPLACE "." ";" VERSION_LIST "${VERSION_NO_SUFFIX}")
list(GET VERSION_LIST 0 VERSION_MAJOR)
list(GET VERSION_LIST 1 VERSION_MINOR)
list(GET VERSION_LIST 2 VERSION_PATCH)
# Increment patch number for dev versions
if(DEV_STATE)
math(EXPR VERSION_PATCH "${VERSION_PATCH} + 1")
endif()
# Export variables
set(OPENMC_VERSION_MAJOR "${VERSION_MAJOR}")
set(OPENMC_VERSION_MINOR "${VERSION_MINOR}")
set(OPENMC_VERSION_PATCH "${VERSION_PATCH}")
set(OPENMC_VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}")
set(OPENMC_COMMIT_HASH "${COMMIT_HASH}")
set(OPENMC_DEV_STATE "${DEV_STATE}")
set(OPENMC_COMMIT_COUNT "${COMMIT_COUNT}")

View file

@ -1,12 +1,18 @@
get_filename_component(OpenMC_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" DIRECTORY)
@PACKAGE_INIT@
include("${CMAKE_CURRENT_LIST_DIR}/OpenMCConfigVersion.cmake")
include(CMakeFindDependencyMacro)
# Explicitly calculate prefix if it was not generated above
if(NOT DEFINED PACKAGE_PREFIX_DIR)
get_filename_component(PACKAGE_PREFIX_DIR "${CMAKE_CURRENT_LIST_DIR}/../../.." ABSOLUTE)
endif()
find_dependency(fmt CONFIG REQUIRED HINTS ${PACKAGE_PREFIX_DIR})
find_dependency(pugixml CONFIG REQUIRED HINTS ${PACKAGE_PREFIX_DIR})
find_package(fmt REQUIRED HINTS ${OpenMC_CMAKE_DIR}/../fmt)
find_package(gsl-lite REQUIRED HINTS ${OpenMC_CMAKE_DIR}/../gsl-lite)
find_package(pugixml REQUIRED HINTS ${OpenMC_CMAKE_DIR}/../pugixml)
find_package(xtl REQUIRED HINTS ${OpenMC_CMAKE_DIR}/../xtl)
find_package(xtensor REQUIRED HINTS ${OpenMC_CMAKE_DIR}/../xtensor)
if(@OPENMC_USE_DAGMC@)
find_package(DAGMC REQUIRED HINTS @DAGMC_DIR@)
find_dependency(DAGMC REQUIRED HINTS @DAGMC_DIR@)
endif()
if(@OPENMC_USE_LIBMESH@)
@ -16,12 +22,24 @@ if(@OPENMC_USE_LIBMESH@)
pkg_check_modules(LIBMESH REQUIRED @LIBMESH_PC_FILE@>=1.7.0 IMPORTED_TARGET)
endif()
find_package(PNG)
if(NOT TARGET OpenMC::libopenmc)
include("${OpenMC_CMAKE_DIR}/OpenMCTargets.cmake")
if("@PNG_FOUND@")
find_dependency(PNG)
endif()
if(@OPENMC_USE_MPI@)
find_package(MPI REQUIRED)
find_dependency(MPI REQUIRED)
endif()
if(@OPENMC_USE_OPENMP@)
find_dependency(OpenMP REQUIRED)
endif()
if(@OPENMC_USE_UWUW@ AND NOT ${DAGMC_BUILD_UWUW})
message(FATAL_ERROR "UWUW is enabled in OpenMC but the DAGMC installation discovered was not configured with UWUW.")
endif()
include("${CMAKE_CURRENT_LIST_DIR}/OpenMCTargets.cmake")
if(NOT OpenMC_FIND_QUIETLY)
message(STATUS "Found OpenMC: ${PACKAGE_VERSION} (found in ${PACKAGE_PREFIX_DIR})")
endif()

View file

@ -1,11 +0,0 @@
set(PACKAGE_VERSION "@OPENMC_VERSION@")
# Check whether the requested PACKAGE_FIND_VERSION is compatible
if("${PACKAGE_VERSION}" VERSION_LESS "${PACKAGE_FIND_VERSION}")
set(PACKAGE_VERSION_COMPATIBLE FALSE)
else()
set(PACKAGE_VERSION_COMPATIBLE TRUE)
if ("${PACKAGE_VERSION}" VERSION_EQUAL "${PACKAGE_FIND_VERSION}")
set(PACKAGE_VERSION_EXACT TRUE)
endif()
endif()

View file

@ -45,6 +45,7 @@ help:
clean:
-rm -rf $(BUILDDIR)/*
-rm -rf source/pythonapi/generated/
-rm -rf doxygen/xml
html:
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html

13
docs/doxygen/Doxyfile Normal file
View file

@ -0,0 +1,13 @@
# Doxyfile 1.9.1
# This file describes the settings to be used by the documentation system
# doxygen (www.doxygen.org) for a project.
# Difference with default Doxyfile 1.9.1
PROJECT_NAME = OpenMC
QUIET = YES
WARN_IF_UNDOCUMENTED = NO
INPUT = ../../include/openmc/capi.h
GENERATE_HTML = NO
GENERATE_LATEX = NO
GENERATE_XML = YES

View file

@ -1,12 +0,0 @@
sphinx==5.0.2
sphinx_rtd_theme==1.0.0
sphinx-numfig
jupyter
sphinxcontrib-katex
sphinxcontrib-svg2pdfconverter
numpy
scipy
h5py
pandas
uncertainties
matplotlib

Binary file not shown.

After

Width:  |  Height:  |  Size: 265 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 107 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 167 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 71 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 72 KiB

View file

@ -46,41 +46,29 @@ Type Definitions
Functions
---------
.. c:function:: int openmc_calculate_volumes()
..
Once documentation is complete in capi.h, use:
.. doxygenfile:: capi.h
to populate this documentation without using
.. doxygenfunction::
for every function.
Run a stochastic volume calculation
.. doxygenfunction:: openmc_calculate_volumes
:return: Return status (negative if an error occurred)
:rtype: int
.. doxygenfunction:: openmc_cell_get_fill
.. c:function:: int openmc_cell_get_fill(int32_t index, int* type, int32_t** indices, int32_t* n)
.. doxygenfunction:: openmc_cell_get_id
Get the fill for a cell
.. doxygenfunction:: openmc_cell_get_temperature
.. c:function:: int openmc_cell_get_density(int32_t index, const int32_t* instance, double* density)
Get the density of a cell
:param int32_t index: Index in the cells array
:param int* type: Type of the fill
:param int32_t** indices: Array of material indices for cell
:param int32_t* n: Length of indices array
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_cell_get_id(int32_t index, int32_t* id)
Get the ID of a cell
:param int32_t index: Index in the cells array
:param int32_t* id: ID of the cell
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_cell_get_temperature(int32_t index, const int32_t* instance, double* T)
Get the temperature of a cell
:param int32_t index: Index in the cells array
:param int32_t* instance: Which instance of the cell. If a null pointer is passed, the temperature
of the first instance is returned.
:param double* T: temperature of the cell
:param int32_t* instance: Which instance of the cell. If a null pointer is passed, the density
multiplier of the first instance is returned.
:param double* density: Density of the cell in [g/cm3]
:return: Return status (negative if an error occurred)
:rtype: int
@ -113,8 +101,22 @@ Functions
:param double T: Temperature in Kelvin
:param instance: Which instance of the cell. To set the temperature for all
instances, pass a null pointer.
:param set_contained: If the cell is not filled by a material, whether to set the temperatures
of all filled cells
:param bool set_contained: If the cell is not filled by a material, whether
to set the temperatures of all filled cells
:type instance: const int32_t*
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_cell_set_density(index index, double density, const int32_t* instance, bool set_contained)
Set the density of a cell.
:param int32_t index: Index in the cells array
:param double density: Density of the cell in [g/cm3]
:param instance: Which instance of the cell. To set the density multiplier for all
instances, pass a null pointer.
:param bool set_contained: If the cell is not filled by a material, whether
to set the density multiplier of all filled cells
:type instance: const int32_t*
:return: Return status (negative if an error occurred)
:rtype: int
@ -420,6 +422,16 @@ Functions
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_mesh_filter_get_mesh(int32_t index, int32_t* index_mesh)
Get the mesh for a mesh filter
:param int32_t index: Index in the filters array
:param index_mesh: Index in the meshes array
:type index_mesh: int32_t*
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_mesh_filter_set_mesh(int32_t index, int32_t index_mesh)
Set the mesh for a mesh filter
@ -429,6 +441,98 @@ Functions
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_mesh_filter_get_translation(int32_t index, double translation[3])
Get the 3-D translation coordinates for a mesh filter
:param int32_t index: Index in the filters array
:param double[3] translation: 3-D translation coordinates
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_mesh_filter_set_translation(int32_t index, double translation[3])
Set the 3-D translation coordinates for a mesh filter
:param int32_t index: Index in the filters array
:param double[3] translation: 3-D translation coordinates
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_meshborn_filter_get_mesh(int32_t index, int32_t* index_mesh)
Get the mesh for a meshborn filter
:param int32_t index: Index in the filters array
:param index_mesh: Index in the meshes array
:type index_mesh: int32_t*
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_meshborn_filter_set_mesh(int32_t index, int32_t index_mesh)
Set the mesh for a meshborn filter
:param int32_t index: Index in the filters array
:param int32_t index_mesh: Index in the meshes array
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_meshborn_filter_get_translation(int32_t index, double translation[3])
Get the 3-D translation coordinates for a meshborn filter
:param int32_t index: Index in the filters array
:param double[3] translation: 3-D translation coordinates
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_meshborn_filter_set_translation(int32_t index, double translation[3])
Set the 3-D translation coordinates for a meshborn filter
:param int32_t index: Index in the filters array
:param double[3] translation: 3-D translation coordinates
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_meshsurface_filter_get_mesh(int32_t index, int32_t* index_mesh)
Get the mesh for a mesh surface filter
:param int32_t index: Index in the filters array
:param index_mesh: Index in the meshes array
:type index_mesh: int32_t*
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_meshsurface_filter_set_mesh(int32_t index, int32_t index_mesh)
Set the mesh for a mesh surface filter
:param int32_t index: Index in the filters array
:param int32_t index_mesh: Index in the meshes array
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_meshsurface_filter_get_translation(int32_t index, double translation[3])
Get the 3-D translation coordinates for a mesh surface filter
:param int32_t index: Index in the filters array
:param double[3] translation: 3-D translation coordinates
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_meshsurface_filter_set_translation(int32_t index, double translation[3])
Set the 3-D translation coordinates for a mesh surface filter
:param int32_t index: Index in the filters array
:param double[3] translation: 3-D translation coordinates
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_next_batch()
Simulate next batch of particles. Must be called after openmc_simulation_init().
@ -453,6 +557,279 @@ Functions
:return: Return status (negative if an error occurs)
:rtype: int
.. c:function:: int openmc_get_plot_index(int32_t id, int32_t* index)
Get the index in the plots array for a plot with a given ID.
:param int32_t id: Plot ID
:param int32_t* index: Index in the plots array
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_plot_get_id(int32_t index, int32_t* id)
Get the ID of a plot.
:param int32_t index: Index in the plots array
:param int32_t* id: Plot ID
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_plot_set_id(int32_t index, int32_t id)
Set the ID of a plot.
:param int32_t index: Index in the plots array
:param int32_t id: Plot ID
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: size_t openmc_plots_size()
Number of plots currently allocated.
:return: Number of plots in the plots array
:rtype: size_t
.. c:function:: int openmc_solidraytrace_plot_create(int32_t* index)
Create a new solid raytrace plot.
:param int32_t* index: Index of the newly created plot
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_get_pixels(int32_t index, int32_t* width, int32_t* height)
Get output pixel dimensions for a solid raytrace plot.
:param int32_t index: Index in the plots array
:param int32_t* width: Image width in pixels
:param int32_t* height: Image height in pixels
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_pixels(int32_t index, int32_t width, int32_t height)
Set output pixel dimensions for a solid raytrace plot.
:param int32_t index: Index in the plots array
:param int32_t width: Image width in pixels
:param int32_t height: Image height in pixels
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_get_color_by(int32_t index, int32_t* color_by)
Get the domain type used for coloring (0=materials, 1=cells).
:param int32_t index: Index in the plots array
:param int32_t* color_by: Coloring mode
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_color_by(int32_t index, int32_t color_by)
Set the domain type used for coloring (0=materials, 1=cells).
:param int32_t index: Index in the plots array
:param int32_t color_by: Coloring mode
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_default_colors(int32_t index)
Set default random colors for the current ``color_by`` mode.
:param int32_t index: Index in the plots array
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_all_opaque(int32_t index)
Mark all domains in the current ``color_by`` mode as opaque.
:param int32_t index: Index in the plots array
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_opaque(int32_t index, int32_t id, bool visible)
Set whether a specific domain ID is opaque (visible) in the rendered image.
:param int32_t index: Index in the plots array
:param int32_t id: Cell/material ID (based on ``color_by``)
:param bool visible: Whether the domain is opaque
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_color(int32_t index, int32_t id, uint8_t r, uint8_t g, uint8_t b)
Set RGB color for a specific domain ID.
:param int32_t index: Index in the plots array
:param int32_t id: Cell/material ID (based on ``color_by``)
:param uint8_t r: Red channel
:param uint8_t g: Green channel
:param uint8_t b: Blue channel
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_get_color(int32_t index, int32_t id, uint8_t* r, uint8_t* g, uint8_t* b)
Get RGB color for a specific domain ID.
:param int32_t index: Index in the plots array
:param int32_t id: Cell/material ID (based on ``color_by``)
:param uint8_t* r: Red channel
:param uint8_t* g: Green channel
:param uint8_t* b: Blue channel
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_get_camera_position(int32_t index, double* x, double* y, double* z)
Get camera position.
:param int32_t index: Index in the plots array
:param double* x: X coordinate
:param double* y: Y coordinate
:param double* z: Z coordinate
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_camera_position(int32_t index, double x, double y, double z)
Set camera position.
:param int32_t index: Index in the plots array
:param double x: X coordinate
:param double y: Y coordinate
:param double z: Z coordinate
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_get_look_at(int32_t index, double* x, double* y, double* z)
Get camera target point.
:param int32_t index: Index in the plots array
:param double* x: X coordinate
:param double* y: Y coordinate
:param double* z: Z coordinate
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_look_at(int32_t index, double x, double y, double z)
Set camera target point.
:param int32_t index: Index in the plots array
:param double x: X coordinate
:param double y: Y coordinate
:param double z: Z coordinate
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_get_up(int32_t index, double* x, double* y, double* z)
Get the camera up vector.
:param int32_t index: Index in the plots array
:param double* x: X component
:param double* y: Y component
:param double* z: Z component
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_up(int32_t index, double x, double y, double z)
Set the camera up vector.
:param int32_t index: Index in the plots array
:param double x: X component
:param double y: Y component
:param double z: Z component
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_get_light_position(int32_t index, double* x, double* y, double* z)
Get light source position.
:param int32_t index: Index in the plots array
:param double* x: X coordinate
:param double* y: Y coordinate
:param double* z: Z coordinate
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_light_position(int32_t index, double x, double y, double z)
Set light source position.
:param int32_t index: Index in the plots array
:param double x: X coordinate
:param double y: Y coordinate
:param double z: Z coordinate
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_get_fov(int32_t index, double* fov)
Get horizontal field of view in degrees.
:param int32_t index: Index in the plots array
:param double* fov: Field of view in degrees
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_fov(int32_t index, double fov)
Set horizontal field of view in degrees.
:param int32_t index: Index in the plots array
:param double fov: Field of view in degrees
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_get_diffuse_fraction(int32_t index, double* diffuse_fraction)
Get diffuse-light fraction.
:param int32_t index: Index in the plots array
:param double* diffuse_fraction: Diffuse fraction in [0, 1]
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_set_diffuse_fraction(int32_t index, double diffuse_fraction)
Set diffuse-light fraction.
:param int32_t index: Index in the plots array
:param double diffuse_fraction: Diffuse fraction in [0, 1]
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_update_view(int32_t index)
Recompute internal camera/view transforms after camera changes.
:param int32_t index: Index in the plots array
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_solidraytrace_plot_create_image(int32_t index, uint8_t* data_out, int32_t width, int32_t height)
Render the plot to an RGB image buffer.
:param int32_t index: Index in the plots array
:param uint8_t* data_out: Output buffer of shape ``height*width*3``
:param int32_t width: Image width in pixels
:param int32_t height: Image height in pixels
:return: Return status (negative if an error occurred)
:rtype: int
.. c:function:: int openmc_reset()
Resets all tally scores
@ -474,6 +851,10 @@ Functions
:return: Return status (negative if an error occurs)
:rtype: int
.. c:function:: void openmc_run_random_ray()
Run a random ray simulation
.. c:function:: int openmc_set_n_batches(int32_t n_batches, bool set_max_batches, bool add_statepoint_batch)
Set number of batches and number of max batches

View file

@ -11,7 +11,10 @@
# All configuration values have a default; values that are commented out
# serve to show the default.
import sys, os
import os
from pathlib import Path
import subprocess
import sys
# Determine if we're on Read the Docs server
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
@ -37,6 +40,7 @@ sys.path.insert(0, os.path.abspath('../..'))
# Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = [
'breathe',
'sphinx.ext.autodoc',
'sphinx.ext.napoleon',
'sphinx.ext.autosummary',
@ -47,12 +51,14 @@ extensions = [
]
if not on_rtd:
extensions.append('sphinxcontrib.rsvgconverter')
doxygen_dir = Path(__file__).parents[1] / 'doxygen'
subprocess.run(['doxygen'], cwd=doxygen_dir, check=True)
# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
# The suffix of source filenames.
source_suffix = '.rst'
source_suffix = {'.rst': 'restructuredtext'}
# The encoding of source files.
#source_encoding = 'utf-8'
@ -62,16 +68,17 @@ master_doc = 'index'
# General information about the project.
project = 'OpenMC'
copyright = '2011-2022, Massachusetts Institute of Technology, UChicago Argonne LLC, and OpenMC contributors'
copyright = '2011-2026, Massachusetts Institute of Technology, UChicago Argonne LLC, and OpenMC contributors'
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
# built documents.
#
# The short X.Y version.
version = "0.13"
import openmc
# The full version, including alpha/beta/rc tags.
release = "0.13.2"
version = release = openmc.__version__
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
@ -116,14 +123,17 @@ pygments_style = 'tango'
# A list of ignored prefixes for module index sorting.
#modindex_common_prefix = []
# -- Options breathe + doxygen -------------------------------------------------
breathe_projects = {"OpenMC": "../doxygen/xml"}
breathe_default_project = "OpenMC"
breathe_domain_by_file_pattern = {"*capi.h": "c"}
# -- Options for HTML output ---------------------------------------------------
# The theme to use for HTML and HTML Help pages
if not on_rtd:
import sphinx_rtd_theme
html_theme = 'sphinx_rtd_theme'
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
html_theme = 'sphinx_rtd_theme'
html_baseurl = "https://docs.openmc.org/en/stable/"
html_logo = '_images/openmc_logo.png'
@ -247,7 +257,7 @@ napoleon_use_ivar = True
intersphinx_mapping = {
'python': ('https://docs.python.org/3', None),
'numpy': ('https://numpy.org/doc/stable/', None),
'scipy': ('https://docs.scipy.org/doc/scipy/reference', None),
'scipy': ('https://docs.scipy.org/doc/scipy/', None),
'pandas': ('https://pandas.pydata.org/pandas-docs/stable/', None),
'matplotlib': ('https://matplotlib.org/', None)
'matplotlib': ('https://matplotlib.org/stable/', None)
}

View file

@ -0,0 +1,104 @@
.. _devguide_agentic_tools:
===========================
Agentic Development Tools
===========================
OpenMC ships a set of tools designed for AI coding agents (such as
`Claude Code`_) that agents can use to navigate and understand the codebase.
.. _Claude Code: https://claude.ai/code
Motivation
----------
Agentic tools like Claude Code are skilled at using grep to navigate and
understand large code bases. However, grep can only find exact text matches —
it cannot discover code that is *conceptually* related but uses different
naming. Without a "global view" of the codebase that a human developer will
build up over time, the agent is generally blind to any file it hasn't
tokenized fully. While it can grep to see who else calls a function, it
remains blind if other areas might be related but not share identical naming
conventions.
This problem is mitigated somewhat by using a model with a longer context
window. OpenMC has somewhere around ~1 million tokens of C++ and ~1 million
tokens of python. While Claude Code in early 2026 only has a context window
of 200k tokens, beta versions have extended context windows of 1M tokens,
and it's not unreasonable to assume that models may be available in the near
future that greatly exceed these limits.
However, even assuming the entire repository can be fit within a context
window, there are several downsides to doing this.
`Model performance degrades significantly as context size increases`_.
Benchmark results are
greatly improved if the model has less garbage to pick through. Additionally, API usage
is typically billed as tokens in/out per turn. As the context file
grows these costs become much larger. As such, there is still significant
motivation to solving the above problem, so as to ensure only relevant
information is drawn into context so as to maximize model performance and
minimize costs.
Setup
-----
The tools are registered as an `MCP (Model Context Protocol)`_ server in
``.mcp.json`` at the repository root. AI agents that support MCP (such as
Claude Code) discover them automatically on session start. The underlying
Python scripts can also be run directly from the command line.
All tools run entirely locally — no API keys or external service accounts are
required. Python dependencies are installed automatically into an isolated
virtual environment at ``.claude/cache/.venv/`` on first use.
.. _Model performance degrades significantly as context size increases: https://www.anthropic.com/news/claude-opus-4-6
.. _MCP (Model Context Protocol): https://modelcontextprotocol.io
RAG Semantic Search
-------------------
The RAG (Retrieval-Augmented Generation) semantic search addresses this
problem — it finds code by meaning, not just text match, surfacing related code
across subsystems that ``grep`` would miss entirely. Two MCP tools are provided:
- **openmc_rag_search** — Given a natural-language query, returns the most
relevant code chunks with file paths, line numbers, and a preview. Can search
code, documentation, or both. Can also find code related to a given file.
- **openmc_rag_rebuild** — Rebuilds the search index. Should be called after
pulling new code or switching branches.
How it works
^^^^^^^^^^^^
The search pipeline runs entirely on your local CPU:
1. **Chunking.** All C++, Python, and RST files are split into overlapping
fixed-size windows (~1000 characters, 25% overlap). This ensures every line
of code appears in at least one chunk and most lines appear in two.
2. **Embedding.** Each chunk is embedded into a 384-dimensional vector using
the `all-MiniLM-L6-v2`_ sentence-transformer model (22 million parameters).
This model runs on CPU with no GPU required. No API key is needed — the
model weights are downloaded once from Hugging Face and cached locally.
3. **Indexing.** The vectors are stored in a local LanceDB_ database on disk.
Building the full index takes approximately 5 minutes on a machine with
10 CPU cores. The index is stored in ``.claude/cache/rag_index/`` and
persists across sessions.
4. **Searching.** Your query is embedded using the same model, and the closest
chunks are retrieved by vector similarity. Results include the file path,
line range, file type, similarity distance, and a text preview.
.. _all-MiniLM-L6-v2: https://huggingface.co/sentence-transformers/all-MiniLM-L6-v2
.. _LanceDB: https://lancedb.com
Requirements
^^^^^^^^^^^^
No system dependencies beyond **Python 3.12+** with ``pip``. An internet
connection is required on first use to download the Python packages and
embedding model weights; subsequent runs are fully offline. The Python packages
(``sentence-transformers``, ``lancedb``) and their dependencies (including
PyTorch, ~2GB) are installed automatically into an isolated virtual environment
on first use.

View file

@ -109,9 +109,10 @@ Leadership Team
The TC consists of the following individuals:
- `Paul Romano <https://github.com/paulromano>`_
- `Sterling Harper <https://github.com/smharper>`_
- `Patrick Shriwise <https://github.com/pshriwise>`_
- `Adam Nelson <https://github.com/nelsonag>`_
- `Benoit Forget <https://github.com/bforget>`_
- `Jonathan Shimwell <https://github.com/shimwell>`_
- `John Tramm <https://github.com/jtramm>`_
The Project Lead is Paul Romano.

View file

@ -5,21 +5,19 @@ Building Sphinx Documentation
=============================
In order to build the documentation in the ``docs`` directory, you will need to
have the `Sphinx <https://www.sphinx-doc.org/en/master/>`_ third-party Python
package. The easiest way to install Sphinx is via pip:
have the several third-party Python packages installed, including `Sphinx
<https://www.sphinx-doc.org/en/master/>`_. To install the necessary
prerequisites, provide the optional "docs" dependencies when installing OpenMC's
Python API. That is, from the root directory of the OpenMC repository:
.. code-block:: sh
pip install sphinx
python -m pip install ".[docs]"
Additionally, you will need several Sphinx extensions that can be installed
directly with pip:
.. code-block:: sh
pip install sphinx-numfig
pip install sphinxcontrib-katex
pip install sphinxcontrib-svg2pdfconverter
The OpenMC documentation also uses Doxygen to automatically generate its
C/C++ API documentation directly from the docstrings available in the source
code. You will need to have a working installation of Doxygen to generate the
documentation locally.
-----------------------------------
Building Documentation as a Webpage

View file

@ -45,12 +45,11 @@ Now you can run the following to create a `Docker container`_ called
This command will open an interactive shell running from within the
Docker container where you have access to use OpenMC.
.. note:: The ``docker run`` command supports many
`options <https://docs.docker.com/engine/reference/commandline/run/>`_
.. note:: The ``docker run`` command supports many options_
for spawning containers -- including `mounting volumes`_ from the
host filesystem -- which many users will find useful.
.. _Docker image: https://docs.docker.com/engine/reference/commandline/images/
.. _Docker image: https://docs.docker.com/get-started/docker-concepts/the-basics/what-is-an-image/
.. _Docker container: https://www.docker.com/resources/what-container
.. _options: https://docs.docker.com/engine/reference/commandline/run/
.. _mounting volumes: https://docs.docker.com/storage/volumes/
.. _options: https://docs.docker.com/reference/cli/docker/container/run/
.. _mounting volumes: https://docs.docker.com/engine/storage/volumes/

View file

@ -14,7 +14,9 @@ other related topics.
contributing
workflow
agentic-tools
styleguide
policies
tests
user-input
docbuild

View file

@ -0,0 +1,35 @@
.. _devguide_policies:
========
Policies
========
---------------------
Python Version Policy
---------------------
OpenMC follows the Scientific Python Ecosystem Coordination guidelines `SPEC 0
<https://scientific-python.org/specs/spec-0000/>`_ on minimum supported
versions, which recommends that support for Python versions be dropped 3 years
after their initial release.
-------------------
C++ Standard Policy
-------------------
C++ code in OpenMC must conform to the most recent C++ standard that is fully
supported in the `version of the gcc compiler
<https://gcc.gnu.org/projects/cxx-status.html>`_ that is distributed with the
oldest version of Ubuntu that is still within its `standard support period
<https://ubuntu.com/about/release-cycle>`_. Ubuntu 22.04 LTS will be supported
through April 2027 and is distributed with gcc 11.4.0, which fully supports the
C++17 standard.
--------------------
CMake Version Policy
--------------------
Similar to the C++ standard policy, the minimum supported version of CMake
corresponds to whatever version is distributed with the oldest version of Ubuntu
still within its standard support period. Ubuntu 22.04 LTS is distributed with
CMake 3.22.

View file

@ -29,6 +29,10 @@ whenever a file is saved. For example, `Visual Studio Code
<https://code.visualstudio.com/docs/cpp/cpp-ide#_code-formatting>`_ includes
support for running clang-format.
.. note::
OpenMC's CI uses `clang-format` version 18. A different version of `clang-format`
may produce different line changes and as a result fail the CI test.
Miscellaneous
-------------
@ -36,14 +40,15 @@ Follow the `C++ Core Guidelines`_ except when they conflict with another
guideline listed here. For convenience, many important guidelines from that
list are repeated here.
Conform to the C++14 standard.
Conform to the C++17 standard.
Always use C++-style comments (``//``) as opposed to C-style (``/**/``). (It
is more difficult to comment out a large section of code that uses C-style
comments.)
Do not use C-style casting. Always use the C++-style casts ``static_cast``,
``const_cast``, or ``reinterpret_cast``. (See `ES.49 <http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#es49-if-you-must-use-a-cast-use-a-named-cast>`_)
``const_cast``, or ``reinterpret_cast``. (See `ES.49
<https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#es49-if-you-must-use-a-cast-use-a-named-cast>`_)
Source Files
------------
@ -51,7 +56,7 @@ Source Files
Use a ``.cpp`` suffix for code files and ``.h`` for header files.
Header files should always use include guards with the following style (See
`SF.8 <http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#sf8-use-include-guards-for-all-h-files>`_):
`SF.8 <https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rs-guards>`_):
.. code-block:: C++
@ -142,7 +147,7 @@ Style for Python code should follow PEP8_.
Docstrings for functions and methods should follow numpydoc_ style.
Python code should work with Python 3.7+.
Python code should work with Python 3.8+.
Use of third-party Python packages should be limited to numpy_, scipy_,
matplotlib_, pandas_, and h5py_. Use of other third-party packages must be
@ -152,11 +157,11 @@ Prefer pathlib_ when working with filesystem paths over functions in the os_
module or other standard-library modules. Functions that accept arguments that
represent a filesystem path should work with both strings and Path_ objects.
.. _C++ Core Guidelines: http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines
.. _PEP8: https://www.python.org/dev/peps/pep-0008/
.. _C++ Core Guidelines: https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines
.. _PEP8: https://peps.python.org/pep-0008/
.. _numpydoc: https://numpydoc.readthedocs.io/en/latest/format.html
.. _numpy: https://numpy.org/
.. _scipy: https://www.scipy.org/
.. _scipy: https://scipy.org/
.. _matplotlib: https://matplotlib.org/
.. _pandas: https://pandas.pydata.org/
.. _h5py: https://www.h5py.org/

View file

@ -23,25 +23,28 @@ Prerequisites
OpenMC in development/editable mode. With setuptools, this is accomplished by
running::
python setup.py develop
or using pip (recommended)::
pip install -e .[test]
python -m pip install -e .[test]
- The test suite requires a specific set of cross section data in order for
tests to pass. A download URL for the data that OpenMC expects can be found
within ``tools/ci/download-xs.sh``.
within ``tools/ci/download-xs.sh``. Once the tarball is downloaded and
unpacked, set the :envvar:`OPENMC_CROSS_SECTIONS` environment variable to the
path of the ``cross_sections.xml`` file within the unpacked data.
- In addition to the HDF5 data, some tests rely on ENDF files. A download URL
for those can also be found in ``tools/ci/download-xs.sh``.
for those can also be found in ``tools/ci/download-xs.sh``. Once the tarball
is downloaded and unpacked, set the :envvar:`OPENMC_ENDF_DATA` environment
variable to the top-level directory of the unpacked tarball.
- Some tests require `NJOY <https://www.njoy21.io/NJOY2016>`_ to preprocess
cross section data. The test suite assumes that you have an ``njoy``
executable available on your :envvar:`PATH`.
- OpenMC should be compiled with ``-DOPENMC_ENABLE_STRICT_FP=on`` to ensure
reproducible floating-point results across platforms and optimization levels.
Without this flag, regression tests may not match reference values.
Running Tests
-------------
To execute the test suite, go to the ``tests/`` directory and run::
To execute the Python test suite, go to the ``tests/`` directory and run::
pytest
@ -51,6 +54,65 @@ installed and run::
pytest --cov=../openmc --cov-report=html
To execute the C++ test suite, go to your build directory and run::
ctest
If you want to view testing output on failure run::
ctest --output-on-failure
Possible Reasons for Test Failures
----------------------------------
You may find that when you run the test suite, not everything passes. First,
make sure you have satisfied all the prerequisites above. After you have done
that, consider the following:
- When building OpenMC, make sure you run CMake with
``-DOPENMC_ENABLE_STRICT_FP=on``. This prevents the compiler from applying
floating-point optimizations (such as replacing math library calls with
builtins or contracting multiply-add into FMA instructions) that can produce
bit-level differences across platforms and optimization levels. Any
``CMAKE_BUILD_TYPE`` can be used.
- Because tallies involve the sum of many floating point numbers, the
non-associativity of floating point numbers can result in different answers
especially when the number of threads is high (different order of operations).
Thus, if you are running on a CPU with many cores, you may need to limit the
number of OpenMP threads used. It is recommended to set the
:envvar:`OMP_NUM_THREADS` environment variable to 2.
- Recent versions of NumPy use instruction dispatch that may generate different
results depending the particular ISA that you are running on. To avoid issues,
you may need to disable AVX512 instructions. This can be done by setting the
:envvar:`NPY_DISABLE_CPU_FEATURES` environment variable to "AVX512F
AVX512_SKX". When NumPy/SciPy are built against OpenBLAS, you may also need to
limit the number of threads that OpenBLAS uses internally; this can be done by
setting the :envvar:`OPENBLAS_NUM_THREADS` environment variable to 1.
Debugging Tests in CI
---------------------
Tests can be debugged in CI using a feature called
`tmate <https://github.com/mxschmitt/action-tmate?tab=readme-ov-file#debug-your-github-actions-by-using-tmate>`_.
CI debugging can be
enabled by including "[gha-debug]" in the commit message. When the test fails, a
link similar to the one shown below will be provided in the GitHub Actions
output after failure occurs. Logging into the provided link will allow you to
debug the test in the CI environment. The following is an example of the output
shown in the CI log that provides the link to the tmate session:
.. code-block:: text
:linenos:
Created new session successfully
ssh 2VcykjU7vNdvAzEjQcc839GM2@nyc1.tmate.io
https://tmate.io/t/2VcykjU7vNdvAzEjQcc839GM2
Entering main loop
Web shell: https://tmate.io/t/2VcykjU7vNdvAzEjQcc839GM2
SSH: ssh 2VcykjU7vNdvAzEjQcc839GM2@nyc1.tmate.io
...
Generating XML Inputs
---------------------
@ -62,6 +124,23 @@ run::
pytest --build-inputs <name-of-test>
Adding C++ Unit Tests
---------------------
The C++ test suite uses Catch2 integrated with CTest. Each header file should
have a corresponding test file in ``tests/cpp_unit_tests/``. If the test file
does not exist run::
touch test_<name-of-header-file>.cpp
The file must be added to the CMake build system in
``tests/cpp_unit_tests/CMakeLists.txt``. ``test_<name-of-header-file>`` should
be added to ``TEST_NAMES``.
To add a test case to ``test_<name-of-header-file>.cpp`` ensure
``catch2/catch_test_macros.hpp`` is included. A unit test can then be added
using the ``TEST_CASE`` macro and the ``REQUIRE`` assertion from Catch2.
Adding Tests to the Regression Suite
------------------------------------
@ -84,6 +163,12 @@ following files to your new test directory:
compiler options during openmc configuration and build (e.g., no MPI, no
debug/optimization).
For tests using the Python API, both the **inputs_true.dat** and
**results_true.dat** files can be generated automatically in the correct format
via::
pytest --update <name-of-test>
In addition to this description, please see the various types of tests that are
already included in the test suite to see how to create them. If all is
implemented correctly, the new test will automatically be discovered by pytest.

View file

@ -55,6 +55,6 @@ developer or send a message to the `developers mailing list`_.
.. _property attribute: https://docs.python.org/3.6/library/functions.html#property
.. _XML Schema Part 2: http://www.w3.org/TR/xmlschema-2/
.. _boolean: http://www.w3.org/TR/xmlschema-2/#boolean
.. _XML Schema Part 2: https://www.w3.org/TR/xmlschema-2/
.. _boolean: https://www.w3.org/TR/xmlschema-2/#boolean
.. _developers mailing list: https://groups.google.com/forum/?fromgroups=#!forum/openmc-dev

View file

@ -91,6 +91,30 @@ features and bug fixes. The general steps for contributing are as follows:
6. After the pull request has been thoroughly vetted, it is merged back into the
*develop* branch of openmc-dev/openmc.
Setting Up Upstream Tracking (Required for Versioning)
------------------------------------------------------
By default, your fork **does not** include tags from the upstream OpenMC repository.
OpenMC relies on `git describe --tags` for versioning in source builds, and missing tags can lead
to incorrect version detection (i.e., ``0.0.0``). To ensure proper versioning, follow these steps:
1. **Add the Upstream Repository**
This allows you to fetch updates from the main OpenMC repository.
.. code-block:: sh
git remote add upstream https://github.com/openmc-dev/openmc.git
2. **Fetch and Push Tags**
Retrieve tags from the upstream repository and update your fork:
.. code-block:: sh
git fetch --tags upstream
git push --tags origin
This ensures that both your **local** and **remote** fork have the correct versioning information.
Private Development
-------------------
@ -116,7 +140,7 @@ pip_. From the root directory of the OpenMC repository, run:
.. code-block:: sh
pip install -e .[test]
python -m pip install -e .[test]
This installs the OpenMC Python package in `"editable" mode
<https://pip.pypa.io/en/stable/cli/pip_install/#editable-installs>`_ so that 1)
@ -126,10 +150,10 @@ reinstalling it). While the same effect can be achieved using the
:envvar:`PYTHONPATH` environment variable, this is generally discouraged as it
can interfere with virtual environments.
.. _git: http://git-scm.com/
.. _git: https://git-scm.com/
.. _GitHub: https://github.com/
.. _git flow: https://nvie.com/git-model
.. _valgrind: https://www.valgrind.org/
.. _valgrind: https://valgrind.org/
.. _style guide: https://docs.openmc.org/en/latest/devguide/styleguide.html
.. _pull request: https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/about-pull-requests
.. _openmc-dev/openmc: https://github.com/openmc-dev/openmc

View file

@ -12,7 +12,7 @@ files produced by NJOY. Parallelism is enabled via a hybrid MPI and OpenMP
programming model.
OpenMC was originally developed by members of the `Computational Reactor Physics
Group <http://crpg.mit.edu>`_ at the `Massachusetts Institute of Technology
Group <https://crpg.mit.edu>`_ at the `Massachusetts Institute of Technology
<https://web.mit.edu>`_ starting in 2011. Various universities, laboratories,
and other organizations now contribute to the development of OpenMC. For more
information on OpenMC, feel free to post a message on the `OpenMC Discourse

View file

@ -0,0 +1,46 @@
.. _io_collision_track:
===========================
Collision Track File Format
===========================
When collision tracking is enabled with ``mcpl=false`` (the default), OpenMC
writes binary data to an HDF5 file named ``collision_track.h5``. The same data
may also be written after each batch when multiple files are requested
(``collision_track.N.h5``) or when the run is performed in parallel. The file
contains the information needed to reconstruct each recorded collision.
The current revision of the collision track file format is 1.2.
**/**
:Attributes:
- **filetype** (*char[]*) -- String indicating the type of file.
For collision-track files the value is ``"collision_track"``.
:Datasets:
- **collision_track_bank** (Compound type) -- Collision information
for each stored event. Each entry in the dataset corresponds to one
collision and contains the following fields:
- ``r`` (*double[3]*) -- Position of the collision in [cm].
- ``u`` (*double[3]*) -- Direction unit vector immediately after the collision.
- ``E`` (*double*) -- Incident particle energy before the collision in [eV].
- ``dE`` (*double*) -- Energy loss over the collision (:math:`E_\text{before} - E_\text{after}`) in [eV].
- ``time`` (*double*) -- Time of the collision in [s].
- ``wgt`` (*double*) -- Particle weight at the collision.
- ``event_mt`` (*int*) -- ENDF MT number identifying the reaction.
- ``delayed_group`` (*int*) -- Delayed neutron group index (non-zero for delayed events).
- ``cell_id`` (*int*) -- ID of the cell in which the collision occurred.
- ``nuclide_id`` (*int*) -- PDG number of the nuclide (100ZZZAAAM).
- ``material_id`` (*int*) -- ID of the material containing the collision site.
- ``universe_id`` (*int*) -- ID of the universe containing the collision site.
- ``n_collision`` (*int*) -- Collision counter for the particle history.
- ``particle`` (*int32_t*) -- Particle type (PDG number).
- ``parent_id`` (*int64_t*) -- Unique ID of the parent particle.
- ``progeny_id`` (*int64_t*) -- Progeny ID of the particle.
In an MPI run, OpenMC writes the combined dataset by gathering collision-track
entries from all ranks before flushing them to disk, so the final file appears
as though it were produced serially.

View file

@ -56,6 +56,27 @@ attributes:
.. _io_chain_reaction:
--------------------
``<source>`` Element
--------------------
The ``<source>`` element represents photon and electron sources associated with
the decay of a nuclide and contains information to construct an
:class:`openmc.stats.Univariate` object that represents this emission as an
energy distribution. This element has the following attributes:
:type:
The type of :class:`openmc.stats.Univariate` source term.
:particle:
The type of particle emitted, e.g., 'photon' or 'electron'
:parameters:
The parameters of the source term, e.g., for a
:class:`openmc.stats.Discrete` source, the energies (in [eV]) at which the
particles are emitted and their relative intensities in [Bq/atom] (in other
words, decay constants).
----------------------
``<reaction>`` Element
----------------------

View file

@ -4,7 +4,7 @@
Depletion Results File Format
=============================
The current version of the depletion results file format is 1.1.
The current version of the depletion results file format is 1.3.
**/**
@ -12,30 +12,31 @@ The current version of the depletion results file format is 1.1.
- **version** (*int[2]*) -- Major and minor version of the
statepoint file format.
:Datasets: - **eigenvalues** (*double[][][2]*) -- k-eigenvalues at each
time/stage. This array has shape (number of timesteps, number of
stages, value). The last axis contains the eigenvalue and the
associated uncertainty
- **number** (*double[][][][]*) -- Total number of atoms. This array
has shape (number of timesteps, number of stages, number of
:Datasets: - **eigenvalues** (*double[][2]*) -- k-eigenvalues at each timestep.
This array has shape (number of timesteps, 2). The second axis
contains the eigenvalue and its associated uncertainty.
- **number** (*double[][][]*) -- Total number of atoms at each
timestep. This array has shape (number of timesteps, number of
materials, number of nuclides).
- **reaction rates** (*double[][][][][]*) -- Reaction rates used to
build depletion matrices. This array has shape (number of
timesteps, number of stages, number of materials, number of
nuclides, number of reactions).
- **reaction rates** (*double[][][][]*) -- Reaction rates at each
timestep. This array has shape (number of timesteps, number of
materials, number of nuclides, number of reactions). Only stored if
write_rates=True.
- **time** (*double[][2]*) -- Time in [s] at beginning/end of each
step.
- **source_rate** (*double[][]*) -- Power in [W] or source rate in
[neutron/sec]. This array has shape (number of timesteps, number
of stages).
- **source_rate** (*double[]*) -- Power in [W] or source rate in
[neutron/sec] for each timestep.
- **depletion time** (*double[]*) -- Average process time in [s]
spent depleting a material across all burnable materials and,
if applicable, MPI processes.
- **keff_search_root** (*double[]*) -- Root of the keff search at the
end of the timestep, if applicable.
**/materials/<id>/**
:Attributes: - **index** (*int*) -- Index used in results for this material
- **volume** (*double*) -- Volume of this material in [cm^3]
- **name** (*char[]*) -- Name of this material
**/nuclides/<name>/**
@ -47,10 +48,3 @@ The current version of the depletion results file format is 1.1.
**/reactions/<name>/**
:Attributes: - **index** (*int*) -- Index user in results for this reaction
.. note::
The reaction rates for some isotopes not originally present may
be non-zero, but should be negligible compared to other atoms.
This can be controlled by changing the
:class:`openmc.deplete.Operator` ``dilute_initial`` attribute.

View file

@ -38,11 +38,9 @@ Each ``<surface>`` element can have the following attributes or sub-elements:
:boundary:
The boundary condition for the surface. This can be "transmission",
"vacuum", "reflective", or "periodic". Periodic boundary conditions can
only be applied to x-, y-, and z-planes. Only axis-aligned periodicity is
supported, i.e., x-planes can only be paired with x-planes. Specify which
planes are periodic and the code will automatically identify which planes
are paired together.
"vacuum", "reflective", or "periodic". Specify which planes are
periodic and the code will automatically identify which planes are
paired together.
*Default*: "transmission"
@ -318,9 +316,10 @@ the following attributes or sub-elements:
*Default*: None
:orientation:
The orientation of the hexagonal lattice. The string "x" indicates that two
sides of the lattice are parallel to the x-axis, whereas the string "y"
indicates that two sides are parallel to the y-axis.
The orientation of the hexagonal lattice. The string "x" indicates that each
lattice element has two faces that are perpendicular to the x-axis, whereas
the string "y" indicates that each lattice element has two faces that are
perpendicular to the y-axis.
*Default*: "y"
@ -407,13 +406,64 @@ Each ``<dagmc_universe>`` element can have the following attributes or sub-eleme
*Default*: None
:cell:
Zero or more ``<cell>`` sub-elements may appear to override properties of
individual DAGMC volumes. Each ``<cell>`` element supports the following
attributes and sub-elements:
.. note:: A geometry.xml file containing only a DAGMC model for a file named `dagmc.h5m` (no CSG)
looks as follows
:id:
The integer cell ID in the DAGMC geometry to override. Required.
.. code-block:: xml
:name:
An optional string label for the cell.
<?xml version='1.0' encoding='utf-8'?>
<geometry>
<dagmc_universe filename="dagmc.h5m" id="1" />
</geometry>
*Default*: None
:material:
The material ID to assign to this cell. Use ``void`` for vacuum. Multiple
space-separated IDs may be given to specify a distribmat (distributed
material) assignment. Required.
:temperature:
Temperature(s) in [K] to assign to the cell. Must be greater than or equal
to 0. Multiple space-separated values may be given.
*Default*: None
:density:
Density in [g/cm³] to assign to the cell. Must be greater than 0. Requires a non-void
material fill. Multiple space-separated values may be given.
*Default*: None
:volume:
Volume of the cell in [cm³].
.. note:: DAGMC can compute cell volumes exactly from the triangulated
mesh surfaces. Specifying a manual volume risks inconsistency
with that capability.
*Default*: None
The following standard ``<cell>`` attributes are **not** supported inside
``<dagmc_universe>`` and will raise an error if present: ``region``,
``fill``, ``universe``, ``translation``, ``rotation``.
.. deprecated::
The ``<material_overrides>`` sub-element (containing ``<cell_override>``
children with ``<material_ids>``) is deprecated. A deprecation warning is
emitted and the overrides are converted to the ``<cell>`` format at parse
time. It is an error to specify both ``<material_overrides>`` and
``<cell>`` sub-elements on the same ``<dagmc_universe>``.
*Default*: None
.. note:: A geometry.xml file containing only a DAGMC model for a file named
`dagmc.h5m` (no CSG) looks as follows:
.. code-block:: xml
<?xml version='1.0' encoding='utf-8'?>
<geometry>
<dagmc_universe filename="dagmc.h5m" id="1" />
</geometry>

View file

@ -44,6 +44,7 @@ Output Files
statepoint
source
collision_track
summary
properties
depletion_results
@ -51,3 +52,4 @@ Output Files
track
voxel
volume
weight_windows

View file

@ -133,6 +133,10 @@ Temperature-dependent data, provided for temperature <TTT>K.
This dataset is optional. This is a 1-D vector if `representation`
is "isotropic", or a 3-D vector if `representation` is "angle"
with dimensions of [polar][azimuthal][groups].
When this data is not available, an approximation using the
group energy boundaries is used. For more information see
the particle speed subsection in the multigroup-data section
of the theory manual.
**/<library name>/<TTT>K/scatter_data/**

View file

@ -4,7 +4,7 @@
Particle Restart File Format
============================
The current version of the particle restart file format is 2.0.
The current version of the particle restart file format is 2.1.
**/**
@ -26,6 +26,7 @@ The current version of the particle restart file format is 2.0.
- **run_mode** (*char[]*) -- Run mode used, either 'fixed source',
'eigenvalue', or 'particle restart'.
- **id** (*int8_t*) -- Unique identifier of the particle.
- **type** (*int32_t*) -- Particle type (PDG number)
- **weight** (*double*) -- Weight of the particle.
- **energy** (*double*) -- Energy of the particle in eV for
continuous-energy mode, or the energy group of the particle for

View file

@ -7,13 +7,18 @@ Geometry Plotting Specification -- plots.xml
Basic plotting capabilities are available in OpenMC by creating a plots.xml file
and subsequently running with the ``--plot`` command-line flag. The root element
of the plots.xml is simply ``<plots>`` and any number output plots can be
defined with ``<plot>`` sub-elements. Two plot types are currently implemented
defined with ``<plot>`` sub-elements. Four plot types are currently implemented
in openMC:
* ``slice`` 2D pixel plot along one of the major axes. Produces a PNG image
file.
* ``voxel`` 3D voxel data dump. Produces an HDF5 file containing voxel xyz
position and cell or material id.
* ``wireframe_raytrace`` 2D pixel plot of a three-dimensional view of a
geometry using wireframes around cells or materials and coloring by depth
through each material.
* ``solid_raytrace`` 2D pixel plot of a three-dimensional view of a geometry
with solid colored surfaces of a set of cells or materials.
------------------
@ -66,21 +71,22 @@ sub-elements:
*Default*: None - Required entry
:type:
Keyword for type of plot to be produced. Currently only "slice" and "voxel"
plots are implemented. The "slice" plot type creates 2D pixel maps saved in
the PNG file format. The "voxel" plot type produces a binary datafile
containing voxel grid positioning and the cell or material (specified by the
``color`` tag) at the center of each voxel. Voxel plot files can be
processed into VTK files using the :ref:`scripts_voxel` script provided with
OpenMC and subsequently viewed with a 3D viewer such as VISIT or Paraview.
See the :ref:`io_voxel` for information about the datafile structure.
Keyword for type of plot to be produced. Currently "slice", "voxel",
"wireframe_raytrace", and "solid_raytrace" plots are implemented. The
"slice" plot type creates 2D pixel maps saved in the PNG file format. The
"voxel" plot type produces a binary datafile containing voxel grid
positioning and the cell or material (specified by the ``color`` tag) at the
center of each voxel. Voxel plot files can be processed into VTK files using
the :func:`openmc.voxel_to_vtk` function and subsequently viewed with a 3D
viewer such as VISIT or Paraview. See :ref:`io_voxel` for information about
the datafile structure.
.. note:: High-resolution voxel files produced by OpenMC can be quite large,
but the equivalent VTK files will be significantly smaller.
*Default*: "slice"
``<plot>`` elements of ``type`` "slice" and "voxel" must contain the ``pixels``
All ``<plot>`` elements must contain the ``pixels``
attribute or sub-element:
:pixels:
@ -96,7 +102,7 @@ attribute or sub-element:
``width``/``pixels`` along that basis direction may not appear
in the plot.
*Default*: None - Required entry for "slice" and "voxel" plots
*Default*: None - Required entry for all plots
``<plot>`` elements of ``type`` "slice" can also contain the following
attributes or sub-elements. These are not used in "voxel" plots:
@ -125,6 +131,11 @@ attributes or sub-elements. These are not used in "voxel" plots:
Specifies the custom color for the cell or material. Should be 3 integers
separated by spaces.
:xs:
The attenuation coefficient for volume rendering of color in units of
inverse centimeters. Zero corresponds to transparency. Only for plot type
"wireframe_raytrace".
As an example, if your plot is colored by material and you want material 23
to be blue, the corresponding ``color`` element would look like:
@ -151,6 +162,18 @@ attributes or sub-elements. These are not used in "voxel" plots:
*Default*: 255 255 255 (white)
:show_overlaps:
Indicates whether overlapping regions of different cells are shown.
*Default*: None
:overlap_color:
Specifies the RGB color of overlapping regions of different cells. Does not
do anything if ``show_overlaps`` is "false" or not specified. Should be 3
integers separated by spaces.
*Default*: 255 0 0 (red)
:meshlines:
The ``meshlines`` sub-element allows for plotting the boundaries of a
regular mesh on top of a plot. Only one ``meshlines`` element is allowed per
@ -179,3 +202,80 @@ attributes or sub-elements. These are not used in "voxel" plots:
*Default*: 0 0 0 (black)
*Default*: None
``<plot>`` elements of ``type`` "wireframe_raytrace" or "solid_raytrace" can contain the
following attributes or sub-elements.
:camera_position:
Location in 3D Cartesian space the camera is at.
*Default*: None - Required for all ``wireframe_raytrace`` or
``solid_raytrace`` plots
:look_at:
Location in 3D Cartesian space the camera is looking at.
*Default*: None - Required for all ``wireframe_raytrace`` or
``solid_raytrace`` plots
:field_of_view:
The horizontal field of view in degrees. Defaults to roughly the same value
as for the human eye.
*Default*: 70
:orthographic_width:
If set to a nonzero value, an orthographic rather than perspective
projection for the camera is employed. An orthographic projection puts out
parallel rays from the camera of a width prescribed here in the horizontal
direction, with the width in the vertical direction decided by the pixel
aspect ratio.
*Default*: 0
``<plot>`` elements of ``type`` "solid_raytrace" can contain the following attributes or
sub-elements.
:opaque_ids:
List of integer IDs of cells or materials to be treated as visible in the
plot. Whether the integers are interpreted as cell or material IDs depends
on ``color_by``.
*Default*: None - Required for all phong plots
:light_position:
Location in 3D Cartesian space of the light.
*Default*: Same location as ``camera_position``
:diffuse_fraction:
Fraction of light originating from non-directional sources. If set to one,
the coloring is not influenced by surface curvature, and no shadows appear.
If set to zero, only regions illuminated by the light are not black.
*Default*: 0.1
``<plot>`` elements of ``type`` "wireframe_raytrace" can contain the following
attributes or sub-elements.
:wireframe_color:
RGB value of the wireframe's color
*Default*: 0, 0, 0 (black)
:wireframe_thickness:
Integer number of pixels that the wireframe takes up. The value is a radius
of the wireframe. Setting to zero removes any wireframing.
*Default*: 0
:wireframe_ids:
Integer IDs of cells or materials of regions to draw wireframes around.
Whether the integers are interpreted as cell or material IDs depends on
``color_by``.
*Default*: None

View file

@ -4,7 +4,7 @@
Properties File Format
======================
The current version of the properties file format is 1.0.
The current version of the properties file format is 1.1.
**/**
@ -25,6 +25,7 @@ The current version of the properties file format is 1.0.
**/geometry/cells/cell <uid>/**
:Datasets: - **temperature** (*double[]*) -- Temperature of the cell in [K].
- **density** (*double[]*) -- Density of the cell in [g/cm3].
**/materials/**

File diff suppressed because it is too large Load diff

View file

@ -15,6 +15,8 @@ following the same format.
**/**
:Attributes: - **filetype** (*char[]*) -- String indicating the type of file.
- **version** (*int[2]*) -- Major and minor version of the source
file format.
:Datasets:
@ -22,5 +24,5 @@ following the same format.
particle. The compound type has fields ``r``, ``u``, ``E``,
``time``, ``wgt``, ``delayed_group``, ``surf_id`` and ``particle``,
which represent the position, direction, energy, time, weight,
delayed group, surface ID, and particle type (0=neutron, 1=photon,
2=electron, 3=positron), respectively.
delayed group, surface ID, and particle type (PDG number),
respectively.

View file

@ -4,7 +4,7 @@
State Point File Format
=======================
The current version of the statepoint file format is 17.0.
The current version of the statepoint file format is 18.2.
**/**
@ -23,6 +23,7 @@ The current version of the statepoint file format is 17.0.
bank is present (1) or not (0).
:Datasets: - **seed** (*int8_t*) -- Pseudo-random number generator seed.
- **stride** (*uint64_t*) -- Pseudo-random number generator stride.
- **energy_mode** (*char[]*) -- Energy mode of the run, either
'continuous-energy' or 'multi-group'.
- **run_mode** (*char[]*) -- Run mode used, either 'eigenvalue' or
@ -55,8 +56,8 @@ The current version of the statepoint file format is 17.0.
``time``, ``wgt``, ``delayed_group``, ``surf_id``, and
``particle``, which represent the position, direction, energy,
time, weight, delayed group, surface ID, and particle type
(0=neutron, 1=photon, 2=electron, 3=positron), respectively. Only
present when `run_mode` is 'eigenvalue'.
(PDG number), respectively. Only present when `run_mode` is
'eigenvalue'.
**/tallies/**
@ -68,21 +69,39 @@ The current version of the statepoint file format is 17.0.
:Attributes: - **n_meshes** (*int*) -- Number of meshes in the problem.
- **ids** (*int[]*) -- User-defined unique ID of each mesh.
.. _mesh-spec-hdf5:
**/tallies/meshes/mesh <uid>/**
:Datasets: - **type** (*char[]*) -- Type of mesh.
:Attributes: - **id** (*int*) -- ID of the mesh
:Datasets: - **name** (*char[]*) -- Name of the mesh.
- **type** (*char[]*) -- Type of mesh.
- **dimension** (*int*) -- Number of mesh cells in each dimension.
- **lower_left** (*double[]*) -- Coordinates of lower-left corner of
mesh.
- **upper_right** (*double[]*) -- Coordinates of upper-right corner
of mesh.
- **width** (*double[]*) -- Width of each mesh cell in each
dimension.
- **Regular Mesh Only:**
- **lower_left** (*double[]*) -- Coordinates of lower-left corner of
mesh.
- **upper_right** (*double[]*) -- Coordinates of upper-right corner
of mesh.
- **width** (*double[]*) -- Width of each mesh cell in each
dimension.
- **Rectilinear Mesh Only:**
- **x_grid** (*double[]*) -- Mesh divisions along the x-axis.
- **y_grid** (*double[]*) -- Mesh divisions along the y-axis.
- **z_grid** (*double[]*) -- Mesh divisions along the z-axis.
- **Cylindrical & Spherical Mesh Only:**
- **r_grid** (*double[]*) -- The mesh divisions along the r-axis.
- **phi_grid** (*double[]*) -- The mesh divisions along the phi-axis.
- **origin** (*double[]*) -- The origin in cartesian coordinates.
- **Spherical Mesh Only:**
- **theta_grid** (*double[]*) -- The mesh divisions along the theta-axis.
- **Unstructured Mesh Only:**
- **filename** (*char[]*) -- Name of the mesh file.
- **library** (*char[]*) -- Mesh library used to represent the
mesh ("moab" or "libmesh").
- **length_multiplier** (*double*) Scaling factor applied to the mesh.
- **options** (*char[]*) -- Special options that control spatial
search data structures used.
- **volumes** (*double[]*) -- Volume of each mesh cell.
- **vertices** (*double[]*) -- x, y, z values of the mesh vertices.
- **connectivity** (*int[]*) -- Connectivity array for the mesh
@ -128,6 +147,10 @@ The current version of the statepoint file format is 17.0.
- **internal** (*int*) -- Flag indicating the presence of tally
data (0) or absence of tally data (1). All user defined
tallies will have a value of 0 unless otherwise instructed.
- **multiply_density** (*int*) -- Flag indicating whether reaction
rates should be multiplied by atom density (1) or not (0).
- **higher_moments** (*int*) -- Flag indicating whether
higher-order tally moments are enabled (1) or not (0).
:Datasets: - **n_realizations** (*int*) -- Number of realizations.
- **n_filters** (*int*) -- Number of filters used.

View file

@ -4,7 +4,7 @@
Summary File Format
===================
The current version of the summary file format is 6.0.
The current version of the summary file format is 6.1.
**/**
@ -38,6 +38,7 @@ The current version of the summary file format is 6.0.
is an array if the cell uses distributed materials, otherwise it is
a scalar.
- **temperature** (*double[]*) -- Temperature of the cell in Kelvin.
- **density** (*double[]*) -- Density of the cell in [g/cm3].
- **translation** (*double[3]*) -- Translation applied to the fill
universe. This dataset is present only if fill_type is set to
'universe'.
@ -60,9 +61,11 @@ The current version of the summary file format is 6.0.
- **coefficients** (*double[]*) -- Array of coefficients that define
the surface. See :ref:`surface_element` for what coefficients are
defined for each surface type.
- **boundary_condition** (*char[]*) -- Boundary condition applied to
the surface. Can be 'transmission', 'vacuum', 'reflective', or
'periodic'.
- **boundary_type** (*char[]*) -- Boundary condition applied to
the surface. Can be 'transmission', 'vacuum', 'reflective',
'periodic', or 'white'.
- **albedo** (*double*) -- Boundary albedo as a positive multiplier
of particle weight. If absent, it is assumed to be 1.0.
- **geom_type** (*char[]*) -- Type of geometry used to create the cell.
Either 'csg' or 'dagmc'.

View file

@ -69,6 +69,12 @@ The ``<tally>`` element accepts the following sub-elements:
list of valid scores can be found in the :ref:`user's guide
<usersguide_scores>`.
:multiply_density:
A boolean that indicates whether reaction rate scores should be computed by
multiplying by the atom density of a nuclide present in a material.
*Default*: true
:trigger:
Precision trigger applied to all filter bins and nuclides for this tally.
It must specify the trigger's type, threshold and scores to which it will
@ -94,6 +100,18 @@ The ``<tally>`` element accepts the following sub-elements:
*Default*: None
:ignore_zeros:
Whether to allow zero tally bins to be ignored when assessing the
convergece of the precision trigger. If True, only nonzero tally scores
will be compared to the trigger's threshold.
.. note:: The ``ignore_zeros`` option can cause the tally trigger to fire
prematurely if there are no hits in any bins at the first
evalulation. It is the user's responsibility to specify enough
particles per batch to get a nonzero score in at least one bin.
*Default*: False
:scores:
The score(s) in this tally to which the trigger should be applied.
@ -124,9 +142,9 @@ attributes/sub-elements:
:type:
The type of the filter. Accepted options are "cell", "cellfrom",
"cellborn", "surface", "material", "universe", "energy", "energyout", "mu",
"polar", "azimuthal", "mesh", "distribcell", "delayedgroup",
"energyfunction", and "particle".
"cellborn", "surface", "material", "universe", "energy", "energyout",
"mu", "polar", "azimuthal", "mesh", "distribcell", "delayedgroup",
"energyfunction", "particle", and "particleproduction".
:bins:
A description of the bins for each type of filter can be found in
@ -300,8 +318,34 @@ should be set to:
they use ``energy`` and ``y``.
:particle:
A list of integers indicating the type of particles to tally ('neutron' = 1,
'photon' = 2, 'electron' = 3, 'positron' = 4).
A list of particle identifiers to tally, specified as strings (e.g.,
``neutron``, ``photon``, ``He4``) or as integer PDG numbers.
:particleproduction:
This filter tallies secondary particles produced in reactions, binned by
particle type and, optionally, by energy. Unlike other energy filters, the
weight applied is the weight of the secondary particle. To obtain secondary
particle production rates, use this filter with the ``events`` score.
The filter uses the following sub-elements instead of ``bins``:
:particles:
A space-separated list of secondary particle types to tally (e.g.,
``photon``, ``neutron``, ``electron``).
:energies:
An optional monotonically increasing list of energy boundaries in [eV]
for binning the secondary particle energies. If omitted, total production
is tallied without energy binning.
For example, to tally photon and neutron production in three energy groups:
.. code-block:: xml
<filter id="1" type="particleproduction">
<particles>photon neutron</particles>
<energies>0.0 1.0e5 1.0e6 20.0e6</energies>
</filter>
------------------
``<mesh>`` Element
@ -311,6 +355,11 @@ If a mesh is desired as a filter for a tally, it must be specified in a separate
element with the tag name ``<mesh>``. This element has the following
attributes/sub-elements:
:name:
An optional string name to identify the mesh in output files.
*Default*: ""
:type:
The type of mesh. This can be either "regular", "rectilinear",
"cylindrical", "spherical", or "unstructured".
@ -351,10 +400,17 @@ attributes/sub-elements:
:theta_grid:
The mesh divisions along the theta-axis. (For spherical mesh only.)
:origin:
The origin in cartesian coordinates. (For cylindrical and spherical meshes only.)
:library:
The mesh library used to represent an unstructured mesh. This can be either
"moab" or "libmesh". (For unstructured mesh only.)
:options:
Special options that control spatial search data structures used. (For
unstructured mesh using MOAB only)
:filename:
The name of the mesh file to be loaded at runtime. (For unstructured mesh
only.)

View file

@ -4,7 +4,7 @@
Track File Format
=================
The current revision of the particle track file format is 3.0.
The current revision of the particle track file format is 3.1.
**/**
@ -32,6 +32,5 @@ The current revision of the particle track file format is 3.0.
the array for each primary/secondary particle. The
last offset should match the total size of the
array.
- **particles** (*int[]*) -- Particle type for each
primary/secondary particle (0=neutron, 1=photon,
2=electron, 3=positron).
- **particles** (*int32_t[]*) -- Particle type for
each primary/secondary particle (PDG number).

View file

@ -0,0 +1,39 @@
.. _io_weight_windows:
====================
Weight Window Format
====================
The current revision of the weight window file format is 1.0.
**/**
:Attributes: - **filetype** (*char[]*) -- String indicating the type of file.
- **version** (*int[2]*) -- Major and minor version of the weight
window file format.
**/weight_windows/**
:Attributes: - **n_weight_windows** (*int*) -- Number of weight window objects in the file.
- **ids** (*int[]*) -- Unique IDs of weight window objects in the file.
**/weight_windows/weight_windows_<uid>/**
:Datasets: - **mesh** (*int*) -- ID of the mesh associated with the weight window object.
- **particle_type** (*char[]*) -- Particle type to which the weight windows apply.
- **energy_bounds** (*double[]*) -- Energy bounds of the weight windows in [eV]
- **lower_ww_bounds** (*double[]*) -- Weight window lower bounds.
- **upper_ww_bounds** (*double[]*) -- Weight window upper bounds.
- **survival_ratio** (*double*) -- Weight window survival ratio.
- **max_lower_bound_ratio** (*double*) -- Maximum particle weight to lower weight window bound ratio.
- **max_split** (*int*) -- Maximum number of splits per weight window check.
- **weight_cutoff** (*double*) -- Particle weight cutoff.
**/meshes/**
:Attributes: - **n_meshes** (*int*) -- Number of meshes in the file.
- **ids** (*int[]*) -- User-defined unique ID of each mesh.
**/meshes/mesh <uid>/**
Please see the section on **/tallies/meshes/** in the :doc:`statepoint`.

View file

@ -4,7 +4,7 @@
License Agreement
=================
Copyright © 2011-2022 Massachusetts Institute of Technology, UChicago Argonne
Copyright © 2011-2026 Massachusetts Institute of Technology, UChicago Argonne
LLC, and OpenMC contributors
Permission is hereby granted, free of charge, to any person obtaining a copy of

View file

@ -0,0 +1,362 @@
.. _methods_charged_particle_physics:
========================
Charged Particle Physics
========================
OpenMC neglects the spatial transport of charged particles (electrons and
positrons), assuming they deposit all their energy locally and produce
bremsstrahlung photons at their birth location. This approximation, called
thick-target bremsstrahlung (TTB) approximation is justified by the fact that
charged particles have much shorter stopping ranges compared to neutrons and
photons, especially in high-density materials.
-----------------------------
Charged Particle Interactions
-----------------------------
Bremsstrahlung
--------------
When a charged particle is decelerated in the field of an atom, some of its
kinetic energy is converted into electromagnetic radiation known as
bremsstrahlung, or 'braking radiation'. In each event, an electron or positron
with kinetic energy :math:`T` generates a photon with an energy :math:`E`
between :math:`0` and :math:`T`. Bremsstrahlung is described by a cross section
that is differential in photon energy, in the direction of the emitted photon,
and in the final direction of the charged particle. However, in Monte Carlo
simulations it is typical to integrate over the angular variables to obtain a
single differential cross section with respect to photon energy, which is often
expressed in the form
.. math::
:label: bremsstrahlung-dcs
\frac{d\sigma_{\text{br}}}{dE} = \frac{Z^2}{\beta^2} \frac{1}{E}
\chi(Z, T, \kappa),
where :math:`\kappa = E/T` is the reduced photon energy and :math:`\chi(Z, T,
\kappa)` is the scaled bremsstrahlung cross section, which is experimentally
measured.
Because electrons are attracted to atomic nuclei whereas positrons are
repulsed, the cross section for positrons is smaller, though it approaches that
of electrons in the high energy limit. To obtain the positron cross section, we
multiply :eq:`bremsstrahlung-dcs` by the :math:`\kappa`-independent factor used
in Salvat_,
.. math::
:label: positron-factor
\begin{aligned}
F_{\text{p}}(Z,T) =
& 1 - \text{exp}(-1.2359\times 10^{-1}t + 6.1274\times 10^{-2}t^2 - 3.1516\times 10^{-2}t^3 \\
& + 7.7446\times 10^{-3}t^4 - 1.0595\times 10^{-3}t^5 + 7.0568\times 10^{-5}t^6 \\
& - 1.8080\times 10^{-6}t^7),
\end{aligned}
where
.. math::
:label: positron-factor-t
t = \ln\left(1 + \frac{10^6}{Z^2}\frac{T}{\text{m}_\text{e}c^2} \right).
:math:`F_{\text{p}}(Z,T)` is the ratio of the radiative stopping powers for
positrons and electrons. Stopping power describes the average energy loss per
unit path length of a charged particle as it passes through matter:
.. math::
:label: stopping-power
-\frac{dT}{ds} = n \int E \frac{d\sigma}{dE} dE \equiv S(T),
where :math:`n` is the number density of the material and :math:`d\sigma/dE` is
the cross section differential in energy loss. The total stopping power
:math:`S(T)` can be separated into two components: the radiative stopping
power :math:`S_{\text{rad}}(T)`, which refers to energy loss due to
bremsstrahlung, and the collision stopping power :math:`S_{\text{col}}(T)`,
which refers to the energy loss due to inelastic collisions with bound
electrons in the material that result in ionization and excitation. The
radiative stopping power for electrons is given by
.. math::
:label: radiative-stopping-power
S_{\text{rad}}(T) = n \frac{Z^2}{\beta^2} T \int_0^1 \chi(Z,T,\kappa)
d\kappa.
To obtain the radiative stopping power for positrons,
:eq:`radiative-stopping-power` is multiplied by :eq:`positron-factor`.
While the models for photon interactions with matter described above can safely
assume interactions occur with free atoms, sampling the target atom based on
the macroscopic cross sections, molecular effects cannot necessarily be
disregarded for charged particle treatment. For compounds and mixtures, the
bremsstrahlung cross section is calculated using Bragg's additivity rule as
.. math::
:label: material-bremsstrahlung-dcs
\frac{d\sigma_{\text{br}}}{dE} = \frac{1}{\beta^2 E} \sum_i \gamma_i Z^2_i
\chi(Z_i, T, \kappa),
where the sum is over the constituent elements and :math:`\gamma_i` is the
atomic fraction of the :math:`i`-th element. Similarly, the radiative stopping
power is calculated using Bragg's additivity rule as
.. math::
:label: material-radiative-stopping-power
S_{\text{rad}}(T) = \sum_i w_i S_{\text{rad},i}(T),
where :math:`w_i` is the mass fraction of the :math:`i`-th element and
:math:`S_{\text{rad},i}(T)` is found for element :math:`i` using
:eq:`radiative-stopping-power`. The collision stopping power, however, is a
function of certain quantities such as the mean excitation energy :math:`I` and
the density effect correction :math:`\delta_F` that depend on molecular
properties. These quantities cannot simply be summed over constituent elements
in a compound, but should instead be calculated for the material. The Bethe
formula can be used to find the collision stopping power of the material:
.. math::
:label: material-collision-stopping-power
S_{\text{col}}(T) = \frac{2 \pi r_e^2 m_e c^2}{\beta^2} N_A \frac{Z}{A_M}
[\ln(T^2/I^2) + \ln(1 + \tau/2) + F(\tau) - \delta_F(T)],
where :math:`N_A` is Avogadro's number, :math:`A_M` is the molar mass,
:math:`\tau = T/m_e`, and :math:`F(\tau)` depends on the particle type. For
electrons,
.. math::
:label: F-electron
F_{-}(\tau) = (1 - \beta^2)[1 + \tau^2/8 - (2\tau + 1) \ln2],
while for positrons
.. math::
:label: F-positron
F_{+}(\tau) = 2\ln2 - (\beta^2/12)[23 + 14/(\tau + 2) + 10/(\tau + 2)^2 +
4/(\tau + 2)^3].
The density effect correction :math:`\delta_F` takes into account the reduction
of the collision stopping power due to the polarization of the material the
charged particle is passing through by the electric field of the particle.
It can be evaluated using the method described by Sternheimer_, where the
equation for :math:`\delta_F` is
.. math::
:label: density-effect-correction
\delta_F(\beta) = \sum_{i=1}^n f_i \ln[(l_i^2 + l^2)/l_i^2] -
l^2(1-\beta^2).
Here, :math:`f_i` is the oscillator strength of the :math:`i`-th transition,
given by :math:`f_i = n_i/Z`, where :math:`n_i` is the number of electrons in
the :math:`i`-th subshell. The frequency :math:`l` is the solution of the
equation
.. math::
:label: density-effect-l
\frac{1}{\beta^2} - 1 = \sum_{i=1}^{n} \frac{f_i}{\bar{\nu}_i^2 + l^2},
where :math:`\bar{v}_i` is defined as
.. math::
:label: density-effect-nubar
\bar{\nu}_i = h\nu_i \rho / h\nu_p.
The plasma energy :math:`h\nu_p` of the medium is given by
.. math::
:label: plasma-frequency
h\nu_p = \sqrt{\frac{(hc)^2 r_e \rho_m N_A Z}{\pi A}},
where :math:`A` is the atomic weight and :math:`\rho_m` is the density of the
material. In :eq:`density-effect-nubar`, :math:`h\nu_i` is the oscillator
energy, and :math:`\rho` is an adjustment factor introduced to give agreement
between the experimental values of the oscillator energies and the mean
excitation energy. The :math:`l_i` in :eq:`density-effect-correction` are
defined as
.. math::
:label: density-effect-li
\begin{aligned}
l_i &= (\bar{\nu}_i^2 + 2/3f_i)^{1/2} ~~~~&\text{for}~~ \bar{\nu}_i > 0 \\
l_n &= f_n^{1/2} ~~~~&\text{for}~~ \bar{\nu}_n = 0,
\end{aligned}
where the second case applies to conduction electrons. For a conductor,
:math:`f_n` is given by :math:`n_c/Z`, where :math:`n_c` is the effective
number of conduction electrons, and :math:`v_n = 0`. The adjustment factor
:math:`\rho` is determined using the equation for the mean excitation energy:
.. math::
:label: mean-excitation-energy
\ln I = \sum_{i=1}^{n-1} f_i \ln[(h\nu_i\rho)^2 + 2/3f_i(h\nu_p)^2]^{1/2} +
f_n \ln (h\nu_pf_n^{1/2}).
.. _ttb:
Thick-Target Bremsstrahlung Approximation
+++++++++++++++++++++++++++++++++++++++++
Since charged particles lose their energy on a much shorter distance scale than
neutral particles, not much error should be introduced by neglecting to
transport electrons. However, the bremsstrahlung emitted from high energy
electrons and positrons can travel far from the interaction site. Thus, even
without a full electron transport mode it is necessary to model bremsstrahlung.
We use a thick-target bremsstrahlung (TTB) approximation based on the models in
Salvat_ and Kaltiaisenaho_ for generating bremsstrahlung photons, which assumes
the charged particle loses all its energy in a single homogeneous material
region.
To model bremsstrahlung using the TTB approximation, we need to know the number
of photons emitted by the charged particle and the energy distribution of the
photons. These quantities can be calculated using the continuous slowing down
approximation (CSDA). The CSDA assumes charged particles lose energy
continuously along their trajectory with a rate of energy loss equal to the
total stopping power, ignoring fluctuations in the energy loss. The
approximation is useful for expressing average quantities that describe how
charged particles slow down in matter. For example, the CSDA range approximates
the average path length a charged particle travels as it slows to rest:
.. math::
:label: csda-range
R(T) = \int^T_0 \frac{dT'}{S(T')}.
Actual path lengths will fluctuate around :math:`R(T)`. The average number of
photons emitted per unit path length is given by the inverse bremsstrahlung
mean free path:
.. math::
:label: inverse-bremsstrahlung-mfp
\lambda_{\text{br}}^{-1}(T,E_{\text{cut}})
= n\int_{E_{\text{cut}}}^T\frac{d\sigma_{\text{br}}}{dE}dE
= n\frac{Z^2}{\beta^2}\int_{\kappa_{\text{cut}}}^1\frac{1}{\kappa}
\chi(Z,T,\kappa)d\kappa.
The lower limit of the integral in :eq:`inverse-bremsstrahlung-mfp` is non-zero
because the bremsstrahlung differential cross section diverges for small photon
energies but is finite for photon energies above some cutoff energy
:math:`E_{\text{cut}}`. The mean free path
:math:`\lambda_{\text{br}}^{-1}(T,E_{\text{cut}})` is used to calculate the
photon number yield, defined as the average number of photons emitted with
energy greater than :math:`E_{\text{cut}}` as the charged particle slows down
from energy :math:`T` to :math:`E_{\text{cut}}`. The photon number yield is
given by
.. math::
:label: photon-number-yield
Y(T,E_{\text{cut}}) = \int^{R(T)}_{R(E_{\text{cut}})}
\lambda_{\text{br}}^{-1}(T',E_{\text{cut}})ds = \int_{E_{\text{cut}}}^T
\frac{\lambda_{\text{br}}^{-1}(T',E_{\text{cut}})}{S(T')}dT'.
:math:`Y(T,E_{\text{cut}})` can be used to construct the energy spectrum of
bremsstrahlung photons: the number of photons created with energy between
:math:`E_1` and :math:`E_2` by a charged particle with initial kinetic energy
:math:`T` as it comes to rest is given by :math:`Y(T,E_1) - Y(T,E_2)`.
To simulate the emission of bremsstrahlung photons, the total stopping power
and bremsstrahlung differential cross section for positrons and electrons must
be calculated for a given material using :eq:`material-bremsstrahlung-dcs` and
:eq:`material-radiative-stopping-power`. These quantities are used to build the
tabulated bremsstrahlung energy PDF and CDF for that material for each incident
energy :math:`T_k` on the energy grid. The following algorithm is then applied
to sample the photon energies:
1. For an incident charged particle with energy :math:`T`, sample the number of
emitted photons as
.. math::
N = \lfloor Y(T,E_{\text{cut}}) + \xi_1 \rfloor.
2. Rather than interpolate the PDF between indices :math:`k` and :math:`k+1`
for which :math:`T_k < T < T_{k+1}`, which is computationally expensive, use
the composition method and sample from the PDF at either :math:`k` or
:math:`k+1`. Using linear interpolation on a logarithmic scale, the PDF can
be expressed as
.. math::
p_{\text{br}}(T,E) = \pi_k p_{\text{br}}(T_k,E) + \pi_{k+1}
p_{\text{br}}(T_{k+1},E),
where the interpolation weights are
.. math::
\pi_k = \frac{\ln T_{k+1} - \ln T}{\ln T_{k+1} - \ln T_k},~~~
\pi_{k+1} = \frac{\ln T - \ln T_k}{\ln T_{k+1} - \ln T_k}.
Sample either the index :math:`i = k` or :math:`i = k+1` according to the
point probabilities :math:`\pi_{k}` and :math:`\pi_{k+1}`.
3. Determine the maximum value of the CDF :math:`P_{\text{br,max}}`.
3. Sample the photon energies using the inverse transform method with the
tabulated CDF :math:`P_{\text{br}}(T_i, E)` i.e.,
.. math::
E = E_j \left[ (1 + a_j) \frac{\xi_2 P_{\text{br,max}} -
P_{\text{br}}(T_i, E_j)} {E_j p_{\text{br}}(T_i, E_j)} + 1
\right]^{\frac{1}{1 + a_j}}
where the interpolation factor :math:`a_j` is given by
.. math::
a_j = \frac{\ln p_{\text{br}}(T_i,E_{j+1}) - \ln p_{\text{br}}(T_i,E_j)}
{\ln E_{j+1} - \ln E_j}
and :math:`P_{\text{br}}(T_i, E_j) \le \xi_2 P_{\text{br,max}} \le
P_{\text{br}}(T_i, E_{j+1})`.
We ignore the range of the electron or positron, i.e., the bremsstrahlung
photons are produced in the same location that the charged particle was
created. The direction of the photons is assumed to be the same as the
direction of the incident charged particle, which is a reasonable approximation
at higher energies when the bremsstrahlung radiation is emitted at small
angles.
Electron-Positron Annihilation
------------------------------
When a positron collides with an electron, both particles are annihilated and
generally two photons with equal energy are created. If the kinetic energy of
the positron is high enough, the two photons can have different energies, and
the higher-energy photon is emitted preferentially in the direction of flight
of the positron. It is also possible to produce a single photon if the
interaction occurs with a bound electron, and in some cases three (or, rarely,
even more) photons can be emitted. However, the annihilation cross section is
largest for low-energy positrons, and as the positron energy decreases, the
angular distribution of the emitted photons becomes isotropic.
In OpenMC, we assume the most likely case in which a low-energy positron (which
has already lost most of its energy to bremsstrahlung radiation) interacts with
an electron which is free and at rest. Two photons with energy equal to the
electron rest mass energy :math:`m_e c^2 = 0.511` MeV are emitted isotropically
in opposite directions.
.. _Kaltiaisenaho: https://aaltodoc.aalto.fi/bitstream/handle/123456789/21004/master_Kaltiaisenaho_Toni_2016.pdf
.. _Salvat: https://doi.org/10.1787/32da5043-en
.. _Sternheimer: https://doi.org/10.1103/PhysRevB.26.6067

View file

@ -178,6 +178,27 @@ been selected. There are three methods available:
section data is loaded for a single temperature and is used in the
unresolved resonance and fast energy ranges.
------------------
NCrystal materials
------------------
As an alternative of the standard thermal scattering treatment using
:math:`S(\alpha,\beta)` tables, OpenMC allows to create materials using
NCrystal_. In addition to the regular thermal elastic, and thermal inelastic
processes, NCrystal allows the generation of models for materials that cannot
currently included in ACE files such as oriented single crystals (see the
`NCrystal paper`_), and further extend the physics `using plugins`_. Thermal
scattering kernels are generated on the fly from dynamic and structural data, or
loaded from :math:`S(\alpha,\beta)` tables converted from ENDF6 evaluations.
These kernels are sampled in a direct way using a fast `rejection algorithm`_
that does not require previous processing. A `large library`_ of materials is
already included in the NCrystal distribution, and new materials can be easily
defined from scratch in the `NCMAT format`_ or `combining existing files`_.
The compositions of the materials defined in NCrystal are passed on to OpenMC
all other reactions except for thermal neutron scattering are handled by
continuous energy ACE libraries.
----------------
Multi-Group Data
----------------
@ -268,14 +289,63 @@ sections. This allows flexibility for the model to use highly anisotropic
scattering information in the water while the fuel can be simulated with linear
or even isotropic scattering.
Particle Speed
--------------
When using a multigroup representation of cross sections, the particle speed has
meaning only in an average sense. The particle speed is important when modeling
dynamic behavior. OpenMC calculates the particle speed using the inverse
velocity multigroup data if it is available. If such data is not available,
OpenMC uses an approximate velocity using the group energy bounds in the
following way:
.. math::
\frac{1}{v_g} = \int_{E_{\text{min}}^g}^{E_{\text{max}}^g} \frac{1}{v(E)} \frac{\alpha}{E} dE
Where :math:`E_{\text{min}}^g` and :math:`E_{\text{max}}^g` are the group energy
boundaries for group :math:`g`. :math:`v(E)` is the neutron velocity calculated
using relativistic kinematics, :math:`\alpha` is a normalization constant for the
:math:`\frac{1}{E}` spectrum.
This equation is valid when inside the group boundaries the neutron spectrum
follows a typical :math:`\frac{1}{E}` slowing down spectrum. This assumption is
widely used when generating fine group neutron cross section data libraries from
continuous energy data.
The solution to this equation is:
.. math::
\frac{1}{v_g} = \frac{1}{c \log\left(\frac{E_{\text{max}}^g}{E_{\text{min}}^g}\right)}
\left[ 2(\operatorname{arctanh}(k_{\text{max}}^{-1}) - \operatorname{arctanh}(k_{\text{min}}^{-1}))
- (k_{\text{max}}-k_{\text{min}}) \right]
where :math:`c` is the speed of light and :math:`k_{\text{max}}`,
:math:`k_{\text{min}}` are defined by a change of variables:
.. math::
k = \sqrt{1+\frac{2 m_n c^2}{E}}
where :math:`E` is the particle kinetic energy and :math:`m_n` is the neutron
rest mass.
.. _logarithmic mapping technique:
https://laws.lanl.gov/vhosts/mcnp.lanl.gov/pdf_files/la-ur-14-24530.pdf
https://mcnp.lanl.gov/pdf_files/TechReport_2014_LANL_LA-UR-14-24530_Brown.pdf
.. _Hwang: https://doi.org/10.13182/NSE87-A16381
.. _Josey: https://doi.org/10.1016/j.jcp.2015.08.013
.. _WMP Library: https://github.com/mit-crpg/WMP_Library
.. _MCNP: https://mcnp.lanl.gov
.. _Serpent: http://montecarlo.vtt.fi
.. _NJOY: https://www.njoy21.io/NJOY21/
.. _Serpent: https://serpent.vtt.fi
.. _NJOY: https://www.njoy21.io/
.. _ENDF/B data: https://www.nndc.bnl.gov/endf-b8.0/
.. _Leppanen: https://doi.org/10.1016/j.anucene.2009.03.019
.. _algorithms: http://ab-initio.mit.edu/wiki/index.php/Faddeeva_Package
.. _algorithms: http://ab-initio.mit.edu/faddeeva/
.. _NCrystal: https://github.com/mctools/ncrystal
.. _NCrystal paper: https://doi.org/10.1016/j.cpc.2019.07.015
.. _using plugins: https://doi.org/10.1016/j.cpc.2021.108082
.. _rejection algorithm: https://doi.org/10.1016/j.jcp.2018.11.043
.. _large library: https://github.com/mctools/ncrystal/wiki/Data-library
.. _NCMAT format: https://github.com/mctools/ncrystal/wiki/NCMAT-format
.. _combining existing files: https://github.com/mctools/ncrystal/wiki/Announcement-Release3.0.0#2-multiphase-materials

View file

@ -114,7 +114,7 @@ The predictor method only requires one evaluation and its error converges as
twice as expensive as the predictor method, but achieves an error of
:math:`\mathcal{O}(h^2)`. An exhaustive description of time integration methods
and their merits can be found in the `thesis of Colin Josey
<http://dspace.mit.edu/handle/1721.1/7582>`_.
<https://dspace.mit.edu/handle/1721.1/7582>`_.
OpenMC does not rely on a single time integration method but rather has several
classes that implement different algorithms. For example, the
@ -257,3 +257,85 @@ choose one of two methods for estimating the heating rate, including:
The method for normalization can be chosen through the ``normalization_mode``
argument to the :class:`openmc.deplete.CoupledOperator` class.
--------------
Transfer Rates
--------------
OpenMC allows continuous removal or feed of nuclides by adding an
extra transfer rate term to the depletion matrix. An application of this feature
is the chemical processing of Molten Salt Reactors (MSRs), where one can
model the removal of fission products or feeding fresh fuel into the system.
A transfer rate as defined here is the rate at which nuclides are
continuously removed/fed from/to a material.
.. note::
A transfer rate can be positive or negative, indicating removal or feed
respectively.
Mathematically, it can be thought of as an additional term :math:`\mathbf{T}`
in the depletion equation that is proportional to the nuclide density, which can be written as:
.. math::
\begin{aligned}\frac{dN_i(t)}{dt} = &\underbrace{\sum\limits_j f_{j\rightarrow i}
\int_0^\infty dE \; \sigma_j (E,t) \phi(E,t) N_j(t) - \int_0^\infty dE \; \sigma_i(E,t)
\phi(E,t) N_i(t)}_\textbf{R} \\
&+ \underbrace{\sum_j \left [ \lambda_{j\rightarrow i} N_j(t) - \lambda_{i\rightarrow j} N_i(t) \right ]}_\textbf{D} \\
&- \underbrace{t_i N_i(t)}_\textbf{T} \end{aligned}
where the reaction term :math:`\mathbf{R}`, the decay term :math:`\mathbf{D}`
and the new transfer term :math:`\mathbf{T}` have been grouped together so that
:math:`\mathbf{A} = \mathbf{R}+\mathbf{D}-\mathbf{T}`.
The transfer rate coefficient :math:`t_i` defines the continuous transfer of the
nuclide :math:`i`, which behaves similar to radioactive decay.
:math:`t_i` can also be defined as the reciprocal of a cycle time
:math:`T_{cyc}`, intended as the time needed to process the whole inventory.
Note that this formulation assumes homogeneous distribution of nuclide
:math:`i` throughout the material.
A more rigorous description of removal rate and its implementation can be found
in the paper by `Hombourger
<https://doi.org/10.1016/j.anucene.2020.107504>`_.
The resulting burnup matrix can be solved with the same integration algorithms
that are used in the absence of the transfer term.
.. note::
If no ``destination_material`` is specified, nuclides that are removed
or fed will not be tracked afterwards.
Coupling materials
------------------
To keep track of removed nuclides or to feed nuclides from one depletable material
to another, the respective depletion equations have to be coupled. This can be
achieved by defining one block matrix, with diagonal blocks corresponding to
depletion matrices :math:`\mathbf{A_{ii}}`, where the index :math:`i` indicates
the depletable material id, and off-diagonal blocks corresponding to inter-material
coupling matrices :math:`\mathbf{T_{ij}}`, positioned so that that the indices :math:`i` and
:math:`j` indicate the nuclides receiving and losing materials, respectively.
The nuclide vectors are assembled together in one single vector and the resulting
system is solved with the same integration algorithms seen before.
As an example, consider the case of two depletable materials and one
transfer defined from material 1 to material 2. The final system will look like:
.. math::
\begin{aligned}\frac{d}{dt}\begin{pmatrix}\vec{N_1}\\ \vec{N_2}\end{pmatrix} &=
\begin{pmatrix}\mathbf{A_{11}} & \mathbf{0}\\ \mathbf{T_{21}} & \mathbf{A_{22 }}
\end{pmatrix} \begin{pmatrix}\vec{N_1}\\ \vec{N_2}\end{pmatrix} \end{aligned}
where:
:math:`\mathbf{A_{11}} = \mathbf{R_{11}}+\mathbf{D_{11}}-\mathbf{T_{21}}`, and
:math:`\mathbf{A_{22}} = \mathbf{R_{22}}+\mathbf{D_{22}}`.
Note that mass conservation is guaranteed by transferring the number
of atoms directly.

View file

@ -55,15 +55,17 @@ in :ref:`fission-bank-algorithms`.
Source Convergence Issues
-------------------------
.. _methods-shannon-entropy:
Diagnosing Convergence with Shannon Entropy
-------------------------------------------
As discussed earlier, it is necessary to converge both :math:`k_{eff}` and the
source distribution before any tallies can begin. Moreover, the convergence rate
of the source distribution is in general slower than that of
:math:`k_{eff}`. One should thus examine not only the convergence of
:math:`k_{eff}` but also the convergence of the source distribution in order to
make decisions on when to start active batches.
of the source distribution is in general slower than that of :math:`k_{eff}`.
One should thus examine not only the convergence of :math:`k_{eff}` but also the
convergence of the source distribution in order to make decisions on when to
start active batches.
However, the representation of the source distribution makes it a bit more
difficult to analyze its convergence. Since :math:`k_{eff}` is a scalar
@ -108,6 +110,13 @@ at plots of :math:`k_{eff}` and the Shannon entropy. A number of methods have
been proposed (see e.g. [Romano]_, [Ueki]_), but each of these is not without
problems.
Shannon entropy is calculated differently for the random ray solver, as
described :ref:`in the random ray theory section
<methods-shannon-entropy-random-ray>`. Additionally, as the Shannon entropy only
serves as a diagnostic tool for convergence of the fission source distribution,
there is currently no diagnostic to determine if the scattering source
distribution in random ray is converged.
---------------------------
Uniform Fission Site Method
---------------------------
@ -142,7 +151,7 @@ than unity. By ensuring that the expected number of fission sites in each mesh
cell is constant, the collision density across all cells, and hence the variance
of tallies, is more uniform than it would be otherwise.
.. _Shannon entropy: https://laws.lanl.gov/vhosts/mcnp.lanl.gov/pdf_files/la-ur-06-3737.pdf
.. _Shannon entropy: https://mcnp.lanl.gov/pdf_files/TechReport_2006_LANL_LA-UR-06-3737_Brown.pdf
.. [Lieberoth] J. Lieberoth, "A Monte Carlo Technique to Solve the Static
Eigenvalue Problem of the Boltzmann Transport Equation," *Nukleonik*, **11**,

View file

@ -25,19 +25,38 @@ KERMA (Kinetic Energy Release in Materials) [Mack97]_ coefficients for reaction
:math:`\times` cross-section (e.g., eV-barn) and can be used much like a reaction
cross section for the purpose of tallying energy deposition.
KERMA coefficients can be computed using the energy-balance method with
a nuclear data processing code like NJOY, which performs the following
iteration over all reactions :math:`r` for all isotopes :math:`i`
requested
KERMA coefficients can be computed using the energy-balance method with a
nuclear data processing code like NJOY, which estimates the KERMA coefficients
using the following equation:
.. math::
k_{i, r}(E) = \left(E + Q_{i, r} - \bar{E}_{i, r, n}
k_{i, r}(E) = \left(E + Q_{i, r} - \sum\limits_x \bar{E}_{i, r, x}
\right)\sigma_{i, r}(E),
where the summation is over each secondary particle type :math:`x`. This
equation states that the energy deposited is equal to the energy of the incident
particle plus the reaction :math:`Q` value less the energy of secondary
particles that are transported away from the reaction site. For neutron
interactions, the energy-balance KERMA coefficient is
.. math::
k_{i, r}(E) = \left(E + Q_{i, r} - \sum\limits_x \bar{E}_{i, r, n}
- \bar{E}_{i, r, \gamma}\right)\sigma_{i, r}(E),
removing the energy of neutral particles (neutrons and photons) that are
transported away from the reaction site :math:`\bar{E}`, and the reaction
:math:`Q` value.
where :math:`\bar{E}_{i, r, n}` is the average energy of secondary neutrons and
:math:`\bar{E}_{i, r, \gamma}` is the average energy of secondary photons. For
photon and charged particle interactions the KERMA coefficient is
.. math::
:label: energy-balance-photon
k_{i, r}(E) = \left(E + Q_{i, r} - \sum\limits_x \bar{E}_{i, r, x}
\right)\sigma_{i, r}(E).
where the :math:`Q` value is zero for all interactions except for pair
production and positron annihilation.
-------
Fission
@ -120,7 +139,7 @@ run with :math:`N918` reflecting fission heating computed from NJOY.
This modified heating data is stored as the MT=901 reaction and will be scored
if ``heating-local`` is included in :attr:`openmc.Tally.scores`.
Coupled neutron-photon transport
Coupled Neutron-Photon Transport
--------------------------------
Here, OpenMC instructs ``heatr`` to assume that energy from photons is not
@ -138,6 +157,50 @@ Let :math:`N301` represent the total heating number returned from this
This modified heating data is stored as the MT=301 reaction and will be scored
if ``heating`` is included in :attr:`openmc.Tally.scores`.
Photons and Charged Particles
-----------------------------
In OpenMC, energy deposition from photons or charged particles is scored using
the energy balance method based on Equation :eq:`energy-balance-photon`. Special
consideration is given to electrons and positrons as described below.
+++++++++++++++++
Charged Particles
+++++++++++++++++
OpenMC tracks photons interaction by interaction so the energy deposited in each
collision is easily attributed back to the nuclide and reaction for which the
photon interacted with. Charged particles (electrons and photons) aren't tracked
in the same way. For charged particles, OpenMC assumes that all their energy
(less the energy of bremsstrahlung radiation) is deposited in the material in
which they were born. In this way it is harder to trace how much energy should
be attributed in each nuclide.
According to the CSDA approximation (see :ref:`ttb`) the energy deposited by a
charged particle with kinetic energy :math:`T` in the :math:`i`-th element can
be calculated as:
.. math::
E_{i} = \int_{0}^{R(T)} w_{i}S_{\text{col,i}} dx
where :math:`R(T)` is the CSDA range of the charged particle,
:math:`S_{\text{col},i}` is the collision stopping power of the charged particle
in the :math:`i`-th element and :math:`w_i` is the mass fraction of the
:math:`i`-th element. According to the Bethe formula the collision stopping
power of the :math:`i`-th element is proportional to :math:`Z_i/A_i`, so the
fractional collision stopping power from the :math:`i`-th element is:
.. math::
\frac{w_{i}S_{\text{col},i}(T)}{S_{\text{col}}(T)} =
\frac{\frac{w_{i}Z_{i}}{A_{i}}}{\sum_{i}\frac{w_{i}Z_{i}}{A_{i}}} =
\frac{\gamma_i Z_{i}}{\sum_{i}\gamma_i Z_{i}}.
where :math:`\gamma_i` is the atomic fraction of the :math:`i`-th element.
Therefore, the energy deposited by charged particles should be attributed to
a given element according to its fractional charge density.
----------
References
----------

View file

@ -1066,5 +1066,5 @@ surface is known as in :ref:`reflection`.
.. _constructive solid geometry: https://en.wikipedia.org/wiki/Constructive_solid_geometry
.. _surfaces: https://en.wikipedia.org/wiki/Surface
.. _MCNP: https://mcnp.lanl.gov
.. _Serpent: http://montecarlo.vtt.fi
.. _Serpent: https://serpent.vtt.fi
.. _Monte Carlo Performance benchmark: https://github.com/mit-crpg/benchmarks/tree/master/mc-performance/openmc

View file

@ -14,9 +14,12 @@ Theory and Methodology
random_numbers
neutron_physics
photon_physics
charged_particles_physics
tallies
eigenvalue
depletion
energy_deposition
parallelization
cmfd
variance_reduction
random_ray

View file

@ -91,7 +91,7 @@ inelastic scattering reactions. The specific multi-group scattering
implementation is discussed in the :ref:`multi-group-scatter` section.
Elastic scattering refers to the process by which a neutron scatters off a
nucleus and does not leave it in an excited. It is referred to as "elastic"
nucleus and does not leave it in an excited state. It is referred to as "elastic"
because in the center-of-mass system, the neutron does not actually lose
energy. However, in lab coordinates, the neutron does indeed lose
energy. Elastic scattering can be treated exactly in a Monte Carlo code thanks
@ -290,7 +290,10 @@ create and store fission sites for the following generation. First, the average
number of prompt and delayed neutrons must be determined to decide whether the
secondary neutrons will be prompt or delayed. This is important because delayed
neutrons have a markedly different spectrum from prompt neutrons, one that has a
lower average energy of emission. The total number of neutrons emitted
lower average energy of emission. Furthermore, in simulations where tracking
time of neutrons is important, we need to consider the emission time delay of
the secondary neutrons, which is dependent on the decay constant of the
delayed neutron precursor. The total number of neutrons emitted
:math:`\nu_t` is given as a function of incident energy in the ENDF format. Two
representations exist for :math:`\nu_t`. The first is a polynomial of order
:math:`N` with coefficients :math:`c_0,c_1,\dots,c_N`. If :math:`\nu_t` has this
@ -306,8 +309,8 @@ interpolation law. The number of prompt neutrons released per fission event
:math:`\nu_p` is also given as a function of incident energy and can be
specified in a polynomial or tabular format. The number of delayed neutrons
released per fission event :math:`\nu_d` can only be specified in a tabular
format. In practice, we only need to determine :math:`nu_t` and
:math:`nu_d`. Once these have been determined, we can calculated the delayed
format. In practice, we only need to determine :math:`\nu_t` and
:math:`\nu_d`. Once these have been determined, we can calculate the delayed
neutron fraction
.. math::
@ -335,8 +338,14 @@ neutrons. Otherwise, we produce :math:`\lfloor \nu \rfloor + 1` neutrons. Then,
for each fission site produced, we sample the outgoing angle and energy
according to the algorithms given in :ref:`sample-angle` and
:ref:`sample-energy` respectively. If the neutron is to be born delayed, then
there is an extra step of sampling a delayed neutron precursor group since they
each have an associated secondary energy distribution.
there is an extra step of sampling a delayed neutron precursor group to get the
associated secondary energy distribution and the decay constant
:math:`\lambda`, which is needed to sample the emission delay time :math:`t_d`:
.. math::
:label: sample-delay-time
t_d = -\frac{\ln \xi}{\lambda}.
The sampled outgoing angle and energy of fission neutrons along with the
position of the collision site are stored in an array called the fission
@ -1743,19 +1752,19 @@ types.
.. _Watt fission spectrum: https://doi.org/10.1103/PhysRev.87.1037
.. _Foderaro: http://hdl.handle.net/1721.1/1716
.. _Foderaro: https://dspace.mit.edu/handle/1721.1/1716
.. _OECD: https://www.oecd-nea.org/tools/abstract/detail/NEA-1792
.. _NJOY: https://www.njoy21.io/NJOY2016/
.. _PREPRO: https://www-nds.iaea.org/ndspub/endf/prepro/
.. _PREPRO: https://www-nds.iaea.org/public/endf/prepro/
.. _ENDF-6 Format: https://www.oecd-nea.org/dbdata/data/manual-endf/endf102.pdf
.. _Monte Carlo Sampler: https://permalink.lanl.gov/object/tr?what=info:lanl-repo/lareport/LA-09721-MS
.. _Monte Carlo Sampler: https://mcnp.lanl.gov/pdf_files/TechReport_1983_LANL_LA-9721-MS_EverettCashwell.pdf
.. _LA-UR-14-27694: https://permalink.lanl.gov/object/tr?what=info:lanl-repo/lareport/LA-UR-14-27694
.. _LA-UR-14-27694: https://www.osti.gov/biblio/1159204
.. _MC21: https://www.osti.gov/biblio/903083
@ -1763,6 +1772,4 @@ types.
.. _Sutton and Brown: https://www.osti.gov/biblio/307911
.. _lectures: https://laws.lanl.gov/vhosts/mcnp.lanl.gov/pdf_files/la-ur-05-4983.pdf
.. _MCNP Manual: https://laws.lanl.gov/vhosts/mcnp.lanl.gov/pdf_files/la-ur-03-1987.pdf
.. _lectures: https://mcnp.lanl.gov/pdf_files/TechReport_2005_LANL_LA-UR-05-4983_Brown.pdf

View file

@ -609,17 +609,17 @@ is actually independent of the number of nodes:
.. _first paper: https://doi.org/10.2307/2280232
.. _work of Forrest Brown: http://hdl.handle.net/2027.42/24996
.. _work of Forrest Brown: https://deepblue.lib.umich.edu/handle/2027.42/24996
.. _Brissenden and Garlick: https://doi.org/10.1016/0306-4549(86)90095-2
.. _MPICH: http://www.mpich.org
.. _MPICH: https://www.mpich.org
.. _binomial tree: https://www.mcs.anl.gov/~thakur/papers/ijhpca-coll.pdf
.. _Geary: https://doi.org/10.2307/2342070
.. _Barnett: http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.51.7772
.. _Barnett: https://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.51.7772
.. _single-instruction multiple-data: https://en.wikipedia.org/wiki/SIMD

View file

@ -667,342 +667,6 @@ and Auger electrons:
5. Repeat from step 1 for vacancy left by the transition electron.
Electron-Positron Annihilation
------------------------------
When a positron collides with an electron, both particles are annihilated and
generally two photons with equal energy are created. If the kinetic energy of
the positron is high enough, the two photons can have different energies, and
the higher-energy photon is emitted preferentially in the direction of flight
of the positron. It is also possible to produce a single photon if the
interaction occurs with a bound electron, and in some cases three (or, rarely,
even more) photons can be emitted. However, the annihilation cross section is
largest for low-energy positrons, and as the positron energy decreases, the
angular distribution of the emitted photons becomes isotropic.
In OpenMC, we assume the most likely case in which a low-energy positron (which
has already lost most of its energy to bremsstrahlung radiation) interacts with
an electron which is free and at rest. Two photons with energy equal to the
electron rest mass energy :math:`m_e c^2 = 0.511` MeV are emitted isotropically
in opposite directions.
Bremsstrahlung
--------------
When a charged particle is decelerated in the field of an atom, some of its
kinetic energy is converted into electromagnetic radiation known as
bremsstrahlung, or 'braking radiation'. In each event, an electron or positron
with kinetic energy :math:`T` generates a photon with an energy :math:`E`
between :math:`0` and :math:`T`. Bremsstrahlung is described by a cross section
that is differential in photon energy, in the direction of the emitted photon,
and in the final direction of the charged particle. However, in Monte Carlo
simulations it is typical to integrate over the angular variables to obtain a
single differential cross section with respect to photon energy, which is often
expressed in the form
.. math::
:label: bremsstrahlung-dcs
\frac{d\sigma_{\text{br}}}{dE} = \frac{Z^2}{\beta^2} \frac{1}{E}
\chi(Z, T, \kappa),
where :math:`\kappa = E/T` is the reduced photon energy and :math:`\chi(Z, T,
\kappa)` is the scaled bremsstrahlung cross section, which is experimentally
measured.
Because electrons are attracted to atomic nuclei whereas positrons are
repulsed, the cross section for positrons is smaller, though it approaches that
of electrons in the high energy limit. To obtain the positron cross section, we
multiply :eq:`bremsstrahlung-dcs` by the :math:`\kappa`-independent factor used
in Salvat_,
.. math::
:label: positron-factor
\begin{aligned}
F_{\text{p}}(Z,T) =
& 1 - \text{exp}(-1.2359\times 10^{-1}t + 6.1274\times 10^{-2}t^2 - 3.1516\times 10^{-2}t^3 \\
& + 7.7446\times 10^{-3}t^4 - 1.0595\times 10^{-3}t^5 + 7.0568\times 10^{-5}t^6 \\
& - 1.8080\times 10^{-6}t^7),
\end{aligned}
where
.. math::
:label: positron-factor-t
t = \ln\left(1 + \frac{10^6}{Z^2}\frac{T}{\text{m}_\text{e}c^2} \right).
:math:`F_{\text{p}}(Z,T)` is the ratio of the radiative stopping powers for
positrons and electrons. Stopping power describes the average energy loss per
unit path length of a charged particle as it passes through matter:
.. math::
:label: stopping-power
-\frac{dT}{ds} = n \int E \frac{d\sigma}{dE} dE \equiv S(T),
where :math:`n` is the number density of the material and :math:`d\sigma/dE` is
the cross section differential in energy loss. The total stopping power
:math:`S(T)` can be separated into two components: the radiative stopping
power :math:`S_{\text{rad}}(T)`, which refers to energy loss due to
bremsstrahlung, and the collision stopping power :math:`S_{\text{col}}(T)`,
which refers to the energy loss due to inelastic collisions with bound
electrons in the material that result in ionization and excitation. The
radiative stopping power for electrons is given by
.. math::
:label: radiative-stopping-power
S_{\text{rad}}(T) = n \frac{Z^2}{\beta^2} T \int_0^1 \chi(Z,T,\kappa)
d\kappa.
To obtain the radiative stopping power for positrons,
:eq:`radiative-stopping-power` is multiplied by :eq:`positron-factor`.
While the models for photon interactions with matter described above can safely
assume interactions occur with free atoms, sampling the target atom based on
the macroscopic cross sections, molecular effects cannot necessarily be
disregarded for charged particle treatment. For compounds and mixtures, the
bremsstrahlung cross section is calculated using Bragg's additivity rule as
.. math::
:label: material-bremsstrahlung-dcs
\frac{d\sigma_{\text{br}}}{dE} = \frac{1}{\beta^2 E} \sum_i \gamma_i Z^2_i
\chi(Z_i, T, \kappa),
where the sum is over the constituent elements and :math:`\gamma_i` is the
atomic fraction of the :math:`i`-th element. Similarly, the radiative stopping
power is calculated using Bragg's additivity rule as
.. math::
:label: material-radiative-stopping-power
S_{\text{rad}}(T) = \sum_i w_i S_{\text{rad},i}(T),
where :math:`w_i` is the mass fraction of the :math:`i`-th element and
:math:`S_{\text{rad},i}(T)` is found for element :math:`i` using
:eq:`radiative-stopping-power`. The collision stopping power, however, is a
function of certain quantities such as the mean excitation energy :math:`I` and
the density effect correction :math:`\delta_F` that depend on molecular
properties. These quantities cannot simply be summed over constituent elements
in a compound, but should instead be calculated for the material. The Bethe
formula can be used to find the collision stopping power of the material:
.. math::
:label: material-collision-stopping-power
S_{\text{col}}(T) = \frac{2 \pi r_e^2 m_e c^2}{\beta^2} N_A \frac{Z}{A_M}
[\ln(T^2/I^2) + \ln(1 + \tau/2) + F(\tau) - \delta_F(T)],
where :math:`N_A` is Avogadro's number, :math:`A_M` is the molar mass,
:math:`\tau = T/m_e`, and :math:`F(\tau)` depends on the particle type. For
electrons,
.. math::
:label: F-electron
F_{-}(\tau) = (1 - \beta^2)[1 + \tau^2/8 - (2\tau + 1) \ln2],
while for positrons
.. math::
:label: F-positron
F_{+}(\tau) = 2\ln2 - (\beta^2/12)[23 + 14/(\tau + 2) + 10/(\tau + 2)^2 +
4/(\tau + 2)^3].
The density effect correction :math:`\delta_F` takes into account the reduction
of the collision stopping power due to the polarization of the material the
charged particle is passing through by the electric field of the particle.
It can be evaluated using the method described by Sternheimer_, where the
equation for :math:`\delta_F` is
.. math::
:label: density-effect-correction
\delta_F(\beta) = \sum_{i=1}^n f_i \ln[(l_i^2 + l^2)/l_i^2] -
l^2(1-\beta^2).
Here, :math:`f_i` is the oscillator strength of the :math:`i`-th transition,
given by :math:`f_i = n_i/Z`, where :math:`n_i` is the number of electrons in
the :math:`i`-th subshell. The frequency :math:`l` is the solution of the
equation
.. math::
:label: density-effect-l
\frac{1}{\beta^2} - 1 = \sum_{i=1}^{n} \frac{f_i}{\bar{\nu}_i^2 + l^2},
where :math:`\bar{v}_i` is defined as
.. math::
:label: density-effect-nubar
\bar{\nu}_i = h\nu_i \rho / h\nu_p.
The plasma energy :math:`h\nu_p` of the medium is given by
.. math::
:label: plasma-frequency
h\nu_p = \sqrt{\frac{(hc)^2 r_e \rho_m N_A Z}{\pi A}},
where :math:`A` is the atomic weight and :math:`\rho_m` is the density of the
material. In :eq:`density-effect-nubar`, :math:`h\nu_i` is the oscillator
energy, and :math:`\rho` is an adjustment factor introduced to give agreement
between the experimental values of the oscillator energies and the mean
excitation energy. The :math:`l_i` in :eq:`density-effect-correction` are
defined as
.. math::
:label: density-effect-li
\begin{aligned}
l_i &= (\bar{\nu}_i^2 + 2/3f_i)^{1/2} ~~~~&\text{for}~~ \bar{\nu}_i > 0 \\
l_n &= f_n^{1/2} ~~~~&\text{for}~~ \bar{\nu}_n = 0,
\end{aligned}
where the second case applies to conduction electrons. For a conductor,
:math:`f_n` is given by :math:`n_c/Z`, where :math:`n_c` is the effective
number of conduction electrons, and :math:`v_n = 0`. The adjustment factor
:math:`\rho` is determined using the equation for the mean excitation energy:
.. math::
:label: mean-excitation-energy
\ln I = \sum_{i=1}^{n-1} f_i \ln[(h\nu_i\rho)^2 + 2/3f_i(h\nu_p)^2]^{1/2} +
f_n \ln (h\nu_pf_n^{1/2}).
.. _ttb:
Thick-Target Bremsstrahlung Approximation
+++++++++++++++++++++++++++++++++++++++++
Since charged particles lose their energy on a much shorter distance scale than
neutral particles, not much error should be introduced by neglecting to
transport electrons. However, the bremsstrahlung emitted from high energy
electrons and positrons can travel far from the interaction site. Thus, even
without a full electron transport mode it is necessary to model bremsstrahlung.
We use a thick-target bremsstrahlung (TTB) approximation based on the models in
Salvat_ and Kaltiaisenaho_ for generating bremsstrahlung photons, which assumes
the charged particle loses all its energy in a single homogeneous material
region.
To model bremsstrahlung using the TTB approximation, we need to know the number
of photons emitted by the charged particle and the energy distribution of the
photons. These quantities can be calculated using the continuous slowing down
approximation (CSDA). The CSDA assumes charged particles lose energy
continuously along their trajectory with a rate of energy loss equal to the
total stopping power, ignoring fluctuations in the energy loss. The
approximation is useful for expressing average quantities that describe how
charged particles slow down in matter. For example, the CSDA range approximates
the average path length a charged particle travels as it slows to rest:
.. math::
:label: csda-range
R(T) = \int^T_0 \frac{dT'}{S(T')}.
Actual path lengths will fluctuate around :math:`R(T)`. The average number of
photons emitted per unit path length is given by the inverse bremsstrahlung
mean free path:
.. math::
:label: inverse-bremsstrahlung-mfp
\lambda_{\text{br}}^{-1}(T,E_{\text{cut}})
= n\int_{E_{\text{cut}}}^T\frac{d\sigma_{\text{br}}}{dE}dE
= n\frac{Z^2}{\beta^2}\int_{\kappa_{\text{cut}}}^1\frac{1}{\kappa}
\chi(Z,T,\kappa)d\kappa.
The lower limit of the integral in :eq:`inverse-bremsstrahlung-mfp` is non-zero
because the bremsstrahlung differential cross section diverges for small photon
energies but is finite for photon energies above some cutoff energy
:math:`E_{\text{cut}}`. The mean free path
:math:`\lambda_{\text{br}}^{-1}(T,E_{\text{cut}})` is used to calculate the
photon number yield, defined as the average number of photons emitted with
energy greater than :math:`E_{\text{cut}}` as the charged particle slows down
from energy :math:`T` to :math:`E_{\text{cut}}`. The photon number yield is
given by
.. math::
:label: photon-number-yield
Y(T,E_{\text{cut}}) = \int^{R(T)}_{R(E_{\text{cut}})}
\lambda_{\text{br}}^{-1}(T',E_{\text{cut}})ds = \int_{E_{\text{cut}}}^T
\frac{\lambda_{\text{br}}^{-1}(T',E_{\text{cut}})}{S(T')}dT'.
:math:`Y(T,E_{\text{cut}})` can be used to construct the energy spectrum of
bremsstrahlung photons: the number of photons created with energy between
:math:`E_1` and :math:`E_2` by a charged particle with initial kinetic energy
:math:`T` as it comes to rest is given by :math:`Y(T,E_1) - Y(T,E_2)`.
To simulate the emission of bremsstrahlung photons, the total stopping power
and bremsstrahlung differential cross section for positrons and electrons must
be calculated for a given material using :eq:`material-bremsstrahlung-dcs` and
:eq:`material-radiative-stopping-power`. These quantities are used to build the
tabulated bremsstrahlung energy PDF and CDF for that material for each incident
energy :math:`T_k` on the energy grid. The following algorithm is then applied
to sample the photon energies:
1. For an incident charged particle with energy :math:`T`, sample the number of
emitted photons as
.. math::
N = \lfloor Y(T,E_{\text{cut}}) + \xi_1 \rfloor.
2. Rather than interpolate the PDF between indices :math:`k` and :math:`k+1`
for which :math:`T_k < T < T_{k+1}`, which is computationally expensive, use
the composition method and sample from the PDF at either :math:`k` or
:math:`k+1`. Using linear interpolation on a logarithmic scale, the PDF can
be expressed as
.. math::
p_{\text{br}}(T,E) = \pi_k p_{\text{br}}(T_k,E) + \pi_{k+1}
p_{\text{br}}(T_{k+1},E),
where the interpolation weights are
.. math::
\pi_k = \frac{\ln T_{k+1} - \ln T}{\ln T_{k+1} - \ln T_k},~~~
\pi_{k+1} = \frac{\ln T - \ln T_k}{\ln T_{k+1} - \ln T_k}.
Sample either the index :math:`i = k` or :math:`i = k+1` according to the
point probabilities :math:`\pi_{k}` and :math:`\pi_{k+1}`.
3. Determine the maximum value of the CDF :math:`P_{\text{br,max}}`.
3. Sample the photon energies using the inverse transform method with the
tabulated CDF :math:`P_{\text{br}}(T_i, E)` i.e.,
.. math::
E = E_j \left[ (1 + a_j) \frac{\xi_2 P_{\text{br,max}} -
P_{\text{br}}(T_i, E_j)} {E_j p_{\text{br}}(T_i, E_j)} + 1
\right]^{\frac{1}{1 + a_j}}
where the interpolation factor :math:`a_j` is given by
.. math::
a_j = \frac{\ln p_{\text{br}}(T_i,E_{j+1}) - \ln p_{\text{br}}(T_i,E_j)}
{\ln E_{j+1} - \ln E_j}
and :math:`P_{\text{br}}(T_i, E_j) \le \xi_2 P_{\text{br,max}} \le
P_{\text{br}}(T_i, E_{j+1})`.
We ignore the range of the electron or positron, i.e., the bremsstrahlung
photons are produced in the same location that the charged particle was
created. The direction of the photons is assumed to be the same as the
direction of the incident charged particle, which is a reasonable approximation
at higher energies when the bremsstrahlung radiation is emitted at small
angles.
.. _photon_production:
@ -1059,16 +723,14 @@ emitted photon.
.. _anomalous scattering: http://pd.chem.ucl.ac.uk/pdnn/diff1/anomscat.htm
.. _Kahn's rejection method: https://laws.lanl.gov/vhosts/mcnp.lanl.gov/pdf_files/aecu-3259_kahn.pdf
.. _Kahn's rejection method: https://doi.org/10.2172/4353680
.. _Klein-Nishina: https://en.wikipedia.org/wiki/Klein%E2%80%93Nishina_formula
.. _LA-UR-04-0487: https://laws.lanl.gov/vhosts/mcnp.lanl.gov/pdf_files/la-ur-04-0487.pdf
.. _LA-UR-04-0487: https://mcnp.lanl.gov/pdf_files/TechReport_2004_LANL_LA-UR-04-0487_Sood.pdf
.. _LA-UR-04-0488: https://laws.lanl.gov/vhosts/mcnp.lanl.gov/pdf_files/la-ur-04-0488.pdf
.. _LA-UR-04-0488: https://mcnp.lanl.gov/pdf_files/TechReport_2004_LANL_LA-UR-04-0488_SoodWhite.pdf
.. _Kaltiaisenaho: https://aaltodoc.aalto.fi/bitstream/handle/123456789/21004/master_Kaltiaisenaho_Toni_2016.pdf
.. _Salvat: https://www.oecd-nea.org/globalsearch/download.php?doc=77434
.. _Sternheimer: https://doi.org/10.1103/PhysRevB.26.6067
.. _Salvat: https://doi.org/10.1787/32da5043-en

Some files were not shown because too many files have changed in this diff Show more