Welcome, Guest
Username: Password: Remember me

TOPIC: Graphic printout period using variable time step

Graphic printout period using variable time step 3 years 2 months ago #39149

Hello everyone,

Is there any way to save outputs at a constant interval, let say after each 24 h at 00:00 O'clock, using variable time step?

It is definitely possible by using a constant time step (output saving interval [seconds]=time step * graphic printout period); however, the computational time is high using this option.

I mean, is there any way to adjust the graphic printout period somewhere in a subroute so that I can have output after specific intervals.

I thank you for your support!

Ateeq
The administrator has disabled public write access.

Graphic printout period using variable time step 2 years 11 months ago #39396

I tried to make the following editions for saving my results after a constant interval using VARIABLE TIME-STEP=YES. Apparently, I am able to save outputs after every 3600 seconds.

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
C LISTING PRINTOUT PERIOD at a constant interval using variable time step, I need to only update the following line in TELEMAC SUBROUTINE:

INTEGER AQ_AT,AQ_ATT,AQ_DIFF,AT_DIFF_K,AQ_DUPLICATE
C ORIGINAL CODE
C IF((LISPRD*(LT/LISPRD).EQ.LT.AND.LT.GE.PTINIL).OR.LT.EQ.NIT) THEN
C ENTET=LISTIN
C ELSE
C ENTET=.FALSE.
C ENDIF
!ORIGINAL- ENDS
WITH
!EDIT FOR PRENTOUT WITH VARIABLE TIME STEP
AQ_ATT=(INT(AT)/INT(LISPRD))*INT(LISPRD)
AQ_AT=INT(AT)
AQ_DIFF=ABS(AQ_AT-AQ_ATT)
AT_DIFF_K=INT(DT)!Thresh hold coefficient
IF(LT.EQ.1)THEN
AQ_DUPLICATE=AQ_DIFF
ENDIF
IF((AQ_DIFF.LE.AT_DIFF_K.AND.AQ_DUPLICATE.NE.AQ_ATT.
& AND.LT.GE.PTINIL).OR.LT.EQ.NIT) THEN
ENTET=LISTIN
AQ_DUPLICATE=AQ_ATT!Avoid many saving/printing when DT<1 AS AQ_DIFF IS INT.
ELSE
ENTET=.FALSE.
ENDIF
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
C For graphics printout at a constant interval using variable time step, I need to update the following code in SUBROUTINE PRERES_TELEMAC2D:
INTEGER AQ_AT,AQ_ATT,AQ_DIFF,AT_DIFF_K!AQ=EDITION
INTEGER AQ_DUPLICATE1!EDIT
SAVE AT_DIFF_K,AQ_DUPLICATE1!EDIT


! Always write the initial conditions
IF(LT.EQ.0) THEN
IMP=.TRUE.
LEO=.TRUE.
COMPLEO=0
ELSE
IF(EQUA(1:15).NE.'SAINT-VENANT VF') THEN
! FEM
AQ_ATT=(INT(AT)/INT(LISPRD))*INT(LISPRD)!EDIT
AQ_AT=INT(AT)!EDIT
AQ_DIFF=ABS(AQ_AT-AQ_ATT)!EDIT
AT_DIFF_K=INT(DT)!!EDIT Thresh hold coefficient set by.
LTT=(LT/LISPRD)*LISPRD
IF(LT.EQ.LTT.AND.LT.GE.PTINIL) IMP=.TRUE.
LTT=(LT/LEOPRD)*LEOPRD
C IF(LT.EQ.LTT.AND.LT.GE.PTINIG) LEO=.TRUE.!ORIGINAL
IF(LT.EQ.1)THEN!EDIT
AQ_DUPLICATE1=AQ_DIFF!EDIT
ENDIF!EDIT
IF(AQ_DIFF.LE.AT_DIFF_K.AND.AQ_DUPLICATE1.NE.AQ_ATT.
& AND.LT.GE.PTINIG) LEO=.TRUE.!EDIT
IF(LEO)THEN!EDIT
AQ_DUPLICATE1=AQ_ATT!!EDIT Avoid many saving/printing when DT<1 AS AQ_DIFF IS INT
ENDIF!EDIT
! FOR GRAPHICAL OUTPUTS
IF(LEO)COMPLEO=COMPLEO+1
ELSE


C And SUBROUTINE BIEF_DESIMP should be updated with the following lines. The subroutine can be found in C:\opentelemac-mascaret\v7p2r0\sources\utils\bief
! LOGICAL THAT DEFINE THE OUTPUTS
!
&(FORMAT_RES,VARSOR,N,NRES,STD,AT,LT,LISPRD,LEOPRD,
& SORLEO,SORIMP,MAXVAR,TEXTE,PTINIG,PTINIL,MESH,
& IIMP,ILEO,COMPGRAPH)



INTEGER AQ_AT,AQ_ATT,AQ_DIFF,AT_DIFF_K,AQ_DUPLICATE

IF(PRESENT(IIMP).AND.PRESENT(ILEO))THEN
IMP=IIMP
LEO=ILEO
ELSE
IMP=.FALSE.
LEO=.FALSE.
AQ_ATT=(INT(AT)/INT(LISPRD))*INT(LISPRD)
AQ_AT=INT(AT)
AQ_DIFF=ABS(AQ_AT-AQ_ATT)
IF(LT.EQ.1)THEN
AQ_DUPLICATE=AQ_DIFF
ENDIF
LTT=(LT/LISPRD)*LISPRD
IF(LT.EQ.LTT.AND.LT.GE.PTINIL) IMP=.TRUE.
LTT=(LT/LEOPRD)*LEOPRD

IF(AQ_DIFF.LE.AT_DIFF_K.AND.AQ_DUPLICATE.NE.AQ_AT.
& AND.LT.GE.PTINIG) LEO=.TRUE.
!SAVE LAST AQ_DIFF
IF(LEO)THEN
AQ_DUPLICATE=AQ_AT!Avoid many saving/printing when DT<1 AS AQ_DIFF IS INT
ENDIF

C IF(LT.EQ.LTT.AND.LT.GE.PTINIG) LEO=.TRUE.!ORIGINAL
IF(LT.EQ.0) LEO=.TRUE.
ENDIF
The administrator has disabled public write access.

Graphic printout period using variable time step 2 years 11 months ago #39448

Hello,
Can you try to replace line 1707 of telemac2d.F:
IF(NCP.NE.0.AND.(ENTET.OR.CUMFLO)) THEN
by:
IF(NCP.NE.0.AND.(LEO.OR.CUMFLO)) THEN
so the control section management is controled by the GRAPHIC PRINTOUT PERIOD instead of the LISTING PRINTOUT PERIOD. The graphic printout period being controlled by the TIME STEP set in the cas file, and not the computed time step, it could work.
I also invite you to take a look to this topic : www.opentelemac.org/index.php/kunena/16-...on-output-in-fv-mode

Best regards,

Florent
The administrator has disabled public write access.
The following user(s) said Thank You: sardar.ateeq
Moderators: pham

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