From f553141864f48a28a050792678777307c79ca3fb Mon Sep 17 00:00:00 2001 From: kamischi <karl-michael.schindler@web.de> Date: Fri, 20 Jan 2023 13:43:25 +0100 Subject: [PATCH] Fix boson program for fcat. --- source/f90/fcat-analysis/boson_all-fcat.f90 | 51 +++++++++++++------ source/f90/fcat-analysis/boson_all.f90 | 51 +++++++++++++------ .../boson_all.f90.fcat-analysis.txt | 51 +++++++++++++------ 3 files changed, 108 insertions(+), 45 deletions(-) diff --git a/source/f90/fcat-analysis/boson_all-fcat.f90 b/source/f90/fcat-analysis/boson_all-fcat.f90 index 9660331..37b41d6 100644 --- a/source/f90/fcat-analysis/boson_all-fcat.f90 +++ b/source/f90/fcat-analysis/boson_all-fcat.f90 @@ -132,6 +132,7 @@ program boson stop call FCAT_boson_all_rep() end program boson + subroutine change_working_dir() ! This routine gets the first argument of the commandline and takes it @@ -168,6 +169,7 @@ subroutine change_working_dir() call FCAT_boson_all(55) return end subroutine change_working_dir + double precision function respon(w, width) !******************************************************************* @@ -206,8 +208,7 @@ double precision function respon(w, width) return call FCAT_boson_all_rep() end function respon -module sicot_mod -contains + subroutine sicot(f, m, h, x0) ! ******************************************************************* @@ -236,8 +237,6 @@ subroutine sicot(f, m, h, x0) ! * * ! ******************************************************************* - use sintr_mod - implicit none double precision, intent(in out) :: f(*) @@ -250,6 +249,14 @@ subroutine sicot(f, m, h, x0) logical :: debug + interface + subroutine sintr(f, msign, h) + double precision, intent(in out) :: f(*) + integer, intent(in) :: msign + double precision, intent(in) :: h + end subroutine sintr + end interface + call FCAT_boson_all(67) debug = .false. call FCAT_boson_all(68) @@ -351,9 +358,7 @@ subroutine sicot(f, m, h, x0) call FCAT_boson_all(109) return end subroutine sicot -end module sicot_mod -module sintr_mod -contains + subroutine sintr(f, msign, h) ! ******************************************************************* @@ -688,9 +693,7 @@ subroutine sintr(f, msign, h) call FCAT_boson_all(246) return end subroutine sintr -end module sintr_mod -module rcffi_mod -contains + subroutine rcffi(ar, ai, msign, h) ! ******************************************************************* @@ -993,7 +996,7 @@ subroutine rcffi(ar, ai, msign, h) call FCAT_boson_all(367) return end subroutine rcffi -end module rcffi_mod + subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, yout, nout) ! ******************************************************************* @@ -1018,10 +1021,6 @@ subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, y ! * nout: Number of points of this computation * ! ******************************************************************* - use rcffi_mod - use sicot_mod - use sintr_mod - implicit none double precision, intent(in) :: t, width, gauss, asym, emin, emax, wmin @@ -1047,6 +1046,26 @@ subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, y logical :: debug + interface + subroutine rcffi(ar, ai, msign, h) + double precision, intent(in out) :: ar(*) + double precision, intent(in out) :: ai(*) + integer, intent(in) :: msign + double precision, intent(in) :: h + end subroutine rcffi + subroutine sicot(f, m, h, x0) + double precision, intent(in out) :: f(*) + integer, intent(in) :: m + double precision, intent(in) :: h + double precision, intent(in) :: x0 + end subroutine sicot + subroutine sintr(f, msign, h) + double precision, intent(in out) :: f(*) + integer, intent(in) :: msign + double precision, intent(in) :: h + end subroutine sintr + end interface + ! remark : the two arrays r1 and r2 are used for fourier ! transforming the user-supplied instrumental response of the ! spectrometer that has to be coded in the external routine @@ -1553,6 +1572,7 @@ subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, y call FCAT_boson_all(596) return end subroutine doboson + double precision function o1(u) implicit none @@ -1568,6 +1588,7 @@ double precision function o1(u) call FCAT_boson_all(599) return end function o1 + double precision function o2(u) implicit none diff --git a/source/f90/fcat-analysis/boson_all.f90 b/source/f90/fcat-analysis/boson_all.f90 index 67edb5b..cd0ea68 100644 --- a/source/f90/fcat-analysis/boson_all.f90 +++ b/source/f90/fcat-analysis/boson_all.f90 @@ -83,6 +83,7 @@ program boson deallocate (xout, yout) stop end program boson + subroutine change_working_dir() ! This routine gets the first argument of the commandline and takes it @@ -108,6 +109,7 @@ subroutine change_working_dir() return end subroutine change_working_dir + double precision function respon(w, width) !******************************************************************* @@ -134,8 +136,7 @@ double precision function respon(w, width) endif return end function respon -module sicot_mod -contains + subroutine sicot(f, m, h, x0) ! ******************************************************************* @@ -164,8 +165,6 @@ subroutine sicot(f, m, h, x0) ! * * ! ******************************************************************* - use sintr_mod - implicit none double precision, intent(in out) :: f(*) @@ -178,6 +177,14 @@ subroutine sicot(f, m, h, x0) logical :: debug + interface + subroutine sintr(f, msign, h) + double precision, intent(in out) :: f(*) + integer, intent(in) :: msign + double precision, intent(in) :: h + end subroutine sintr + end interface + debug = .false. if (m == 0) then f(1) = 0.0d0 @@ -234,9 +241,7 @@ subroutine sicot(f, m, h, x0) call sintr(f, msign, h) return end subroutine sicot -end module sicot_mod -module sintr_mod -contains + subroutine sintr(f, msign, h) ! ******************************************************************* @@ -433,9 +438,7 @@ subroutine sintr(f, msign, h) f(1) = 0.0d0 return end subroutine sintr -end module sintr_mod -module rcffi_mod -contains + subroutine rcffi(ar, ai, msign, h) ! ******************************************************************* @@ -616,7 +619,7 @@ subroutine rcffi(ar, ai, msign, h) enddo return end subroutine rcffi -end module rcffi_mod + subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, yout, nout) ! ******************************************************************* @@ -641,10 +644,6 @@ subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, y ! * nout: Number of points of this computation * ! ******************************************************************* - use rcffi_mod - use sicot_mod - use sintr_mod - implicit none double precision, intent(in) :: t, width, gauss, asym, emin, emax, wmin @@ -670,6 +669,26 @@ subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, y logical :: debug + interface + subroutine rcffi(ar, ai, msign, h) + double precision, intent(in out) :: ar(*) + double precision, intent(in out) :: ai(*) + integer, intent(in) :: msign + double precision, intent(in) :: h + end subroutine rcffi + subroutine sicot(f, m, h, x0) + double precision, intent(in out) :: f(*) + integer, intent(in) :: m + double precision, intent(in) :: h + double precision, intent(in) :: x0 + end subroutine sicot + subroutine sintr(f, msign, h) + double precision, intent(in out) :: f(*) + integer, intent(in) :: msign + double precision, intent(in) :: h + end subroutine sintr + end interface + ! remark : the two arrays r1 and r2 are used for fourier ! transforming the user-supplied instrumental response of the ! spectrometer that has to be coded in the external routine @@ -945,6 +964,7 @@ subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, y deallocate (p2) return end subroutine doboson + double precision function o1(u) implicit none @@ -957,6 +977,7 @@ double precision function o1(u) return end function o1 + double precision function o2(u) implicit none diff --git a/source/f90/fcat-analysis/boson_all.f90.fcat-analysis.txt b/source/f90/fcat-analysis/boson_all.f90.fcat-analysis.txt index 8d97d00..12427b0 100644 --- a/source/f90/fcat-analysis/boson_all.f90.fcat-analysis.txt +++ b/source/f90/fcat-analysis/boson_all.f90.fcat-analysis.txt @@ -83,6 +83,7 @@ program boson 1 deallocate (xout, yout) 1 stop end program boson + subroutine change_working_dir() ! This routine gets the first argument of the commandline and takes it @@ -108,6 +109,7 @@ subroutine change_working_dir() 1 return end subroutine change_working_dir + double precision function respon(w, width) !******************************************************************* @@ -134,8 +136,7 @@ double precision function respon(w, width) *> endif *> return end function respon -module sicot_mod -contains + subroutine sicot(f, m, h, x0) ! ******************************************************************* @@ -164,8 +165,6 @@ subroutine sicot(f, m, h, x0) ! * * ! ******************************************************************* - use sintr_mod - implicit none double precision, intent(in out) :: f(*) @@ -178,6 +177,14 @@ subroutine sicot(f, m, h, x0) logical :: debug + interface + subroutine sintr(f, msign, h) + double precision, intent(in out) :: f(*) + integer, intent(in) :: msign + double precision, intent(in) :: h + end subroutine sintr + end interface + 1 debug = .false. 1 if (m == 0) then *> f(1) = 0.0d0 @@ -234,9 +241,7 @@ subroutine sicot(f, m, h, x0) 1 call sintr(f, msign, h) 1 return end subroutine sicot -end module sicot_mod -module sintr_mod -contains + subroutine sintr(f, msign, h) ! ******************************************************************* @@ -433,9 +438,7 @@ subroutine sintr(f, msign, h) 2 f(1) = 0.0d0 2 return end subroutine sintr -end module sintr_mod -module rcffi_mod -contains + subroutine rcffi(ar, ai, msign, h) ! ******************************************************************* @@ -616,7 +619,7 @@ subroutine rcffi(ar, ai, msign, h) 4095 enddo 1 return end subroutine rcffi -end module rcffi_mod + subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, yout, nout) ! ******************************************************************* @@ -641,10 +644,6 @@ subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, y ! * nout: Number of points of this computation * ! ******************************************************************* - use rcffi_mod - use sicot_mod - use sintr_mod - implicit none double precision, intent(in) :: t, width, gauss, asym, emin, emax, wmin @@ -670,6 +669,26 @@ subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, y logical :: debug + interface + subroutine rcffi(ar, ai, msign, h) + double precision, intent(in out) :: ar(*) + double precision, intent(in out) :: ai(*) + integer, intent(in) :: msign + double precision, intent(in) :: h + end subroutine rcffi + subroutine sicot(f, m, h, x0) + double precision, intent(in out) :: f(*) + integer, intent(in) :: m + double precision, intent(in) :: h + double precision, intent(in) :: x0 + end subroutine sicot + subroutine sintr(f, msign, h) + double precision, intent(in out) :: f(*) + integer, intent(in) :: msign + double precision, intent(in) :: h + end subroutine sintr + end interface + ! remark : the two arrays r1 and r2 are used for fourier ! transforming the user-supplied instrumental response of the ! spectrometer that has to be coded in the external routine @@ -945,6 +964,7 @@ subroutine doboson(t, width, gauss, asym, emin, emax, wmin, wmax, np, p, xout, y 1 deallocate (p2) 1 return end subroutine doboson + double precision function o1(u) implicit none @@ -957,6 +977,7 @@ double precision function o1(u) 297 return end function o1 + double precision function o2(u) implicit none -- GitLab