WriteField Subroutine

public subroutine WriteField(P, NRz, NRr, iRec)

Arguments

Type IntentOptional Attributes Name
complex, intent(in) :: P(NRz,NRr)
integer, intent(in) :: NRz
integer, intent(in) :: NRr
integer, intent(inout) :: iRec

Source Code

  SUBROUTINE WriteField( P, NRz, NRr, IRec )

    ! Write the field to disk

    INTEGER, INTENT( IN )    :: NRz, NRr        ! Number of receiver depths, ranges
    COMPLEX, INTENT( IN )    :: P( NRz, NRr )   ! Pressure field
    INTEGER, INTENT( INOUT ) :: iRec            ! last record read
    INTEGER                  :: iRz

    DO iRz = 1, NRz
       iRec = iRec + 1
       WRITE( SHDFile, REC = iRec ) P( iRz, : )
    END DO

  END SUBROUTINE WriteField