RE: [fluka-discuss]: simulation of x-ray divergent beam

From: Anton Lechner <>
Date: Mon, 20 Aug 2018 17:06:15 +0000

Dear Minal,

1. If you look inside the source routine, you can see that the beam position as defined by the BEAMPOS card (stored in X/Y/ZBEAM in the (BEAMCM) common) are by default assigned to the particle coordinates. However, the rotation of the beam reference frame as defined by the BEAMAXIS cards is not applied (the routine uses the direction cosines given on the BEAMPOS card). The values are however available in the (BEAMCM) common (inside BMAXIS(*,*)) and could be applied manually. However, in your case the beam axis corresponds to a geometry axis, so it is straightforward to define the direction manually; what is a bit more complicated is the divergence sampling around this direction -> see point 2.

2. If you use the user source routine, you have to code yourself the divergence of the beam, i.e. the divergence you specify on the BEAM card is ineffective (although the value is available via the BEAMCM common). Apart from that, if you would not have a user routine, the correct way to get the divergence sampling around an arbitrary axis (in your case the neg. y-axis) is indeed to transform the beam reference frame via the BEAMAXIS cards. Then the sampling will be done around this axis. So your approach would have been correct in case you wouldn't use a custom source routine.

Just a side remark: you should not mix up divergence (i.e. angular distribution of the beam) and transverse beam shape at the beam position. Divergence is only specified on WHAT(3), whereas the deltax/y on WHAT(4)/(5) of the BEAM card concerns the initial beam shape.

3. Hard to judge without input file.

Cheers, Anton

From: [] on behalf of []
Sent: 20 August 2018 14:01
Subject: [fluka-discuss]: simulation of x-ray divergent beam

Dear fluka experts,

I wanted to simulate X-ray beam along negative Y direction. It starts
from a point and then diverge along x and z direction and at a distance
of 180 cm forms a rectangle of 35 x 35 cm2.

I have few doubts.

1. I have to use source.f file to generate X-ray energies. As beam is in
negative y direction, i am using BEAMAXES card along with BEAM and
BEAMPOS cards. whether the rotation information is again required to be
given in source.f?

2. how to give divergent rectangular beam? I have tried giving deltaphi
for divergence in mrad and deltax and deltay as 17.5 cm, but i want the
beam diverged in x and z direction.

3. I tried to plot the output using BEAM-PART of usrbin, but could not
able to visualise the divergence.

Kindly help.


Minal Y.
IDS, BARC, Mumbai

You can manage unsubscription from this mailing list at

You can manage unsubscription from this mailing list at
Received on Mon Aug 20 2018 - 20:25:27 CEST

This archive was generated by hypermail 2.3.0 : Mon Aug 20 2018 - 20:25:29 CEST