Welcome, Guest
Username: Password: Remember me

TOPIC: Initial conditions - modifying confin.f

Initial conditions - modifying confin.f 8 years 1 month ago #23935

  • kingja.x
  • kingja.x's Avatar
Hi all,

Sorry if this post is duplicating a previous one but I have searched the forum and can't find exactly what I need, though post #19749 comes close.

I have a large tidal domain and am trying to introduce a number of river inflow boundaries. I have discharge-time series for these though as I understand the cells must be initially wet at t=0 to impose a discharge boundary condition.

Rather than flood the domain to an unrealistic level and let water drain out (as I have had problems with this) am trying to modify condin.f to assign a small depth of water at the river boundary cells which are dry at the start of my computation.

I have attached my modified confin.f file though when I try and compile I get the following error:


ERROR.jpg

!
!  TO BE MODIFIED BY USER IF SPECIAL INITIAL CONDITIONS
! 
!  IF INITIAL WATER DEPTH <= 0: INITIAL ELEVATION (COTINI) - BOTTOM TOPOGRAPHY (ZF)
!  .AND. IF POINT IS WITHIN SPECIFIED REGION THEN
!  SET INITIAL WATER DEPTH 0.1M ABOVE BOTTOM TOPOGRAPHY (ZF)
!  ELSE SET INITIAL WATER LEVEL TO INITIAL ELEVATION (CONTINI)
! 
        IF((COTINI-ZF<=0).AND.(INPOLY(X,Y,XSOM,YSOM,NSOM))) THEN
			CALL OS( 'X=Y+C   ' , H , ZF , H , 0.1DO   )
		ELSE
			CALL OS( 'X=C     ' , H , H  , H , COTINI )
			CALL OS( 'X=X-Y   ' , H , ZF , H , 0.D0   )
		END IF

        IF(LNG.EQ.1) WRITE(LU,10)
        IF(LNG.EQ.2) WRITE(LU,11)
10      FORMAT(1X,'CONDIN : AVEC DES CONDITIONS INITIALES PARTICULIERES'
     &         ,/,'         VOUS DEVEZ MODIFIER CONDIN')
11      FORMAT(1X,'CONDIN : WITH SPECIAL INITIAL CONDITIONS'
     &         ,/,'         YOU HAVE TO MODIFY CONDIN')
		
        CALL PLANTE(1)
        STOP
!
!  END OF CODE TO BE MODIFIED BY USER
!

I have obviously made an error in calling X and Y which according to declarations_telemac.f are pointers to the node coordinates. Being fairly new to FORTRAN I'm not sure what I need to change to that for each cell the code performs the check I want and assigns the initial water level accordingly.

The other alternative is to explicitly assign an initial water level to the cells I want (there are only 8) but I'm even more unsure of how to do this.

Many thanks
Jon
Attachments:
The administrator has disabled public write access.

Initial conditions - modifying confin.f 8 years 1 month ago #23937

  • josekdiaz
  • josekdiaz's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 161
  • Thank you received: 48
Dear Jon,

If assigning a Water depth (or rather set a Free Surface and let telemac do the math in that nodes), I think modifying condin.f is an overkill.

This procedure can be done using Bluekenue or even Fudaa.

In fudaa just right click the mesh (when setting up the case) and click "Enable initial condition", just select a surface plane set to 0 or something, and then in the righ panel select "initial conditions" and below that is "Initial conditions value" then click the 8 nodes you want to modify and right-click edit on them. Specify a free surface.

The output of the process is a "condInit.ser" in the root directory of your cas file which has the initial condition in the nodes.

Btw, The option "remove negative water depths" option in Fudaa menu is specially useful in that procedure.

regards,

José Diaz.
The administrator has disabled public write access.
The following user(s) said Thank You: kingja.x

Initial conditions - modifying confin.f 8 years 1 month ago #23942

  • kingja.x
  • kingja.x's Avatar
Hi Jose,

That sounds a lot easier. I didn't realise that was possible so will take a look.

Many thanks
Jon
The administrator has disabled public write access.
Moderators: pham

The open TELEMAC-MASCARET template for Joomla!2.5, the HTML 4 version.