program xbeach use params use spaceparams IMPLICIT NONE type(parameters) ::par type(spacepars) ::s integer*4 ::nt integer ::it real*8 ::degrad,thetamin,thetamax,tbegin,tend call cpu_time(tbegin) write(*,*) 'Welcome to Xbeach' write(*,*) 'General Input Module' ! General input per module call wave_input(par) call flow_input(par) call sed_input(par) write(*,*) 'Building Grid and Bathymetry and....' write(*,*) 'Distributing wave energy across the directional space ....' ! Grid and bathymetry call grid_bathy(s,par) ! Jump into subroutine readtide if(par%tideloc>=1)then call readtide (s,par) !Ap 15/10 end if write(*,*) 'Initializing .....' ! Initialisations call wave_init (s,par) call flow_init (s,par) call sed_init (s,par) par%t=0. par%tnext=par%tint it=0 write(*,*) 'Stepping into the time loop ....' do while (par%t<=par%tstop) ! Calculate timestep call timestep(s,par) ! Wave boundary conditions call wave_bc (s,par,it); ! Flow boundary conditions call flow_bc (s,par,it); ! Wave timestep if (par%instat==0) then if (mod(par%t,real(par%wavint))==0) call wave_stationary(s,par) else call wave_timestep(s,par) endif ! Flow timestep call flow_timestep (s,par) ! Suspended transport call transus(s,par) ! Bed level update call bed_update(s,par) ! Output call output(it,s,par) enddo call cpu_time(tend) write(*,*)'Total calculation time: ',tend-tbegin,' seconds' end program