calculating ubar and vbar
-
- Posts: 128
- Joined: Tue Feb 01, 2005 8:21 pm
- Location: Istanbul Technical University (ITU)
- Contact:
calculating ubar and vbar
Hi,
I want to calculate ubar and vbar using u and v. Is it calculated using following formula,
ubar = ubar + u*dz
vbar = vbar + v*dz
but in this case the units of the 2d vertical integrated momentum component will be m2/s (m/s * m) because we multiply with the thickness of the layer. In climatology package the unit of ubar and vbar is in m/s. Which one is correct? May be the formula is wrong and you can provide me the correct one.
Thanks,
I want to calculate ubar and vbar using u and v. Is it calculated using following formula,
ubar = ubar + u*dz
vbar = vbar + v*dz
but in this case the units of the 2d vertical integrated momentum component will be m2/s (m/s * m) because we multiply with the thickness of the layer. In climatology package the unit of ubar and vbar is in m/s. Which one is correct? May be the formula is wrong and you can provide me the correct one.
Thanks,
Re: calculating ubar and vbar
In step3d_uv:
CF = CF + Hz
DC = DC + u*Hz
ubar = DC/CF (more or less)
CF = CF + Hz
DC = DC + u*Hz
ubar = DC/CF (more or less)
Re: calculating ubar and vbar
hi,
is there any update of calculatung ubar and vbar by u and v?
or is there any recommendation for me to refer to?
thank you
is there any update of calculatung ubar and vbar by u and v?
or is there any recommendation for me to refer to?
thank you
- arango
- Site Admin
- Posts: 1367
- Joined: Wed Feb 26, 2003 4:41 pm
- Location: DMCS, Rutgers University
- Contact:
Re: calculating ubar and vbar
Look at Nonlinear/ini_fields.F instead. It is very clear how it is computed there. It is how the inital ubar anf vbar is computed in ROMS.
Re: calculating ubar and vbar
Sorry, I think I am going to ask some silly questions since I am not that understand the flow.
Currently, I have download data like zeta, u v current, temp and salinity from MERCATER, yet some error occur when I used the mercator2roms.m.
Since I am not a MATLAB expert, I decided to rewrite the script using python.
However, I meet some problem in understanding the calcutation in ubar and vbar.
When look into the script INI_FIELD.F, I wonder will ROMS calculate ubar and vbar itself if the initial file contains u and v data.
How should I modified my header file if so.
Thank you very much.
Currently, I have download data like zeta, u v current, temp and salinity from MERCATER, yet some error occur when I used the mercator2roms.m.
Since I am not a MATLAB expert, I decided to rewrite the script using python.
However, I meet some problem in understanding the calcutation in ubar and vbar.
When look into the script INI_FIELD.F, I wonder will ROMS calculate ubar and vbar itself if the initial file contains u and v data.
How should I modified my header file if so.
Thank you very much.
Re: calculating ubar and vbar
To make it clear, here is the error when I tried to convert MERCATOR to ROMS initial file.
However, I cannot upload my nc file even after zipping it.
In an assignment A(:) = B, the number of elements in A and
B must be the same.
Error in mercator2roms (line 188)
Fwork(indnan(m))=Fwork(indwet(near));
Error in d_mercator2roms_update (line 225)
temp=mercator2roms('temp',S,Temp,Tlon,Tlat,Rmask3d,Tdepth);
Error in run (line 96)
evalin('caller', [script ';']);
Thank you.
However, I cannot upload my nc file even after zipping it.
In an assignment A(:) = B, the number of elements in A and
B must be the same.
Error in mercator2roms (line 188)
Fwork(indnan(m))=Fwork(indwet(near));
Error in d_mercator2roms_update (line 225)
temp=mercator2roms('temp',S,Temp,Tlon,Tlat,Rmask3d,Tdepth);
Error in run (line 96)
evalin('caller', [script ';']);
Thank you.
- Attachments
-
- grid13_gebco_smooth4.nc
- (64 KiB) Downloaded 342 times
-
- d_mercator2roms_update.m
- (11.14 KiB) Downloaded 354 times
-
- mercator2roms.m
- (6.4 KiB) Downloaded 363 times
Re: calculating ubar and vbar
To update, the error has been solved.
Yet , when I used the new initial file, a new error popped up.
Please have a look if you have any idea to solve it. Thank you.
Yet , when I used the new initial file, a new error popped up.
Please have a look if you have any idea to solve it. Thank you.
- Attachments
-
- temp.txt
- (56.85 KiB) Downloaded 371 times
Re: calculating ubar and vbar
Code: Select all
STEP Day HH:MM:SS KINETIC_ENRG POTEN_ENRG TOTAL_ENRG NET_VOLUME
C => (i,j,k) Cu Cv Cw Max Speed
144 1 00:00:00 NaN NaN NaN 5.758336E+16
(163,187,19) 2.195484E-02 1.405542E-02 0.000000E+00 1.002493E+00
Re: calculating ubar and vbar
Thank you for your reply.
I have solved it by using ANA_INITIAL in my header file.
I have solved it by using ANA_INITIAL in my header file.
-
- Posts: 88
- Joined: Wed Oct 01, 2014 8:57 pm
- Location: International Coastal Research Center
Re: calculating ubar and vbar
I'd like to clarify what you meant as you seemed to be using an initial condition file earlier. So instead of using an initial condition file, you edited ana_initial.h to input your desired initial conditions?venuscheung wrote: ↑Wed Dec 25, 2019 6:08 am Thank you for your reply.
I have solved it by using ANA_INITIAL in my header file.
Re: calculating ubar and vbar
yes, I put ana_initial in my header file, yet the result show that the model seems starting from a new initial condition that salinity = 35 and sst = 17.lcbernardo wrote: ↑Thu Dec 26, 2019 7:18 amI'd like to clarify what you meant as you seemed to be using an initial condition file earlier. So instead of using an initial condition file, you edited ana_initial.h to input your desired initial conditions?venuscheung wrote: ↑Wed Dec 25, 2019 6:08 am Thank you for your reply.
I have solved it by using ANA_INITIAL in my header file.
should use other initial condition instead of ana_initial