test_vgrid.m

General scientific issues regarding ROMS

Moderators: arango, robertson

Post Reply
Message
Author
fdaryabor
Posts: 78
Joined: Wed Jan 02, 2008 3:15 pm
Location: University of Copenhagen

test_vgrid.m

#1 Unread post by fdaryabor »

Hi
I'm going to test the effects of theta_s,theta_b,hc and N by using '../Preprocessing/test_vgrid.m', but doesn't exist this script in directory.
Could you guide me

Best Regards
F.Daryabor

ocecept
Posts: 42
Joined: Tue Jan 08, 2008 3:57 pm
Location: Universidade Federal do Ceará
Contact:

Re: test_vgrid.m

#2 Unread post by ocecept »

Hi Daryabor;

I have used scoord.m to test these coordinates parameters. It's located in http://www.myroms.org/software/Processi ... lab.tar.gz.

Cheers
Carlos Teixeira, PhD
Instituto de Ciências do Mar - LABOMAR
Universidade Federal do Ceará
Brazil

fdaryabor
Posts: 78
Joined: Wed Jan 02, 2008 3:15 pm
Location: University of Copenhagen

Re: test_vgrid.m

#3 Unread post by fdaryabor »

Hi
Thanks so much for your guide.
Could you explain me, how can I use from this tool (scoord.m) for test theta_s,theta_b,hc and N?
Best Regards
F.Daryabor

ocecept
Posts: 42
Joined: Tue Jan 08, 2008 3:57 pm
Location: Universidade Federal do Ceará
Contact:

Re: test_vgrid.m

#4 Unread post by ocecept »

Hi Daryabor;

I started using ROMs few months ago, so I'm not an expert. I will tell you what I did and people are free to correct it.

First read these posts viewtopic.php?f=14&t=76&hilit=scoord; viewtopic.php?f=14&t=612&hilit=haney and https://www.myroms.org/wiki/index.php/S-coordinate.

Scoord.m will plot the vertical grid (s-surfaces) using your depth information and the parameters theta_s,theta_b,hc and N you chose based on the problem you want to solve with your model. Have a look if the s-surfaces look good.

Run the model, look the Beckmann and Haidvogel numbers and see what happens.

In my case, I'm studding the exchanges between one gulf and the shelf. My grid extends from 30m to 1000m. I'm using an idealized initial temperature and salinity field that change with depth in the first 30m and are homogeneous after that. I had to work a lot with theta_s and theta_b to solve the temp. and sal. fields and avoid pressure gradient problems. I'm using 15 levels, theta_s=7, theta_b=0.4 and hc=30m.

Good luck
Carlos Teixeira, PhD
Instituto de Ciências do Mar - LABOMAR
Universidade Federal do Ceará
Brazil

fdaryabor
Posts: 78
Joined: Wed Jan 02, 2008 3:15 pm
Location: University of Copenhagen

Re: test_vgrid.m

#5 Unread post by fdaryabor »

Hi
Thanks so much my friend.
I defined function parameters
[z,sc,Cs]=scoord(h,theta_s,theta_b,Tcline,N,kgrid,column,index,plt)
but when I want plot S-coordinate I face with following error:

>>[z,sc,Cs]=scoord(40,6,0.4,10,15,0,0,1,1)
??? Error using ==> set
Bad value for axes property: 'XLim'
Values must be increasing and non-NaN.

Error in ==> scoord at 230
set(gca,'xlim',[0 Lp-1],'ylim',[zmin 0]);
could you please help me for resolve my problem

Best Regards
F.Daryabor

ocecept
Posts: 42
Joined: Tue Jan 08, 2008 3:57 pm
Location: Universidade Federal do Ceará
Contact:

Re: test_vgrid.m

#6 Unread post by ocecept »

Hi Daryabor;

>>[z,sc,Cs]=scoord(40,6,0.4,10,15,0,0,1,1)
>>??? Error using ==> set
>>Bad value for axes property: 'XLim'
>>Values must be increasing and non-NaN.

Instead of 40 you have to enter your depth matrix.

[z,sc,Cs]=scoord(h,theta_s,theta_b,Tcline,N,kgrid,column,index,plt);

if column = 1 -> you will plot a column section based on depths h(:,index)
if column = 0 -> you will plot a row section based on depths h(index,:)

Cheers

Carlos

fdaryabor
Posts: 78
Joined: Wed Jan 02, 2008 3:15 pm
Location: University of Copenhagen

Re: test_vgrid.m

#7 Unread post by fdaryabor »

Hi
1- do you defined your grid from 30m under surface to 1000m?
2- Is shallow water your study region ?
3- Is concept of h, study region depth?
when I want set teta_s and teta_b for 5000m depth and switch index=0 for both column section and row section I face following error:
>> [z,sc,Cs]=scoord(5000,7,0.5,30,15,0,1,0,0)

*** Error: SCOORD - illegal column index.
valid range: 1 <= index <= 1

??? Output argument "z" (and maybe others) not assigned during call to "/root/ROMSTOOLS/matlab/tools/scoord.m (scoord)".

Error in ==> scoord at 51
c1=1.0;

>> [z,sc,Cs]=scoord(5000,7,0.5,30,15,0,0,0,0)

*** Error: SCOORD - illegal column index.
valid range: 1 <= index <= 1

??? Output argument "z" (and maybe others) not assigned during call to "/root/ROMSTOOLS/matlab/tools/scoord.m (scoord)".

Error in ==> scoord at 51
c1=1.0;


I want set my grid for 40m depth to 5000m depth could you please tell me how set teta_s and theta_b

Best Regards
F.Daryabor

Post Reply