I want to create a 10×10×10 prototype lattice inside a large container using lattice.f . After writing my flair file and lattice.f file, my program fails to run correctly. However, if I remove the LATTICE card in flair, the program runs properly. Therefore, I infer that the issue stems from my use of the LATTICE card or the implementation of lattice.f , and I hope you can point out where the problem lies. (The particle source settings are determined by the source_newgen.f file, and their configuration is presumably correct.) (I have also shared my flair file, lattice.f file, and source_newgen.f file.)
unfortunately it is not possible to use the lattic.f routine in the way you tried.
Please have a look at:
I would suggest to try to set up the lattice structure with cards only, since the user routine only replaced the ROT_DEFI cards. The cards for the replica bodies and the LATTICE cards are still has to be defined in the FLUKA input file. (You may generate them with an external script.)
Dear David,
Actually, my core requirement is to replicate approximately 3×10¹⁶ prototype lattices within a large container. From the course PowerPoint slides and user manual, I noticed that the lattice.f file must be used for replicating a large number of lattices. However, I have not found specific usage methods or practical cases for the lattice.f file. Could you please provide relevant guidance?
the large number in this context is in the order of hundreds/few thousands, since the total number of regions allowed is 20’000.
Furthermore, you still need to define each replica bodies and lattice regions with FLUKA cards. The routine only allow to set up the transformation between the replicas and prototype.
that is correct, it is not possible to create a 3e16 lattice replicas. The lattice system is mostly used for creating copies of bigger geometry componenets, like magnets in an accelerator, or detector components.
If you would let us know why you need so many copies of an object, maybe we can suggest an alternative solution.
Dear David,
I hope to construct a square aqueous solution in FLUKA, with a large number of metal particles suspended regularly in it. The metal particles are spaced apart from each other, and their quantity follows a distribution of 3.3E7 × 3.3E7 × 3.3E. Which FLUKA function should I use to achieve this?
Dear David,
As a matter of fact, what I intend to explore is the reaction of particles within such microstructures. Therefore, simply mixing metal with water cannot adequately meet my requirements. I have already generated the desired structure by using the LATTICE card in combination with the ROT-DEFIN card (the prototype material is temporarily replaced with lead). However, the program reports an error during operation, and I am unable to pinpoint the root cause of the error effectively. Could you help me identify the problem?
While Flair shows the geometry as you wanted, FLUKA is not capable to use it, because nested lattices are not allowed. Each lattice should go back to the prototype.
You cannot use FLUKA for studies on a nanometer scale, as recalled above, nor for simulating an unreasonable number of regions, which would require thousands of CPU years to be tracked.