About spherical shell definition

Dear @horvathd ,
I am new of source user routine , I have read a topic titled “Spherical shell definition” and also want to define a source like that, I have some questions need your help.

  1. If the source particle energy is monoenergetic thermal neutron,may I use “particle_code = WHASOU(1), momentum_energy = WHASOU(2)” with SOURCE CARD instead of “call neutron_sampling()” and delete line133 to line222?
  2. About subroutine spherical_shell distribution, For a fixed-size sphere, I guess do while() is to judge inner spherical shell set to isotropic, but I really do not understand the sentence “new_radius=10*radius” and the function RACO().
    Look forward to your help.
    spherical_shell.f (7.1 KB)

Dear @xiongbp,

  1. Yes, you can remove the call and code of neutron_sampling().
  2. the RACO() subroutine gives a random uniformly distributed direction. The do while() cycle - as far as I can tell - checks if the sampled direction is pointing inside, and if not, it resampled the directions.

Please note, that this code is provided by another user, you need to make sure that it is appropriate for your needs.

You may want to look at FLUKA’s built in FLOOD source option. See slide 22 of:

Cheers,
David

Dear @horvathd ,
Thank you for your reply.
For the second question, I have figured it out after rethinking.
I have read the built in source option of “FLOOD”, The inside of the sphere satisfied my goal, but it seems that outside of the spherical surface exist source fluence? I do not want it and anyway to solve it?

Dear @xiongbp,

the source particles only directed towards the inside of the sphere. Outside the sphere the fluence is caused by the particles leaving. However, the fluence outside is not isotropic, nor uniform.

If you have a sphere big enough to contain your whole geometry, then you don’t need to worry about the fluence outside.

Cheers,
David

Dear @horvathd ,
I have understand it and thank you very much for your help. :blush: