Page 1 of 1

Float or Int Blocks/

Posted: 3. May 2018, 16:15
by RobertoFranceschini
Hi!
I have noted that

Code: Select all

Block SPhenoInput
accepts 1.0 or 0.0 as switches values, whereas

Code: Select all

Block MODSEL
needs them to be integers otherwise

Code: Select all

At line 464 of file InputOutput_MSSM.f90 (unit = 99, file = 'input.slha')
Fortran runtime error: Bad integer for item 2 in list input
I am writing a parser to handle the SLHA files as Python dictionaries. For now I have added a specific rule to parse&write MODSEL (the only block I found that needs integers). So I was wondering if there is any way to make SPheno work with float values in the Block MODEL or I'd risk some bad behaviour of the code (the .f90 for Subroutine Read_MODSEL seems quite similar to the other Read_* but somehow the work differently).

Thanks a lot for reading. Cheers,
Roberto

Re: Float or Int Blocks/

Posted: 4. May 2018, 09:24
by FStaub
Hi,

I think according to the SLHA conventions, the definition for this block is to use integers.
If you don't mind playing yourself with this issue, you could try to edit InputOutput_MODEL.f90 and change

Code: Select all

     If (i_test.Ne.12) Then
      Backspace(io)
      Read(io,*) i_test,i_mod ! ,read_line
     End If
to

Code: Select all

     If (i_test.Ne.12) Then
      Backspace(io)
      Read(io,*) i_test, r_mod ! ,read_line
      i_mod = int(r_mod)
     End If
and see if that works.

Cheers,
Florian

Re: Float or Int Blocks/

Posted: 4. May 2018, 12:06
by RobertoFranceschini
Hi Florian, thanks for your input.

That change, assuming I used it correctly, does not seem to give a working code. I get the same complaint, concerning the line

Code: Select all

      Read(io,*) i_test, r_mod ! ,read_line
I am not sure why. Strangely enough this happens for both int and float values in the input SLHA file.

I have tricked a bit the declarion of the variable into

Code: Select all

   Real(dp) :: r_mod
   Real(dp) :: i_mod

   ! Integer :: i_mod, i_test, i_rp
   Integer :: i_test, i_rp
and it seems to give a working code. I have compared for a few points with the original code and the differences seem to arise at the n-th digit of some Higgs boson property

Code: Select all

840c840
<         25           22           22     0.37160034E-04 # H-Photon-Photon
---
>         25           22           22     0.37136300E-04 # H-Photon-Photon
928,930c928,930
<     1101    2.21022106E-33  # BR(h->e mu)
<     1102    9.51125776E-61  # BR(h->e tau)
<     1103    8.09022540E-35  # BR(h->mu tau)
---
>     1101    2.21023048E-33  # BR(h->e mu)
>     1102    9.51129827E-61  # BR(h->e tau)
>     1103    8.09025986E-35  # BR(h->mu tau)
1381c1381
< DECAY        25     3.80481077E-03   # hh_1
---
> DECAY        25     3.80479457E-03   # hh_1
1383,1391c1383,1391
<      3.33549242E-03    2           22         22   # BR(hh_1 -> VP VP )
<      8.09451708E-02    2           21         21   # BR(hh_1 -> VG VG )
<      1.71208037E-02    2           23         23   # BR(hh_1 -> VZ VZ )
<      2.23321916E-01    2           24        -24   # BR(hh_1 -> VWm^* VWm_virt )
<      2.17548943E-04    2           -3          3   # BR(hh_1 -> Fd_2^* Fd_2 )
<      5.82638712E-01    2           -5          5   # BR(hh_1 -> Fd_3^* Fd_3 )
<      2.33481552E-04    2          -13         13   # BR(hh_1 -> Fe_2^* Fe_2 )
<      6.73916197E-02    2          -15         15   # BR(hh_1 -> Fe_3^* Fe_3 )
<      2.47945409E-02    2           -4          4   # BR(hh_1 -> Fu_2^* Fu_2 )
---
>      3.33124719E-03    2           22         22   # BR(hh_1 -> VP VP )
>      8.09455156E-02    2           21         21   # BR(hh_1 -> VG VG )
>      1.71208766E-02    2           23         23   # BR(hh_1 -> VZ VZ )
>      2.23322867E-01    2           24        -24   # BR(hh_1 -> VWm^* VWm_virt )
>      2.17549869E-04    2           -3          3   # BR(hh_1 -> Fd_2^* Fd_2 )
>      5.82641194E-01    2           -5          5   # BR(hh_1 -> Fd_3^* Fd_3 )
>      2.33482546E-04    2          -13         13   # BR(hh_1 -> Fe_2^* Fe_2 )
>      6.73919067E-02    2          -15         15   # BR(hh_1 -> Fe_3^* Fe_3 )
>      2.47946465E-02    2           -4          4   # BR(hh_1 -> Fu_2^* Fu_2 )
Nothing serious, but let me show it to you first ...