Spatial source definition.

Hi All,
I try to make my radiation shielding simulation model of the tokamak more
precise. Now I use just box shaped source, and that not good enoudh. Next
step is implement ring-shape uniformal and isotropic sourse (ideally a
torus, but it should not be so important in terms of my calculations).
Unfortunatly, I dont find full enough (for my understanding :slight_smile: )
explenation of openmc.stats.Spatial, or some an example of non point/box
sourse.
Can samebody help me with that. May be a simple example of sousre from
cell/region or some other type of definition of shape.
Thank's a lot!

Hi Illia

I have come across similar difficulties where a volume source was needed, I think a solution exists for volume fission sources but perhaps not for fixed sources

Anyway I am not sure I have a solution for that that exact problem but perhaps we have something better :slight_smile:

The DLOpen branch which is being developed allows you to specify external source routine

There is a pull request for this feature

https://github.com/openmc-dev/openmc/pull/1257

A source routine has been created for a plasma source based on the Fausser paper

https://www.sciencedirect.com/science/article/pii/S0920379612000853
https://github.com/ukaea/openmc_workshop/tree/master/parametric_plasma_source

Together this branch and the external plasma source file allow you to simulate fusion plasma quite nicely.

I have made an example as part of a fusion neutronics openmc workshop here

[https://github.com/ukaea/openmc_workshop](https://github.com/ukaea/openmc_workshop)

The particular task you want is task 3
[https://github.com/ukaea/openmc_workshop/tree/master/tasks/task_3](https://github.com/ukaea/openmc_workshop/tree/master/tasks/task_3)

The particular example file you want is 4_plot_neutron_birth_location_plasma.py
[https://github.com/ukaea/openmc_workshop/blob/master/tasks/task_3/4_plot_neutron_birth_location_plasma.py](https://github.com/ukaea/openmc_workshop/blob/master/tasks/task_3/4_plot_neutron_birth_location_plasma.py)

As mentioned earlier this currently needs the dlopen branch to work so perhaps the docker file with this branch checkouted is also useful
https://github.com/ukaea/openmc_workshop/blob/master/docker_images/Dockerfile_openmc

Hopefully the branch will be merged into the master branch at some point and documentation along with examples will appear in the openmc read the docs but for now this is a temporary solution

Feel free to review and feedback any comments to the PR on the dlopen branch https://github.com/openmc-dev/openmc/pull/1257

Best of luck with your fusion related research

Jon

Hi Illia,

To follow on to what Jon explained nicely, the develop branch of openmc has cylindrical and spherical source distributions. So, for a volumetric ring source you could specify Uniform or Normal distributions in R and Z for example to get a simplified version of what youโ€™re looking for.

Best of luck!
Ethan