MCNP6.2 - Source particle started in a cell of zero importance

In summary, I am getting an error "source particle started in a cell of zero importance" which seems to stop the execution of the code.
  • #1
19matthew89
47
12
TL;DR Summary
Error with SDEF for particle starting in a cell with zero importance
Hi everyone,

My plan is defining a surface source on a cylindrical object (cylindrical surface+top end+bottom end) and I am interested in what happens outside the cylindrical body. To avoid distortions of particles starting on the surface, directed inwards and emerging on the other side of the body, I set the importance inside the cylinder =0 so that all the particles entering the inner region are killed (keeping in mind to double the probability of particles for normalization as half of them are terminated).
However, this seems to be an issue as the error "source particle started in a cell of zero importance" stops the execution of the code.

I didn't think that was a problem.

How do you recommend to solve it?

  1. The first idea is to shift slightly off the source so that all the particles are started in a cell of importance different than 0 and, in case they move inwards they'll just cover a little distance and then be killed
  2. Use maybe the card SB? But I have not really understood how this works for normalization. Is normalization not affected because weights are already modified to keep SB into account?
  3. Do you have any other recommendation?
Thanks in advance
 
Engineering news on Phys.org
  • #2
P.S. I tried implementing option 1. but I bump into another error: "mcnp run terminated because 10 particles got lost".
 
  • #3
It might help if you posted your input file.

I'm guessing you are using an SDEF card to specify your source. Look at the NRM option for the SDEF card. This lets you specify the normal to the surface you start particles on. If you specify NRM=1 (if I am remembering correctly) it will start all the particles going straight out from the surface. So if it's a cylinder, they all start going radially out from it. There are other options possible for NRM. For example, you could specify a random distribution of some kind so that the particles start at randomly selected angles to the surface, with a range.

Lost particles usually indicate a bug in your geometry. Either a region is not filled or it is doubly filled or some such thing.

Also, MCNP has trouble with some specific geometry situations that you would think would be OK.
For example, if a cylinder is tangent to a surface then MCNP can lose particles near the contact point. Or if you are using a torus that has its small radius much smaller than its large radius, it can lose particles. That is like a bicycle tire that is very thin relative to the the size of the wheel. Or if you try to make "pizza slices" by intersecting plane surfaces at other than 90 degrees, it can lose particles near the pointy part of the slices.

Each of these has its own work-arounds. For example, don't try to use a torus to make a 90 degree corner in a pipe. Instead make the pipe out of squared off corners and don't try to make the corner round.
 
  • Like
Likes Alex A
  • #4
Grelbr42 said:
It might help if you posted your input file.

I'm guessing you are using an SDEF card to specify your source. Look at the NRM option for the SDEF card. This lets you specify the normal to the surface you start particles on. If you specify NRM=1 (if I am remembering correctly) it will start all the particles going straight out from the surface. So if it's a cylinder, they all start going radially out from it. There are other options possible for NRM. For example, you could specify a random distribution of some kind so that the particles start at randomly selected angles to the surface, with a range.

Lost particles usually indicate a bug in your geometry. Either a region is not filled or it is doubly filled or some such thing.

Also, MCNP has trouble with some specific geometry situations that you would think would be OK.
For example, if a cylinder is tangent to a surface then MCNP can lose particles near the contact point. Or if you are using a torus that has its small radius much smaller than its large radius, it can lose particles. That is like a bicycle tire that is very thin relative to the the size of the wheel. Or if you try to make "pizza slices" by intersecting plane surfaces at other than 90 degrees, it can lose particles near the pointy part of the slices.

Each of these has its own work-arounds. For example, don't try to use a torus to make a 90 degree corner in a pipe. Instead make the pipe out of squared off corners and don't try to make the corner round.
Thanks!
Yeah, indeed I'm using SDEF to define my source, however I didn't use NRM as I could not really use a surface since both cylinder surface and planes defining the cylinder cell are infinite. I know that in theory I could use macrobodies to define a finite cylinder and and then use the associated surface to employ NRM keyword but I'd prefer not to use macrobodies as this is just supposed to be only first step and geometry could get much more difficult than a mere cylinder later so I'd like to understand the code in this setup.

So what I did (see the code), was to define a degenerate volumetric source. In the code I implemented the other case I'm interested in (namely only the inside of the cylinder) and so I set kind of the opposite of what I had written in the original post, i.e. IMP:N 1 inside the cylinder and 0 outside the cylinder. But the issue is of course the same and...as soon as the first particle is produced outside the cylinder I keep on getting again the error: "the source particle started in a cell of zero importance".

If I set instead the importance of the cell 2 equal to 1 the code stops automatically after 10 particles being lost. The particles are actually expected to be lost in passing from a well defined material (the cylinder of cell 1) to a vacuum material like the one of the cell 2. So I'm not much surprised about this. Of course I could use the card LOST to enable more particle loss and in this case the code would run smoothly.

My question is now...which approach would you use?
  • Setting IMP=1 and adding the card LOST? If so, is there any tricky point in the normalization procedure I should beware of, in this case?
  • Filling the external sphere with air instead of vacuum?
  • Would you define a distribution also for the VEC so to be sure that, all the times, the particle starts only inwards? even if, I surmise that with this setup the problems of lost particles would simply pop up again.
Thanks
 

Attachments

  • Snippet.txt
    2.1 KB · Views: 100
  • #5
I'm a little fuzzy on distributions. I don't follow what the ds cards do, but you have a very involved source which includes distributions for RAD. What makes this a degenerate surface?
 
  • #6
Alex A said:
I'm a little fuzzy on distributions. I don't follow what the ds cards do, but you have a very involved source which includes distributions for RAD. What makes this a degenerate surface?
Hi.

Yeah..it's already pretty involved and actually it is a simplification with respect to the real source I have in mind o_O

The DS cards just define other distributions given by the following SI/SP.

By the way, the source is a degenerate column because for the top and bottom end it samples a disk (see SI31/SP31 and SI33/SP33) while for the lateral surface SI32/SP32 a constant radius is given and sampled with probability 1.

So in this way I manage to define a volume but with one dimension being zero and so it's a surface.
 
  • #7
This is an issue with the neutrons appearing on the boundary of cells in the geometry and I think you knew that. Changing the geometry very slightly avoids the issue, so for me option 1 is the way to go. Your source is a surface, and I still don't fully understand it, for example what sets the luminosity per unit area of the edges to be the same as the cylinder?

Code:
10  CZ  0.750001
11  PZ  -7.00001 
12  PZ  7.00001
Sees to work fine for me,

Code:
10  CZ  0.749999
11  PZ  -6.99999 
12  PZ  6.99999
also sees to work fine (with the importance of the first two cells reversed).

I'm not seeing the particles getting lost error, that is normally the result of a volume in the problem that isn't assigned to a cell in the geometry. Maybe it's an error you have that is only showing itself because the source is working.
 
  • Informative
Likes 19matthew89
  • #8
Alex A said:
This is an issue with the neutrons appearing on the boundary of cells in the geometry and I think you knew that. Changing the geometry very slightly avoids the issue, so for me option 1 is the way to go. Your source is a surface, and I still don't fully understand it, for example what sets the luminosity per unit area of the edges to be the same as the cylinder?

Code:
10  CZ  0.750001
11  PZ  -7.00001
12  PZ  7.00001
Sees to work fine for me,

Code:
10  CZ  0.749999
11  PZ  -6.99999
12  PZ  6.99999
also sees to work fine (with the importance of the first two cells reversed).

I'm not seeing the particles getting lost error, that is normally the result of a volume in the problem that isn't assigned to a cell in the geometry. Maybe it's an error you have that is only showing itself because the source is working.
Hi!

Thanks a lot. These solutions actually work and indeed I also got no error of particles getting lost.

I actually didn't know (although I had guessed) that MCNP would complain about neutrons appearing on the boundary of a cell.
And for what concern the intensity of the 3 sources (top end, lateral surface and bottom end) I just put equal values for this simple test code but of course, in what I aim to do, the luminosity would be different.

Thanks again!
 
  • Like
Likes Alex A

What is MCNP6.2?

MCNP6.2 is a Monte Carlo N-Particle transport code used for simulating the transport of particles through materials and environments. It is widely used in the field of nuclear engineering and radiation physics.

What does it mean for a source particle to start in a cell of zero importance?

In MCNP6.2, a source particle starting in a cell of zero importance means that the particle is starting in a cell that has no contribution to the overall simulation. This can occur when the cell has a low density or is not relevant to the simulation.

How does MCNP6.2 handle source particles starting in cells of zero importance?

MCNP6.2 has a built-in algorithm that automatically skips over cells of zero importance when simulating the transport of particles. This helps to improve the efficiency of the simulation and reduce computational time.

Can a source particle be started in a cell of zero importance intentionally?

Yes, a source particle can be intentionally started in a cell of zero importance by assigning a weight of zero to the cell. This can be useful for simulating scenarios where a certain material or environment is not present.

Are there any limitations or considerations when using MCNP6.2 with source particles starting in cells of zero importance?

There are a few limitations to consider when using MCNP6.2 with source particles starting in cells of zero importance. For example, the simulation may not accurately capture the behavior of particles in the skipped cells, and the results may be affected by the choice of weight assigned to the cells. It is important to carefully consider the simulation setup and consult with experts in the field before using this feature.

Similar threads

Replies
3
Views
2K
Replies
6
Views
1K
  • Nuclear Engineering
Replies
2
Views
2K
  • Nuclear Engineering
Replies
1
Views
2K
Replies
1
Views
588
  • Nuclear Engineering
Replies
4
Views
5K
  • High Energy, Nuclear, Particle Physics
Replies
20
Views
16K
  • Engineering and Comp Sci Homework Help
Replies
7
Views
734
  • Mechanical Engineering
Replies
2
Views
1K
  • Classical Physics
Replies
10
Views
2K
Back
Top