Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1
  • 2

TOPIC: Sea water temperature

Sea water temperature 8 years 9 months ago #19616

  • pietrof
  • pietrof's Avatar
Hi,
I don't understand what is the procedure to set thermal and salinity stratification, to simulate a thermocline .
regards
The administrator has disabled public write access.

Sea water temperature 8 years 9 months ago #19620

  • jmhervouet
  • jmhervouet's Avatar
Hello,

The best is to prescribe horizontal planes in the mesh, so that you can easily initialise plane by plane the thermocline and salinity in subroutine condim.f. Then be aware that vertical diffusion will always destroy the thermocline, unless there are forcing terms like the exchanges with atmosphere.

With best regards,

Jean-Michel Hervouet
The administrator has disabled public write access.

Sea water temperature 5 years 2 weeks ago #34903

  • thomas.bockel
  • thomas.bockel's Avatar
Hello,

Working on the same type of problem I tried to implement "M.Mire" solution for stable stratification of sea water temperature.

I however run on this error:
compiling: condim_modif_test.fcondim_modif_test.f:205.20:

ELSEIF(MESH3D%Z%R(J).LT.-9.D0.AND.MESH3D%Z%R(J).GT.-21) TH
1
Error: Unexpected junk after ELSE statement at (1)

Could that be because I dont prescribe tracer values for my boundaries?
Enclosed my cas and fortran.
Thanks a lot.

Thomas
Attachments:
The administrator has disabled public write access.

Sea water temperature 5 years 2 weeks ago #34904

  • PMV
  • PMV's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 149
  • Thank you received: 42
There is a maximum number of caracters per line in FORTRAN code allowed (73 I believe). Therefore FORTRAN is cutting the line midway through the word THEN at line 205.

If you remove spaces before the statement you should be fine, or you break it over two lines using &

You should do the same on line 207.

Hope it helps,

Patrick
The administrator has disabled public write access.

Sea water temperature 5 years 2 weeks ago #34905

  • pham
  • pham's Avatar
  • OFFLINE
  • Administrator
  • Posts: 1559
  • Thank you received: 602
Hello,

Patrick is nearly right. The maximum number of characters per line is 72 for FORTRAN files in your case (that is what the error message says) + steering files. You have the same error in your modified lines in BORD3D.

Anyway, ban tabulations in your ASCII files (FORTRAN FILES, STEERING FILES...), it prevents from errors with TELEMAC.

If I may, I have a few suggestions in your FORTRAN FILE. You do not need to rename the modified subroutines if you do not change the number of arguments (e.g. CONDI3DTRAC or MESH_TRANSF) as you do for BORD3D or CONDIM.
When manipulating floats, as they all are double precision (except reading or writing floats in SERAFIN single precision), you should add .D0 suffix (or with the exponent) for floats.

Your conditions over the vertical for the initial and boundary conditions are strange.
Rather than tests if var > -10 elseif -21 < var < -9 else if < -40 var < -20... with overlap, you should rather write if var var > -10 elseif -21 < var <= -10 else if < -40 var <= -21... that should give you the same, but is clearer to read, in particular for the intervals [-10;-9] and [-21;20].

Hope this helps,

Chi-Tuan
The administrator has disabled public write access.
The following user(s) said Thank You: thomas.bockel

Sea water temperature 5 years 1 week ago #34922

  • Yunhao Song
  • Yunhao Song's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 118
  • Thank you received: 9
Hello Chi-Tuan,

I allowed myself to continue this post cause I'm wondering if there is any example about setting the tracers boundary condition varying in both space and time. In my case I got weekly measured water temperature and other water quality parameters at the upper boundary of a river, those parameters varied along the depth.

Best,
Yunhao
The administrator has disabled public write access.

Sea water temperature 5 years 1 week ago #34933

  • pham
  • pham's Avatar
  • OFFLINE
  • Administrator
  • Posts: 1559
  • Thank you received: 602
Hello Yunhao,

There is no example which perfectly match what you want to do, but as you have boundary conditions varying in both space and time, you must have a look at what is done in the BORD3D subroutine.

You can see 2 possibilities:
- have a BINARY BOUNDARY DATA FILE to store your temperature and water quality parameters (you must fit the expected format),
- implement what you want to read and how it has to be taken into account in a USER_BORD3D subroutine. You have some simple examples in Viollet, stratification or tetra TELEMAC3D examples, which may help you to start.

Hope this helps,

Chi-Tuan
The administrator has disabled public write access.
The following user(s) said Thank You: Yunhao Song

Sea water temperature 5 years 1 week ago #34940

  • Yunhao Song
  • Yunhao Song's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 118
  • Thank you received: 9
Hello Chi-Tuan,

Thank you for the quick answer, could you be more specific on creating the BINARY BOUNDARY DATA FILE as I'm quite new to this part...

Best regards,
Yunhao
The administrator has disabled public write access.
  • Page:
  • 1
  • 2
Moderators: pham

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