diff --git a/Code/dynamic.f90 b/Code/dynamic.f90 index f7b6208dfb8d03b6b5e51a97bea5b72b8fe59a28..eb5e4017c7b7fe5806978702dc3362e8200785c6 100644 --- a/Code/dynamic.f90 +++ b/Code/dynamic.f90 @@ -51,6 +51,7 @@ CONTAINS END IF ! external boost IF(texternal) THEN + CALL init_external CALL extboost(text_timedep) END IF ! Create protocol files diff --git a/Code/external.f90 b/Code/external.f90 index 3a2c8445981d996a38ea2d282280f88da011de8d..1eac1c0c3a2faa0f2e2711ae9161741a07d4130c 100644 --- a/Code/external.f90 +++ b/Code/external.f90 @@ -14,13 +14,15 @@ MODULE External CONTAINS !*********************************************************************** SUBROUTINE getin_external + NAMELIST/extern/ amplq0,radext,widext,isoext,ipulse,omega,tau0,taut, & + textfield_periodic + READ(5,extern) + END SUBROUTINE getin_external + SUBROUTINE init_external REAL(db) :: facn,facp,facr,xlim,ylim,zlim INTEGER :: ix,iy,iz CHARACTER(14),PARAMETER :: pulsetype(0:2)=(/ 'Instantaneous ', & 'Gaussian ','Cosine squared' /) - NAMELIST/extern/ amplq0,radext,widext,isoext,ipulse,omega,tau0,taut, & - textfield_periodic - READ(5,extern) IF(ipulse<0.OR.ipulse>2) STOP & ' External field: called with invalid pulse type' IF(wflag) THEN @@ -49,6 +51,7 @@ CONTAINS facn=-1.0D0/(mass_number-charge_number) facp=1.0D0/charge_number ENDIF + WRITE(*,*) 'EXTERNAL: ',facn,facp ALLOCATE(extfield(nx,ny,nz,2)) xlim=nx*dx ylim=ny*dy @@ -68,7 +71,7 @@ CONTAINS ENDDO ENDDO ENDDO - END SUBROUTINE getin_external + END SUBROUTINE init_external !*********************************************************************** SUBROUTINE extfld(time) REAL(db) :: time