Welcome, Guest
Username: Password: Remember me

TOPIC: Wave height changing at the boundary

Wave height changing at the boundary 12 years 9 months ago #3642

  • OGW
  • OGW's Avatar
Hello, I am trying to change the wave height on my model boundary. I understand that I need to specify a 'formatted file 1' in my steering file and that I also need to modify the Limwac.f subroutine. I am unsure of how to modify Limwac to read in wave variables every hour of my model simulation. Are there any test examples or can any one explain how this should be done?

Many thanks
The administrator has disabled public write access.

Re: Wave height changing at the boundary 12 years 9 months ago #3730

  • glejin
  • glejin's Avatar
Hai,

I also stuck with the same problem of giving temporal varying wave height at the boundary.Expecting advices on this problem.

Kindly,

Glejin
The administrator has disabled public write access.

Re: Wave height changing at the boundary 12 years 9 months ago #3750

  • dougcresswell
  • dougcresswell's Avatar
Hi,

we are also looking at doing this. I think you need to populate variables HM0L (Hm0), FPICL (peak frequency), TETA1L (direction, in radians) in subroutine limwac. They are scalars, so a time loop needs to be added comparing model time (AT) with input data. The data could be listed in the routine, for testing, and if simple, or read in from a file.

I hope that's useful,

Doug
The administrator has disabled public write access.

Re: Wave height changing at the boundary 12 years 9 months ago #3751

  • giovanni.mattarolo
  • giovanni.mattarolo's Avatar
Hello,

I wrote this message in the forum that describes the basic approach to set boundary conditions varying in time. I copy and paste :

The simplest case is to impose non-stationary (varying with the time) and uniform (same value at each point of the boundaries) boundary conditions. In this case what you could do is to read the boundary conditions from a formatted file (e.g. a .txt file) that you create and in which, at each line, you specify the time step and the corresponding reduced input spectral parameters (significant wave height, peak period, mean propagation direction, ...).
The steps to follow are:
  1. you create your formatted file with the time depending boundary conditions
  2. in the steering file you specify the name of this formatted file via the keyword FORMATTED FILE 1 (see chapter 7.2.13 of the TOMAWAC guide)
  3. you modify LIMWAC in order to manage the read operations of this file within the FORTRAN program: at each time step LIMWAC read the spectral parameters from the file and use them as argument variables in the call to SPEINI.

Now, let's take the case of a model having boundary conditions that are constant in space (same values over all the boundaries) and varying in time, and let's suppose that you have your formatted file with the time series of the spectral parameters needed to define the boundary conditions in TOMAWAC.

TOMAWAC makes use of the formatted file at the step n°7 of WAC.f, when the boundary conditions are initialized via the call to LIMWAC, and at the step 11.2 of WAC.f, when the boundary conditions are updated at each time step, again via LIMWAC.

LIMWAC should be modified, in order to read the time series of the spectral parameters in the formatted file and to interpolate those values for each TOMAWAC simulation time step.
A basic example of this approach, which shows the way LIMWAC should be modified, is given here below:
IF (simulation time of TOMAWAC T.EQ.0) THEN
	READ the header of formatted file
	READ the spectral parameters values at the first time step T1 from the formatted file
	READ the spectral parameters values at the next time step T2 from the formatted file
    ENDIF
50  CONTINUE
	IF (TOMAWAC time T is included in the interval T1<=T<T2) GOTO 60
	T1 = T2
	spectral parameters at time T1 = spectral parameters at time T2
	READ the next time step T2 of the formatted file and the parameters associated
	GOTO 50
60  CONTINUE
    Interpolate the spectral parameters read from the formatted file at T1 and T2,
      at the time T of the TOMAWAC simulation
    Assign the values so calculated to the variables passed to SPEINI.f (HM0L, FPICL, TETA1L, …)

If you want to impose boundary conditions that vary not only in time, but also in space (spectra are not constant over the boundary nodes), the approach to follow is similar, but in this case you have to modify the code and, at each time step, make a loop over the boundary nodes.
Hope it helps.
Kind regards,

Giovanni
The administrator has disabled public write access.

Re: Wave height changing at the boundary 12 years 9 months ago #3759

  • OGW
  • OGW's Avatar
Thanks for your help with this problem, it appears to be working well now.

Oliver
The administrator has disabled public write access.

Re: Wave height changing at the boundary 12 years 7 months ago #4117

  • pprel
  • pprel's Avatar
Hello,
I want to propagate waves from offshore to the coast.
I have two points where I know the wave characteristics. I would like to change wave height along my liquid boundary to apply my wave charateristics. Also when water depth is too small along the boundary, I have to put a smaller wave height I think.

To do so, I have modified limwac.f [attached] but I had to do it outside the user modifying part. I create a .txt file that give Hm0, Tp, Gamma, Theta1, s1 for each points of the boundary. It works but since tomawac run limwac for each time step and limwac calls speini as many times as there is points in the liquid boundary, it takes VEEEEEEERY long time (and my mesh is still loose). Since I don't use wind or current, it should not have to update boundaries at each time step, right ?
Do you have any idea how I could reduce the time of calculation.
I use g95.

Thank you very much to any help,
Pauline
The administrator has disabled public write access.

Re: Wave height changing at the boundary 12 years 7 months ago #4118

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
Hi

You could add wac.f in your fortran file and change the call to limwac or maybe change the call to speini in limwac to just call it once.

Hope this helps
Christophe
The administrator has disabled public write access.

Re: Wave height changing at the boundary 12 years 6 months ago #4425

  • shanaspr
  • shanaspr's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 9
Hi Pauline


I am also trying to run the model with time series wave conditions.
If u could send me the modified limwac as in your case it will be helpful for me....


thanks in advance

shanas
The administrator has disabled public write access.

Re: Wave height changing at the boundary 12 years 6 months ago #4428

  • pprel
  • pprel's Avatar
Dear Shanas

Please, note that I'm not using wave conditions varying in time but varying in space. This is pretty different.
Nevertheless, I can send you how I modify the limwac subroutine. Maybe it could give you some ideas.
I must emphasize that I wrote it to use it, not to pass it on so it is likely that it is very disordered and disorganized but though I don't have time right now to tidy it up (besides, organizing myself is not one of my skills).
You have to you use it with a formatted file (exemple lim.txt).
I hope it helps and I can only repeat that this is NOT professional work.

Kind regards,

Pauline
Attachments:
The administrator has disabled public write access.

Re: Wave height changing at the boundary 12 years 6 months ago #4429

  • shanaspr
  • shanaspr's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 9
:cheer: hai Pauline :cheer:

I just need that format only,I think it will surely help my task >

Thanks alot for your time

regards
shanas
The administrator has disabled public write access.
Moderators: tfouquet

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