From 2c46d3327ed7654493e5beff6e637f4f61ee180e Mon Sep 17 00:00:00 2001 From: Daniele Micheletti Date: Wed, 26 Sep 2018 12:58:54 +0000 Subject: [PATCH] trunk/beams: fix to alpha0 value if outside table range in read_beam1 --- Makefile.sum | 4 ++-- src/beams.f90 | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Makefile.sum b/Makefile.sum index c9d8f58..feeb2f3 100644 --- a/Makefile.sum +++ b/Makefile.sum @@ -17,7 +17,7 @@ FC=gfortran FFLAGS=-O3 #FFLAGS=-Wall -g -finit-real=nan -ffpe-trap=invalid -fcheck=all -fbounds-check -DIRECTIVES = -DREVISION="'$(shell svnversion src)'" +DIRECTIVES = -DREVISION="178M" all: $(EXE) @@ -65,7 +65,7 @@ utils.o: const_and_precisions.o .PHONY: clean install # Remove output files clean: - rm -rf *.o *.mod $(EXE) + rm -rf *.o *.mod install: @if [ -f $(EXE) ]; then \ diff --git a/src/beams.f90 b/src/beams.f90 index f7326e7..2e0a247 100644 --- a/src/beams.f90 +++ b/src/beams.f90 @@ -57,7 +57,7 @@ contains implicit none ! arguments character(len=*), intent(in) :: file_beam - real(wp_), intent(in) :: alpha0 + real(wp_), intent(inout) :: alpha0 real(wp_), intent(out) :: fghz,x00,y00,z00,beta0 real(wp_), intent(out) :: wcsi,weta,rcicsi,rcieta,phir,phiw integer, intent(in), optional :: unit @@ -131,6 +131,7 @@ contains ! alpha0 outside table range if(alpha0 >= alphastv(nisteer)) ii=nisteer if(alpha0 <= alphastv(1)) ii=1 + alpha0=alphastv(ii) beta0=betastv(ii) x00=x00v(ii) y00=y00v(ii)