Hello,
I'm beginner in fortran language programming.
I'm trying to use a spatially varying wind drag coefficient. In order to do this i tried using filpol in prosou.
My code looks like this :
IF(VENT) THEN
NSOM = 4
XSOM(1) = 465100.D0
YSOM(1) = 5565000.D0
XSOM(2) = 509800.D0
YSOM(2) = 5580000.D0
XSOM(3) = 509800.D0
YSOM(3) = 5620000.D0
XSOM(4) = 465100.D0
YSOM(4) = 5620000.D0
DRAG = 3.2D-6
!
CALL FILPOL( FAIR , DRAG , XSOM , YSOM , NSOM , MESH )
! SECTION SUD
NSOM = 4
XSOM(1) = 465100.D0
YSOM(1) = 5523000.D0
XSOM(2) = 509800.D0
YSOM(2) = 5529000.D0
XSOM(3) = 509800.D0
YSOM(3) = 5580000.D0
XSOM(4) = 465100.D0
YSOM(4) = 5565000.D0!
CALL FILPOL( FAIR , DRAG , XSOM , YSOM , NSOM , MESH )
!
! TEMPORARY TREATMENT OF TIDAL FLATS
! THE WIND EFFECT IS ONLY CONSIDERED IF THE WATER DEPTH IS
! GREATER THAN 1 M.
!
! ASSUMES HERE THAT THE WIND IS GIVEN IN P1
!
DO N=1,NPOIN
IF (HN%R(N).GT.HWIND) THEN
WD = SQRT( WINDX%R(N)**2 + WINDY%R(N)**2 )
FU%R(N) = FU%R(N) + FAIR * WINDX%R(N) * WD / HN%R(N)
FV%R(N) = FV%R(N) + FAIR * WINDY%R(N) * WD / HN%R(N)
ENDIF
ENDDO
!
ENDIF
However, I get the following error code saying i'm passing REAL(8) to FAIR, which is not the case since DRAG is initialized as DOUBLE PRECISION.
t2dfort.f:859.19:
CALL FILPOL( FAIR , DRAG , XSOM , YSOM , NSOM , MESH )
1
Error: Type mismatch in argument 'f' at (1); passed REAL(8) to TYPE(bief_obj)
t2dfort.f:870.19:
CALL FILPOL( FAIR , DRAG , XSOM , YSOM , NSOM , MESH )
1
Error: Type mismatch in argument 'f' at (1); passed REAL(8) to TYPE(bief_obj)
... The following command failed for the reason above
Any help would be appreciated
Thanks