# Example using Flair

**URL:** <https://fluka-forum.web.cern.ch/t/example-using-flair/392>\
**Category:** Running and Runtime Errors\
**Created:** [27 March 2020 14:18 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392 "2020-03-27T14:18:53Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![pchristo](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/p/e0b2c6/32.png) [@pchristo](https://fluka-forum.web.cern.ch/u/pchristo)\
**Post date:** [27 March 2020 14:18 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/1 "2020-03-27T14:18:53Z")

</div>

Hello,  
I am new in FLAIR and I tried to follow the tutorial in the video: [https://www.youtube.com/watch?v=SjhDqIo5cvk&t=26s](https://www.youtube.com/watch?v=SjhDqIo5cvk&t=26s)  
Unfortunatelly, it says that it finished with errors. The same happened when I followed the instructions from [http://flair.web.cern.ch/flair/tutorial\_fluka.html](http://flair.web.cern.ch/flair/tutorial_fluka.html)  
Any suggestions why this happens?  
Thank you very much in advance.  
Best regards,  
Pinelopi

---

<div class="post-metadata">

**Author:** ![atsingan](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/a/b77776/32.png) [@atsingan](https://fluka-forum.web.cern.ch/u/atsingan)\
**Post date:** [27 March 2020 14:45 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/2 "2020-03-27T14:45:24Z")

</div>

Hi @pchristo,

There is any number of issues that can cause a run to “finish with errors”. You will need to provide more details and the specific input file that you are trying to run.

In the meantime, if you are simply loading the “basic” input in Flair without changing anything in the input file, the run is launched by default with 200GeV protons and 5000 primaries per cycle. It may be that this takes too long on your machine. Does the run stop (almost) immediately or after having run for some time?

---

<div class="post-metadata">

**Author:** ![vasilis](https://fluka-forum.web.cern.ch/user_avatar/fluka-forum.web.cern.ch/vasilis/32/16_2.png) [@vasilis](https://fluka-forum.web.cern.ch/u/vasilis)\
**Post date:** [27 March 2020 14:45 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/3 "2020-03-27T14:45:35Z")

</div>

Could you please post your **.flair** (and **.inp** ) files

---

<div class="post-metadata">

**Author:** ![pchristo](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/p/e0b2c6/32.png) [@pchristo](https://fluka-forum.web.cern.ch/u/pchristo)\
**Post date:** [27 March 2020 16:01 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/4 "2020-03-27T16:01:02Z")

</div>

Hello, thank you for the quick response. Yes it stops (almost) immediately. I will post my flair and inp files  
[tutorial.flair](https://fluka-forum.web.cern.ch/uploads/short-url/rEcZpSpiBI3oMZRIWlmymd1gdsJ.flair) (857 Bytes) [tutorial.inp](https://fluka-forum.web.cern.ch/uploads/short-url/oNbC8F0IJ9ZPBCYwvFhOv50uJYR.inp) (893 Bytes) [tutorial.out](https://fluka-forum.web.cern.ch/uploads/short-url/luOm6mqi26a0t2KSTOdpmq9Micz.out) (542 Bytes)

---

<div class="post-metadata">

**Author:** ![atsingan](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/a/b77776/32.png) [@atsingan](https://fluka-forum.web.cern.ch/u/atsingan)\
**Post date:** [27 March 2020 16:27 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/5 "2020-03-27T16:27:49Z")

</div>

OK, the input file is fine, in fact it is exactly the “basic” input without any change. The problem therefore seems to be related to your installation.

1. Can you confirm what is your FLUKA installation directory? Is it `/mnt/c/WSL/file/fluka2011-3.0/`?
2. Can you send us the output of the following command: `echo $PATH` ? Just run it in the Linux terminal (you don’t need to be in any particular directory when you do this).

---

<div class="post-metadata">

**Author:** ![horvathd](https://fluka-forum.web.cern.ch/user_avatar/fluka-forum.web.cern.ch/horvathd/32/10584_2.png) [@horvathd](https://fluka-forum.web.cern.ch/u/horvathd)\
**Post date:** [27 March 2020 16:32 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/6 "2020-03-27T16:32:01Z")

</div>

Hi Pinelopi,

The error code 127 suggests a file permission error.

In which directory are you trying to run?  
Please, post the result of the command: `pwd`, in that folder.

Cheers,  
David

---

<div class="post-metadata">

**Author:** ![pchristo](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/p/e0b2c6/32.png) [@pchristo](https://fluka-forum.web.cern.ch/u/pchristo)\
**Post date:** [27 March 2020 16:42 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/7 "2020-03-27T16:42:21Z")

</div>

Hello,

1. Yes that is the path were the FLUKA is installed.
2. ![image](https://fluka-forum.web.cern.ch/uploads/default/original/1X/a36df993dd2afb1b3a983f4a79a4b80a68e12dd0.png)

---

<div class="post-metadata">

**Author:** ![atsingan](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/a/b77776/32.png) [@atsingan](https://fluka-forum.web.cern.ch/u/atsingan)\
**Post date:** [27 March 2020 16:50 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/9 "2020-03-27T16:50:21Z")

</div>

It seems like the relevant FLUKA entry is not in the PATH. Please do the following:

Go to your home directory: `cd ~`  
Open the .bashrc file: `less .bashrc`  
Scroll to the bottom with PageDown or the down arrow.

Is there an entry similar to this?  
`export PATH=$PATH:/usr/local/fluka/bin/`

Please also take a look at @horvathd’s question above.

---

<div class="post-metadata">

**Author:** ![pchristo](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/p/e0b2c6/32.png) [@pchristo](https://fluka-forum.web.cern.ch/u/pchristo)\
**Post date:** [27 March 2020 18:46 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/10 "2020-03-27T18:46:12Z")

</div>

Hello,  
there is no such entry:

 ![image](https://fluka-forum.web.cern.ch/uploads/default/original/1X/fef95de093e4dec13daf2756de8d9c9bb50ef931.png)

---

<div class="post-metadata">

**Author:** ![horvathd](https://fluka-forum.web.cern.ch/user_avatar/fluka-forum.web.cern.ch/horvathd/32/10584_2.png) [@horvathd](https://fluka-forum.web.cern.ch/u/horvathd)\
**Post date:** [27 March 2020 18:58 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/11 "2020-03-27T18:58:40Z")

</div>

Hi!

can you post the result of the commend: `which rfluka` ?

Cheers,  
David

---

<div class="post-metadata">

**Author:** ![pchristo](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/p/e0b2c6/32.png) [@pchristo](https://fluka-forum.web.cern.ch/u/pchristo)\
**Post date:** [27 March 2020 19:13 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/12 "2020-03-27T19:13:33Z")

</div>

Hello!  
I entered

which rfluka

as a command in Ubuntu but nothing happened.  
Cheers,  
Pinelopi

---

<div class="post-metadata">

**Author:** ![horvathd](https://fluka-forum.web.cern.ch/user_avatar/fluka-forum.web.cern.ch/horvathd/32/10584_2.png) [@horvathd](https://fluka-forum.web.cern.ch/u/horvathd)\
**Post date:** [27 March 2020 19:18 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/13 "2020-03-27T19:18:06Z")

</div>

Hi,

did you set up the Fluka Directory in the Flair config?

Cheers,  
David

---

<div class="post-metadata">

**Author:** ![pchristo](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/p/e0b2c6/32.png) [@pchristo](https://fluka-forum.web.cern.ch/u/pchristo)\
**Post date:** [27 March 2020 19:23 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/14 "2020-03-27T19:23:09Z")

</div>

Hey,  
are there instructions on how to do that ? 😅  
Cheers.  
Pinelopi

---

<div class="post-metadata">

**Author:** ![horvathd](https://fluka-forum.web.cern.ch/user_avatar/fluka-forum.web.cern.ch/horvathd/32/10584_2.png) [@horvathd](https://fluka-forum.web.cern.ch/u/horvathd)\
**Post date:** [27 March 2020 19:36 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/15 "2020-03-27T19:36:02Z")

</div>

When Flair doesn’t find Fluka, a yellow warning pops up, with the button “Preferences”, which opens the Flair config dialog.

Can you check your settings, with the help of the picture below?

 ![flair_config](https://fluka-forum.web.cern.ch/uploads/default/original/1X/fc3a5a6af71764919d2b707546da701dc88d0529.png)

---

<div class="post-metadata">

**Author:** ![pchristo](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/p/e0b2c6/32.png) [@pchristo](https://fluka-forum.web.cern.ch/u/pchristo)\
**Post date:** [27 March 2020 19:38 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/16 "2020-03-27T19:38:50Z")

</div>

Oh yes it was saying that so I changed it according to this picture:

 ![image](https://fluka-forum.web.cern.ch/uploads/default/original/1X/2c3e6d2bef86a4179b75bc1c8808575e5149f1cc.jpeg)

---

<div class="post-metadata">

**Author:** ![horvathd](https://fluka-forum.web.cern.ch/user_avatar/fluka-forum.web.cern.ch/horvathd/32/10584_2.png) [@horvathd](https://fluka-forum.web.cern.ch/u/horvathd)\
**Post date:** [27 March 2020 20:50 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/17 "2020-03-27T20:50:33Z")

</div>

Hi,

Did you try to open Flair and run from your home directory? (/home/darwin)

Cheers,  
David

---

<div class="post-metadata">

**Author:** ![pchristo](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/p/e0b2c6/32.png) [@pchristo](https://fluka-forum.web.cern.ch/u/pchristo)\
**Post date:** [28 March 2020 11:27 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/18 "2020-03-28T11:27:48Z")

</div>

Hello,  
do you mean to change the directory shown in the picture?

 ![image](https://fluka-forum.web.cern.ch/uploads/default/original/1X/4c61539582af5d7fb3e6f2e9e97808d5829887f9.png)  
Thank you for helping me!  
Best wishes,  
Pinelopi

---

<div class="post-metadata">

**Author:** ![horvathd](https://fluka-forum.web.cern.ch/user_avatar/fluka-forum.web.cern.ch/horvathd/32/10584_2.png) [@horvathd](https://fluka-forum.web.cern.ch/u/horvathd)\
**Post date:** [28 March 2020 11:40 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/19 "2020-03-28T11:40:31Z")

</div>

Hi Pinelopi,

probably I wasn’t clear. I meant if you could run the basic input in that directory, instead in /mnt/c/WSL

Cheers,  
David

---

<div class="post-metadata">

**Author:** ![pchristo](https://fluka-forum.web.cern.ch/letter_avatar_proxy/v4/letter/p/e0b2c6/32.png) [@pchristo](https://fluka-forum.web.cern.ch/u/pchristo)\
**Post date:** [28 March 2020 11:57 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/20 "2020-03-28T11:57:25Z")

</div>

Hello,  
you mean to change the FLUKA directory in the image to /home/darwin ?  
Then it says that the fluka exetuble is not found.

 ![image](https://fluka-forum.web.cern.ch/uploads/default/original/1X/ba53052396c36e6d97fbbdf5328268184138d538.jpeg)

---

<div class="post-metadata">

**Author:** ![horvathd](https://fluka-forum.web.cern.ch/user_avatar/fluka-forum.web.cern.ch/horvathd/32/10584_2.png) [@horvathd](https://fluka-forum.web.cern.ch/u/horvathd)\
**Post date:** [28 March 2020 12:04 UTC](https://fluka-forum.web.cern.ch/t/example-using-flair/392/21 "2020-03-28T12:04:42Z")

</div>

Hi

No, you don’t need to change the settings, just run a simulation in the directory /home/darwin

Cheers,  
David

[Next page](https://fluka-forum.web.cern.ch/t/example-using-flair/392.md?page=2)
