 SUBROUTINE read_phys()
!=========================== DOCUMENTATION ============================= 
!DOCDEBh*    UTI/PRE/read_phys *
!
!    NOM
! read_phys(calc)
!    DESCRIPTION  
!*
! Lecture du Bloc PHYS du fichier de donnees *.inp
! Reading thePHYS block from the *.inp data file
!*
! 
!    ENTREES / INPUT
!    
!    SORTIES / OUTPUT
!    
!    SOURCE
! Ce logiciel est regi par la licence [CeCILL-B]
! This software is governed by the [CeCILL-B] license
!=========================== DEBUT DES DECLARATIONS ==================== 
!.1-----  Implicit, Use
  use num
  IMPLICIT NONE
!.2-----  Declaration
  real(kind=kind(0.d0))  :: arg
  character(4)           :: para
!=========================== DEBUT DU CODE EXECUTABLE ==================

  write(*,*)
  write(*,*)achar(27)//'[34m================================================'
  write(*,*)'Reading physical parameters: block PHYS'
  write(*,*)'================================================'//achar(27)//'[0m'

599 read(33,'(a4,f20.0)',err=600,end=600)para,arg
  SELECT CASE (para)
      CASE('GPES')
          pes_xyz=idint(arg)
          write(*,*)'PHYS-Info  New value for gravity  orientation :', pes_xyz
      CASE('MODE')
          imodel_phy=idint(arg)
          write(*,*)'PHYS-Info  New physical model     :',imodel_phy
          IF (imodel_phy.eq.1) THEN
            nvar=3
            inoncons_phy=1
          ENDIF
      CASE('PREF')
          p0_phy=arg
          write(*,*)'PHYS-Info  New reference pressure :',p0_phy
      CASE('REFA')
          rho0A_phy=arg
          write(*,*)'PHYS-Info  New air density :',rho0A_phy
      CASE('REFW')
          rho0W_phy=arg
          write(*,*)'PHYS-Info  New water density:',rho0W_phy
      CASE('CSSM')
          c_phy=arg
          write(*,*)'PHYS-Info  New mixture sound speed :',c_phy
      CASE('SHAR')
          sharp_phy=arg
          write(*,*)'PHYS-Info  New sharpening parameter:',sharp_phy
      CASE('WLTR')
          hzero_phy=arg
          write(*,*)'PHYS-Info   New water level truncation value :',hzero_phy
      CASE('FRMO')
          ifrict=int(arg)
          write(*,*)'PHYS-Info Friction Model 0/none, 1/Manning-Strickler, 2/Darcy-Weisbach:',ifrict
      CASE('BAGR')
          ngrad_bathy=int(arg)
          write(*,*)'PHYS-Info Bathymetry gradient 0/given, 1/approximated :',ngrad_bathy
          
      CASE DEFAULT
          goto 600
  END SELECT
  
  ! petite verification
  IF (nvar.gt.nvarmax)call print_err('READ_PHYS','nvar is bigger than nvarmax ')
  goto 599
600 continue
!===========================   FIN DE LA ROUTINE    ====================
END SUBROUTINE read_phys
!DOCFIN