I want to determine the required shape and size of magnets with certain magnetic field and the installation distance from target to deflect electrons and ions of certain energies. Is it possible to create different ions in FLUKA ?
yes of course it is possible. You have to select HEAVYION in the BEAM card (and in that case the kinetic energy or momentum will be interpreted as per nuclear mass unit). Then you have to add the HI-PROPErt card which allows to set the Z and A of your desired ion. You should also add the PHYSICS cards activating the treatment of coalescence and evaporation of heavy fragments (See the manual).
Remember that if heavy ions are your primary particles you should link the RQMD and DPMJET event generators (linking with ldpmqmd and not lfluka) or, in Flair, run with flukadpm.
Thank you very much for the response. I have added the necessary cards as you suggested. I run the program with flukadpm. But I am not able to plot the deflection as fluka is not showing the 2d graph and the .bnn.lis consists only zero values.
I am attaching the flair and inp file.
Dear @talktoshubhama,
if you want to activate the magnetic field in regions Mag1 and Mag2 you have to select “Magnetic” in their ASSIGNMA card.
To avoid any misunderstanding, be aware that your beam is not passing through the regions where the field would be present, i.e. Mag1 and Mag2.
When using MGNFIELD and MGNCREAT, you don’t have to define the regions where the dipole coils would be and expect the field to be in between them. Rather define one single region where you know you will have the magnetic field and activate it there.
I have applied the suggested improvements (made one single region Mag1 from where the beam will pass and assigned the magnetic field to the ASSIGMA card). Still, I am not getting anything in the 2d plot, except I see some changes in the 1d plot. Maybe I am missing something.
Attaching the updated files
Dear @talktoshubhama ,
There is no problem with your input file.
I can clearly see the deflection of the ions in the ZX plane: with your settings the magnetic field is directed as the y-axis. For clarity I have increased the range and the number of bins.
I have increased the size of geometry and USRBIN also with bin size. Still, I am getting empty graph like this
Even if same USRBIN size as your graphs. Actually, I am new to FLUKA. May be, I am doing some mistake in plotting because graph dimensions are not the same size as USRBIN
Dear @talktoshubhama,
many thanks, I will have a look. Apologies for the misunderstanding but by output file I meant the one that should be called MF1_3001.out (you have one *out file for each cycle): could you share that one?
Best,
Davide