what's wrong with temperature from two version of roms code

Report or discuss software problems and other woes

Moderators: arango, robertson

Post Reply
Message
Author
tony1230
Posts: 87
Joined: Wed Mar 31, 2010 3:29 pm
Location: SKLEC,ECNU,Shanghai,China

what's wrong with temperature from two version of roms code

#1 Unread post by tony1230 »

Hi all,

I was confused by the results from two version(Old:V.549, New:V624) of roms code, running with all the same input files.
The attached are three plots that with model results comparison and data validation.

As i dont know what's wrong with the new code, i set two parallel runs with one set of input files, say grid and initial, wind force, solar shot wave radiation, pressure, etc., only with two different version of codes, and some CPP definitions(there many cpp options removed from Old V.).

See the uppermost plot. This is a one-year model comparison for temperature and silinity from two runs. The discrepancy to temps and salts(TDis and SDis) are much significant, say 4~5 degs to temp that from two runs and nearly 0.5 psu to salt(see second plot). To temperature, the discrepancy from two results get larger and larger at about 30(x-axis) and 370 time point to salinity. The TDis is maninly associated with heat fluxes, and seems get larger with increase in solar shot wave radiation,vice versa.

Within the second plot, time period(x-axis) coincident with the pink-vertical bar in the first plot and both model results are validated with field data(red solid circle). Be notice that two runs spin-up at day Jan 01/2010 and the field gauge conducted in Oct. We can see that the temperatures from Old Version(549) are much consistent with data and 4~5 degs in discrepancy to the run with New code.

The bottommost plot are fluxes from two runs. As there exists such a marked discrepancy in temperature, i had all the heat fluxes checked out for comparison and results were patched in plot. You can see that the solar shot wave radiations are exactly the same in values at any time point(left-middle). And from the surface net heat flux(right-upper), two results are much coincident, but why and how to cause such obvious discrepancies in temperatures :!: :?:

I would be appreciate your help and suggestion.

Thanks in advance.
Best regrads.

Shou
Attachments
One year comparison for both temp and salinity from two runs with Old and New code.
One year comparison for both temp and salinity from two runs with Old and New code.
Field data(temp,salt) compared with its model equivalents.
Field data(temp,salt) compared with its model equivalents.
fluxes from two results for comparison
fluxes from two results for comparison

rduran
Posts: 152
Joined: Fri Jan 08, 2010 7:22 pm
Location: Theiss Research

Re: what's wrong with temperature from two version of roms c

#2 Unread post by rduran »

Shou,

One place to start with would be comparing the CPP defs, do you have them available?

Rodrigo.

tony1230
Posts: 87
Joined: Wed Mar 31, 2010 3:29 pm
Location: SKLEC,ECNU,Shanghai,China

Re: what's wrong with temperature from two version of roms c

#3 Unread post by tony1230 »

Hi rduran

Thanks for your suggestion.

As i mentioned in the earlier thread, i'd gave one set of input files to the two runs but the CPP.h file, since there had updated more times for many CPP options, say *_WALL etc.

As far as i can remember(i can open the files because the cluster was powered off), within the Old version(V.549), i have had
FSCHAPMAN,M2REDUCED
defined but without U,V(M3RADIATION,M3NUDGING etc) and
T,S(TRADIATION,TNUDGING etc)
to be defined. And these options were set fixed in the .in file
within the New version(V.624). Other CPPs should be all coincident which should be defined according to the model configuration(I'll double
check it for insurance tomorrow!)

Bear in mind, the results on temperature are much closer to the file data from run with Old version(though some CPP options related were not defined, so Why :?: )

Another question confused me was from the third plot. See left-middle patch, shot wave radiations have the same values and in the upper-right
patch, the discrepancies between two time-serial values are not that significant to cause such a obvious difference(4-5 degs,upper-left patch)
in temperature.

Any tips and guidance are appreciated.

Shou

User avatar
arango
Site Admin
Posts: 1347
Joined: Wed Feb 26, 2003 4:41 pm
Location: DMCS, Rutgers University
Contact:

Re: what's wrong with temperature from two version of roms c

#4 Unread post by arango »

You need to be sure that you are using the same boundary conditions as before. Now the boundary conditions are specified with switches in standard input script ocean.in. Everything needs to be specified now!!! Before, if an option was not specified it will default to closed boundary conditions for momentum and closed/gradient conditions for tracers and free-surface. You need also to take a look at the volume conservation that it is also in ocean.in. Everything is mentioned in the released notes.

It seems to me that your configuration between old and new version is not identical. Check the Build/*.f90 files and compare. That is what I always do with this type of problem....

rduran
Posts: 152
Joined: Fri Jan 08, 2010 7:22 pm
Location: Theiss Research

Re: what's wrong with temperature from two version of roms c

#5 Unread post by rduran »

Shou

Could you please let us know what differences you find in your Build/*.f90 files?

It is interesting to learn what configuration change would cause the differences.

thanks,

Rodrigo

tony1230
Posts: 87
Joined: Wed Mar 31, 2010 3:29 pm
Location: SKLEC,ECNU,Shanghai,China

Re: what's wrong with temperature from two version of roms c

#6 Unread post by tony1230 »

Yes, i remember that Hernan said many times in some threads that we have to set LBC for every state variable on every boundary in ocean.in. In my New code, i have these as follow,

Code: Select all

!                   W       S       E          N
!                   e       o       a          o
!                   s       u       s          r
!                   t       t       t          t
!                           h                  h
!
!                   1       2       3          4

   LBC(isFsur) ==   Clo     Clo     Cha        Clo         ! free-surface
   LBC(isUbar) ==   Clo     Clo     Red        Clo         ! 2D U-momentum
   LBC(isVbar) ==   Clo     Clo     Red        Clo         ! 2D V-momentum
   LBC(isUvel) ==   Clo     Clo     Rad        Clo         ! 3D U-momentum
   LBC(isVvel) ==   Clo     Clo     Rad        Clo         ! 3D V-momentum
   LBC(isMtke) ==   Clo     Clo     Rad        Clo         ! mixing TKE

   LBC(isTvar) ==   Clo     Clo     Rad        Clo \    ! temperature
                    Clo     Clo     Rad        Clo      ! salinity

! Adjoint-based algorithms can have different lateral boundary
! conditions keywords.

ad_LBC(isFsur) ==   Per     Clo     Per     Clo         ! free-surface
ad_LBC(isUbar) ==   Per     Clo     Per     Clo         ! 2D U-momentum
ad_LBC(isVbar) ==   Per     Clo     Per     Clo         ! 2D U-momentum
ad_LBC(isUvel) ==   Per     Clo     Per     Clo         ! 3D U-momentum
ad_LBC(isVvel) ==   Per     Clo     Per     Clo         ! 3D V-momentum
ad_LBC(isMtke) ==   Per     Clo     Per     Clo         ! mixing TKE

ad_LBC(isTvar) ==   Per     Clo     Per     Clo \       ! temperature
                    Per     Clo     Per     Clo         ! salinity

! Set lateral open boundary edge volume conservation switch for
! nonlinear model and adjoint-based algorithms. Usually activated
! with radiation boundary conditions to enforce global mass
! conservation, except if tidal forcing enabled. [1:Ngrids].

   VolCons(west)  ==  F                            ! western  boundary
   VolCons(east)  ==  F                            ! eastern  boundary
   VolCons(south) ==  F                            ! southern boundary
   VolCons(north) ==  F                            ! northern boundary

ad_VolCons(west)  ==  F                            ! western  boundary
ad_VolCons(east)  ==  F                            ! eastern  boundary
ad_VolCons(south) ==  F                            ! southern boundary
ad_VolCons(north) ==  F                            ! northern boundary
and corresponding CPP definitions(part of all)

Code: Select all

#define TS_DIF2
#define MIX_S_TS
#define TS_MPDATA

#define SSH_TIDES
#define UV_TIDES
#define RAMP_TIDES
#define ADD_FSOBC
#define ADD_M2OBC
#define FSOBC_REDUCED
#define ANA_M2OBC

#define BULK_FLUXES
#define SOLAR_SOURCE
#define COOL_SKIN
#define LONGWAVE_OUT
#define ANA_SSFLUX
#define ANA_SPFLUX
#define ANA_BTFLUX
#define ANA_BSFLUX 
#define ANA_BPFLUX
#define ANA_RAIN
Following are the CPP options that NOT included in the new code(some were removed)

Code: Select all

#define WESTERN_WALL
#define NORTHERN_WALL
#define SOUTHERN_WALL
#define EAST_FSCHAMPMAN
#define EAST_M2REDUCED
As Hernan says that now all state variables are gaven the BCs with switches in the script ocean.in, but they are WALLs for momentum(3D) and WALLs/GRADIENT for tracers(maybe to many users using old code without define M3 and Tracers). So, there present fixed differences between two runs(though there EAST_M3* and EAST_T* can be used in old code).

And I would check the Build/*.f90 files, to be posted later.

Thank you everybody.

Shou

a.dagostini
Posts: 1
Joined: Wed Jan 23, 2013 4:59 pm
Location: National Institute For Space Research (INPE)

Re: what's wrong with temperature from two version of roms c

#7 Unread post by a.dagostini »

Hi,

I'm having a similar problem when using different versions of ROMS.
When I run with ROMS-3.5, everything works well. But when I try the same configuration (considering modifications at cppdefs) with ROMS-3.6 ou ROMS-3.7, I get a cooler situation of about 4-5 degrees.

Shou, did you find differences between the Build/*.f90 files in the versions of ROMS you tested???

I'm comparing this Build/*.f90 files in the moment, but as I'm a begginer in ocean modelling with ROMS, I would like to know what you have found about it, so I can understand better.

Thanks in advance for any help,

Andressa

tony1230
Posts: 87
Joined: Wed Mar 31, 2010 3:29 pm
Location: SKLEC,ECNU,Shanghai,China

Re: what's wrong with temperature from two version of roms c

#8 Unread post by tony1230 »

you may want to check the "Qair" in External/varinfo.dat, to confirm the value is 0.01 or 1.0.

Post Reply