Wrong Temperature and salinity outputs

General scientific issues regarding ROMS

Moderators: arango, robertson

Post Reply
Message
Author
javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Wrong Temperature and salinity outputs

#1 Unread post by javadi »

Dear Users,

I ran the model for 6 years with this .h. The result does not show proper vertical temperature and salinity.Here I compare with observation. I try to model the temperature, salinity, and circulation of my domain. How to solve this problem?

Please help me with your interesting comments.


#define UV_ADV
#define UV_COR
#define UV_LDRAG
#define UV_VIS2
#undef MIX_GEO_UV
#define MIX_S_UV
#define SPLINES_VDIFF
#define SPLINES_VVISC
#define DJ_GRADPS
#define TS_DIF2
#undef TS_DIF4
#undef MIX_GEO_TS
#define MIX_S_TS

#define SALINITY
#define SOLVE3D
#define AVERAGES
#define DIAGNOSTICS_TS
#define DIAGNOSTICS_UV

#undef ANA_GRID
#undef ANA_INITIAL
#undef ANA_SMFLUX
#define ANA_STFLUX
#define ANA_SSFLUX
#define ANA_BTFLUX
#define ANA_BSFLUX

# define LMD_MIXING
# ifdef LMD_MIXING
# define LMD_RIMIX
# define LMD_CONVEC
# define LMD_SKPP
# define LI_FOX_KEMPER
# undef LMD_BKPP
# define LMD_NONLOCAL
# define LMD_SHAPIRO
# define LMD_DDMIX
# define LIMIT_VDIFF
# endif

#if defined BIO_FENNEL || defined ECOSIM || \
defined NPZD_POWELL || defined NEMURO
# define ANA_BIOLOGY
# define ANA_SPFLUX
# define ANA_BPFLUX
# define ANA_SRFLUX
#endif

#if defined NEMURO
# define HOLLING_GRAZING
# undef IVLEV_EXPLICIT
#endif

#ifdef BIO_FENNEL
# define CARBON
# define DENITRIFICATION
# define BIO_SEDIMENT
# define DIAGNOSTICS_BIO
#endif

#define MASKING
#undef ANA_PSOURCE

#ifdef PERFECT_RESTART
# undef AVERAGES
# undef DIAGNOSTICS_BIO
# undef DIAGNOSTICS_TS
# undef DIAGNOSTICS_UV
# define OUT_DOUBLE
#endif
Attachments
temp.PNG
temp.PNG (15.39 KiB) Viewed 67710 times
sal.PNG
sal.PNG (15.29 KiB) Viewed 67710 times
observ.PNG
observ.PNG (70.19 KiB) Viewed 67710 times

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Wrong Temperature and salinity outputs

#2 Unread post by kate »

Your model is salty at the surface when it should be fresh. What are you using for fresh water forcing?

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#3 Unread post by javadi »

I used river runoff when activating #undef ANA_PSOURCE. Also, I think that the model has a problem in flux too as the water is a little cooler than observation. I think that the model has a problem with vertical forcing and fluxes.

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Wrong Temperature and salinity outputs

#4 Unread post by kate »

So how are you forcing it? You have:
#define ANA_STFLUX
#define ANA_SSFLUX
Are these set to zero or something reasonable?

Note that I have been using BULK_FLUXES (with CCSM_FLUXES) and atmospheric reanalysis fields for over a decade now.

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#5 Unread post by javadi »

Dear Kate

Thanks for your response.

I try to model the temperature, salinity, density, and water circulation(eddies) of my domain, not biology work . Based on your response, I have reviewed your application at Github(Apps-master). I have changed my upwelling.h file. here is the new one. Is it ok?




#define UV_ADV
#define UV_COR
#define UV_LDRAG
#define UV_VIS2
#undef MIX_GEO_UV
#define MIX_S_UV
#define SPLINES_VDIFF
#define SPLINES_VVISC
#define DJ_GRADPS
#define TS_DIF2
#undef TS_DIF4
#undef MIX_GEO_TS
#define MIX_S_TS

#define SALINITY
#define SOLVE3D
#define AVERAGES
#define DIAGNOSTICS_TS
#define DIAGNOSTICS_UV

#undef ANA_GRID
#undef ANA_INITIAL
#undef ANA_SMFLUX
#define ANA_BTFLUX
#define ANA_BSFLUX

# define LMD_MIXING
# ifdef LMD_MIXING
# define LMD_RIMIX
# define LMD_CONVEC
# define LMD_SKPP
# define LI_FOX_KEMPER
# undef LMD_BKPP
# define LMD_NONLOCAL
# define LMD_SHAPIRO
# define LMD_DDMIX
# define LIMIT_VDIFF
# endif

# undef GLS_MIXING
# undef MY25_MIXING

# if defined GLS_MIXING || defined MY25_MIXING
# define KANTHA_CLAYSON
# define N2S2_HORAVG
# endif


#ifdef SOLVE3D
# define CORE_FORCING
# define BULK_FLUXES
# define CCSM_FLUXES
# if defined BULK_FLUXES || defined CCSM_FLUXES
# define LONGWAVE_OUT
# define DIURNAL_SRFLUX
# define EMINUSP
# undef ANA_SRFLUX
# undef ALBEDO_CLOUD
# define ALBEDO_CURVE
# undef LONGWAVE
# endif
#endif

#define MASKING
#undef ANA_PSOURCE

#ifdef PERFECT_RESTART
# undef AVERAGES
# undef DIAGNOSTICS_BIO
# undef DIAGNOSTICS_TS

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Wrong Temperature and salinity outputs

#6 Unread post by kate »

#define MIX_S_TS
This is OK if your bottom is flat, otherwise it leads to mixing along s-surfaces which can be unrealistic. I don't see anything else wrong, but I could be missing something, who knows.

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#7 Unread post by javadi »

Dear Kate

Thanks!

When omitting #define MIX_S_TS, I have faced this error :

18 | T3DMIX: must define one of MIX_S_TS, MIX_GEO_TS, MIX_ISO_TS
| 1
Error: Unclassifiable statement at (1)
t3dmix.f90:16:20:

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#8 Unread post by javadi »

I have defined #defined MIX_GEO_TS and compile the model successfully. The model works correctly for one month but at the end of each month, we have faced an error. For example, when the model starts in January, the model has faced problems on 31 January. While I started in February, the model has faced an error on the 28 February(the same time). The error is



5899 2013-02-28 10:26:40.00 3.282258E-03 3.203207E+03 3.203210E+03 5.412928E+13
(043,146,01) 4.822500E-02 4.499562E-02 5.208305E-01 8.471538E-01
GET_2DFLD - solar shortwave radiation flux, 2013-02-28 13:30:00.00
(Grid=01, Rec=469, Index=1, File: gom_swrad_era1.nc)
(Tmin= -31.0625 Tmax= 333.8125) t = 27.4375
(Min = 1.27788394E-05 Max = 2.53744384E-05) regrid = T
GET_2DFLD - downwelling longwave radiation flux, 2013-02-01 01:30:00.00
(Grid=01, Rec=306, Index=1, File: gom_lwrad_era1.nc)
(Tmin= -31.1875 Tmax= 333.8125) t = -0.0625
(Min = 6.20185804E-05 Max = 8.34224417E-05) regrid = T
GET_2DFLD - rain fall rate, 2013-02-28 13:30:00.00
(Grid=01, Rec=469, Index=1, File: gom_rain_era1.nc)
(Tmin= -31.0625 Tmax= 333.8125) t = 27.4375
(Min = -6.10111224E-12 Max = 1.87287573E-05) regrid = T

SET_2DFLD - current model time exceeds ending value for variable: lwrad_down
TDAYS = 27.3148
Data Tmin = -31.1875 Data Tmax = 333.8125
Data Tstr = -0.1875 Data Tend = 0.3125
TINTRP1 = 27.3125 TINTRP2 = -0.0625
FAC1 = -27.3773 FAC2 = 0.0023
Found Error: 02 Line: 319 Source: ROMS/Nonlinear/set_data.F, set_data_tile
Found Error: 02 Line: 222 Source: ROMS/Nonlinear/main3d.F
Found Error: 02 Line: 302 Source: ROMS/Drivers/nl_ocean.h, ROMS_run

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Wrong Temperature and salinity outputs

#9 Unread post by kate »

You have only one month of forcing per file? You can string them together in the roms.in file. I have my forcing files with one year each and string them together from one year to the next:
NFFILES == 14 ! number of forcing files

FRCNAME == /center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_Pair_2015.nc |
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_Pair_2016.nc \
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_Qair_2015.nc |
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_Qair_2016.nc \
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_Tair_2015.nc |
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_Tair_2016.nc \
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_rain_2015.nc |
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_rain_2016.nc \
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_snow_2015.nc |
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_snow_2016.nc \
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_swrad_2015.nc |
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_swrad_2016.nc \
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_lwrad_down_2015.nc |
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_lwrad_down_2016.nc \
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_Uwind_2015.nc |
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_Uwind_2016.nc \
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_Vwind_2015.nc |
/center1/AKWATERS/kate/JRA55-do/JRA55DO_1.4_Vwind_2016.nc \
/center1/AKWATERS/kshedstrom/CORE2/sss_fill_2004.nc \
/center1/AKWATERS/kshedstrom/Arctic/Files/iron_sediment_ARCTIC4.nc \
/center1/AKWATERS/kshedstrom/Chukchi/Files/Mineral_Fe_Flux_PI_ROMS.nc \
/center1/AKWATERS/kshedstrom/Chukchi/Files/Soluble_Fe_Flux_PI_ROMS.nc \
/center1/AKWATERS/kshedstrom/Arctic/Files/atm_CO2_Arctic.nc

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#10 Unread post by javadi »

No. I think that this is ok. I have downloaded from ECMWF and merge months. Like this, is it ok? maybe, the time is a problem?


NFFILES == 13 ! number of unique forcing files

FRCNAME == /media/java/G/2013/gom_cloud_era1.nc |
/media/java/G/2014/gom_cloud_era2.nc |
/media/java/G/2015/gom_cloud_era_3.nc |
/media/java/G/2016/gom_cloud_era_4.nc |
/media/java/G/2017/gom_cloud_era_5.nc |
/media/java/G/2018/gom_cloud_era_6.nc \
/media/java/G/2013/gom_latent_era1.nc |
/media/java/G/2014/gom_latent_era2.nc |
/media/java/G/2015/gom_latent_era_3.nc |
/media/java/G/2016/gom_latent_era_4.nc |
/media/java/G/2017/gom_latent_era_5.nc |
/media/java/G/2018/gom_latent_era_6.nc \
/media/java/G/2013/gom_lwrad_era1.nc |
/media/java/G/2014/gom_lwrad_era2.nc |
/media/java/G/2015/gom_lwrad_era_3.nc |
/media/java/G/2016/gom_lwrad_era_4.nc |
/media/java/G/2017/gom_lwrad_era_5.nc |
/media/java/G/2018/gom_lwrad_era_6.nc \
/media/java/G/2013/gom_Pair_era1.nc |
/media/java/G/2014/gom_Pair_era2.nc |
/media/java/G/2015/gom_Pair_era_3.nc |
/media/java/G/2016/gom_Pair_era_4.nc |
/media/java/G/2017/gom_Pair_era_5.nc |
/media/java/G/2018/gom_Pair_era_6.nc \
/media/java/G/2013/gom_Qair_era1.nc |
/media/java/G/2014/gom_Qair_era2.nc |
/media/java/G/2015/gom_Qair_era_3.nc |
/media/java/G/2016/gom_Qair_era_4.nc |
/media/java/G/2017/gom_Qair_era_5.nc |
/media/java/G/2018/gom_Qair_era_6.nc \
/media/java/G/2013/gom_rain_era1.nc |
/media/java/G/2014/gom_rain_era2.nc |
/media/java/G/2015/gom_rain_era_3.nc |
/media/java/G/2016/gom_rain_era_4.nc |
/media/java/G/2017/gom_rain_era_5.nc |
/media/java/G/2018/gom_rain_era_6.nc \
/media/java/G/2013/gom_sensible_era1.nc |
/media/java/G/2014/gom_sensible_era2.nc |
/media/java/G/2015/gom_sensible_era_3.nc |
/media/java/G/2016/gom_sensible_era_4.nc |
/media/java/G/2017/gom_sensible_era_5.nc |
/media/java/G/2018/gom_sensible_era_6.nc \
/media/java/G/2013/gom_shflux_era1.nc |
/media/java/G/2014/gom_shflux_era2.nc |
/media/java/G/2015/gom_shflux_era_3.nc |
/media/java/G/2016/gom_shflux_era_4.nc |
/media/java/G/2017/gom_shflux_era_5.nc |
/media/java/G/2018/gom_shflux_era_6.nc \
/media/java/G/2013/gom_sms_era1.nc |
/media/java/G/2014/gom_sms_era2.nc |
/media/java/G/2015/gom_sms_era_3.nc |
/media/java/G/2016/gom_sms_era_4.nc |
/media/java/G/2017/gom_sms_era_5.nc |
/media/java/G/2018/gom_sms_era_6.nc \
/media/java/G/2013/gom_swflux_era1.nc |
/media/java/G/2014/gom_swflux_era2.nc |
/media/java/G/2015/gom_swflux_era_3.nc |
/media/java/G/2016/gom_swflux_era_4.nc |
/media/java/G/2017/gom_swflux_era_5.nc |
/media/java/G/2018/gom_swflux_era_6.nc \
/media/java/G/2013/gom_swrad_era1.nc |
/media/java/G/2014/gom_swrad_era2.nc |
/media/java/G/2015/gom_swrad_era_3.nc |
/media/java/G/2016/gom_swrad_era_4.nc |
/media/java/G/2017/gom_swrad_era_5.nc |
/media/java/G/2018/gom_swrad_era_6.nc \
/media/java/G/2013/gom_Tair_era1.nc |
/media/java/G/2014/gom_Tair_era2.nc |
/media/java/G/2015/gom_Tair_era_3.nc |
/media/java/G/2016/gom_Tair_era_4.nc |
/media/java/G/2017/gom_Tair_era_5.nc |
/media/java/G/2018/gom_Tair_era_6.nc \
/media/java/G/2013/gom_wind_era1.nc |
/media/java/G/2014/gom_wind_era2.nc |
/media/java/G/2015/gom_wind_era_3.nc |
/media/java/G/2016/gom_wind_era_4.nc |
/media/java/G/2017/gom_wind_era_5.nc |
/media/java/G/2018/gom_wind_era_6.nc

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Wrong Temperature and salinity outputs

#11 Unread post by kate »

What is the time variable like in one of these things? You need one common time origin for *everything*.

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#12 Unread post by javadi »

I use ecmwf2roms Matlab manuscript to make forcing. I use


DSTART = 0.0d0 ! days
TIDE_START = 0.0d0 ! days
TIME_REF = 20130101.5d0 ! yyyymmdd.dd





I do not know but we have different times for each variable.





GET_2DFLD - solar shortwave radiation flux, 2013-01-31 13:30:00.00
(Grid=01, Rec=245, Index=2, File: gom_swrad_era1.nc)
(Tmin= -0.4375 Tmax= 364.4375) t = 30.0625
(Min = 3.14134142E-06 Max = 1.27237242E-05) regrid = T
GET_2DFLD - downwelling longwave radiation flux, 2013-01-01 01:30:00.00
(Grid=01, Rec=63, Index=2, File: gom_lwrad_era1.nc)
(Tmin= -0.5625 Tmax= 364.4375) t = -0.4375
(Min = 4.50244663E-05 Max = 7.58182375E-05) regrid = T
GET_2DFLD - rain fall rate, 2013-01-31 13:30:00.00
(Grid=01, Rec=245, Index=2, File: gom_rain_era1.nc)
(Tmin= -0.4375 Tmax= 364.4375) t = 30.0625
(Min = -4.18313908E-12 Max = 1.64248631E-04) regrid = T


GET_2DFLD - surface air temperature, 2013-01-31 12:00:00.00
(Grid=01, Rec=62, Index=2, File: gom_Tair_era1.nc)
(Tmin= -0.5000 Tmax= 364.5000) t = 30.0000
(Min = 4.37862444E+00 Max = 1.65629877E+01) regrid = T
GET_2DFLD - surface air relative humidity, 2013-01-31 12:00:00.00
(Grid=01, Rec=62, Index=2, File: gom_Qair_era1.nc)
(Tmin= -0.5000 Tmax= 364.5000) t = 30.0000
(Min = 3.99281480E-01 Max = 9.57515600E-01) regrid = T

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Wrong Temperature and salinity outputs

#13 Unread post by kate »

What about trying "ncdump -h" on one of these things? I get:

Code: Select all

netcdf JRA55DO_1.5_rain_2020 {
dimensions:
	lon = 640 ;
	lat = 320 ;
	time = UNLIMITED ; // (2928 currently)
variables:
	double lon(lon) ;
		lon:units = "degrees_east" ;
		lon:valid_min = 0. ;
		lon:valid_max = 359.4375 ;
		lon:long_name = "longitude" ;
	double lat(lat) ;
		lat:units = "degrees_north" ;
		lat:valid_min = -89.5700895506066 ;
		lat:valid_max = 89.5700895506066 ;
		lat:long_name = "latitude" ;
	double time(time) ;
		time:units = "days since 1900-01-01 00:00:00" ;
		time:valid_min = 43829.0625 ;
		time:valid_max = 44194.9375 ;
		time:calendar = "LEAP" ;
	float rain(time, lat, lon) ;
		rain:long_name = "Rainfall Flux" ;
		rain:units = "kg m-2 s-1" ;
		rain:coordinates = "lon lat" ;
		rain:time = "time" ;
		rain:_FillValue = 1.e+15f ;
		rain:missing_value = 1.e+15f ;
		rain:valid_range = -0.0003254949f, 0.003580443f ;

// global attributes:
		:About = "File created by SOSIE interpolation environement, Laurent Brodeau, 2010, (brodeau@gmail.com)" ;
}
You can see my time origin of "days since 1900-01-01 00:00:00" with values all in the 43000+ range. You can check that for sure with "ncdump -v time" of the thing. My values do indeed go linearly from time:valid_min to time:valid_max.

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#14 Unread post by javadi »

This is ok. I have checked it.I am surprised as in the previous flags the model ran without any problems. But, with this .h we have this problem



cloud_time:long_name = "cloud fraction time" ;
cloud_time:units = "days since 2000-01-01 00:00:00" ;
cloud_time:calendar = "gregorian" ;
float cloud(cloud_time, lat, lon) ;
cloud:long_name = "cloud fraction" ;
cloud:time = "cloud_time" ;
cloud:coordinates = "lon lat cloud_time" ;


double lhf_time(lhf_time) ;
lhf_time:long_name = "latent heat flux time" ;
lhf_time:units = "days since 2000-01-01 00:00:00" ;
lhf_time:calendar = "gregorian" ;
float latent(lhf_time, lat, lon) ;
latent:long_name = "net latent heat flux" ;
latent:units = "Watt meter-2" ;
latent:positive_value = "downward flux, heating" ;
latent:negative_value = "upward flux, cooling" ;
latent:time = "lhf_time" ;
latent:coordinates = "lon lat lhf_time" ;


double lhf_time(lhf_time) ;
lhf_time:long_name = "latent heat flux time" ;
lhf_time:units = "days since 2000-01-01 00:00:00" ;
lhf_time:calendar = "gregorian" ;

double pair_time(pair_time) ;
pair_time:long_name = "surface air pressure time" ;
pair_time:units = "days since 2000-01-01 00:00:00" ;
pair_time:calendar = "gregorian" ;
float Pair(pair_time, lat, lon) ;
Pair:long_name = "surface air pressure" ;
Pair:units = "millibar" ;
Pair:time = "pair_time" ;
Pair:coordinates = "lon lat pair_time" ;

double qair_time(qair_time) ;
qair_time:long_name = "surface air humidity time" ;
qair_time:units = "days since 2000-01-01 00:00:00" ;
qair_time:calendar = "gregorian" ;

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Wrong Temperature and salinity outputs

#15 Unread post by kate »

So, do you know what to do next? You need to change your TIME_REF to match that of your forcing files. I have:

Code: Select all

!     DSTART =  29226.5d0                  ! days (1980)
      DSTART =  42003.5d0                  ! days (2015)
  TIDE_START =  -1.0d0                     ! days 
    TIME_REF =  19000101.0d0               ! yyyymmdd.dd

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#16 Unread post by javadi »

Excuse me!
I am a little confused about how you estimate the time to start.

Now, I have defined


DSTART = 662214.4375 ! days
TIDE_START = 0.0d0 ! days
TIME_REF = 2000101.0d0

But I have faced this error


SET_2DFLD - current model time exceeds ending value for variable: lwrad_down
TDAYS = 662215.4398
Data Tmin = 662184.9375 Data Tmax = 662549.9375
Data Tstr = 662212.9375 Data Tend = 662213.4375
TINTRP1 = 662215.4375 TINTRP2 = 662185.0625
FAC1 = -30.3773 FAC2 = 0.0023

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Wrong Temperature and salinity outputs

#17 Unread post by kate »

Woah! Where did you get that DSTART? It should be the number of days between your time origin (2000) and your starting time (2013?). That would make 13*365 plus the number of leap days in there, so 4749 days.

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#18 Unread post by javadi »

Dear Kate

Thank you so much for your points.

I have changed the time based on your sugestions but I have faced the same error.

DSTART = 4749 ! days
TIDE_START = 0.0d0 ! days
TIME_REF = 2000101.0d0



GET_2DFLD - solar shortwave radiation flux, 2013-01-31 13:30:00.00
(Grid=01, Rec=245, Index=1, File: gom_swrad_era1.nc)
(Tmin= 662185.0625 Tmax= 662549.9375) t = 662215.5625
(Min = 3.14134142E-06 Max = 1.27237242E-05) regrid = T
GET_2DFLD - downwelling longwave radiation flux, 2013-01-01 01:30:00.00
(Grid=01, Rec=63, Index=1, File: gom_lwrad_era1.nc)
(Tmin= 662184.9375 Tmax= 662549.9375) t = 662185.0625
(Min = 4.50244663E-05 Max = 7.58182375E-05) regrid = T
GET_2DFLD - rain fall rate, 2013-01-31 13:30:00.00
(Grid=01, Rec=245, Index=1, File: gom_rain_era1.nc)
(Tmin= 662185.0625 Tmax= 662549.9375) t = 662215.5625
(Min = -4.18313908E-12 Max = 1.64248631E-04) regrid = T

SET_2DFLD - current model time exceeds ending value for variable: lwrad_down
TDAYS = 662215.4398
Data Tmin = 662184.9375 Data Tmax = 662549.9375
Data Tstr = 662212.9375 Data Tend = 662213.4375
TINTRP1 = 662215.4375 TINTRP2 = 662185.0625
FAC1 = -30.3773 FAC2 = 0.0023

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Wrong Temperature and salinity outputs

#19 Unread post by kate »

TIME_REF = 2000101.0d0
I think it thinks you have year 200 instead of year 2000. Try adding another 0.

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#20 Unread post by javadi »

No, this is not matter. I have corrected it. I think that i have different variables with different tmin. It creates problmes.For this reason٫ at the end of each month there is less input forcing٫leading issue. This problem is as a resualt of new .h. I ran the model for 6 years without any problem with the previous .h which is at the bottom of this page.

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#21 Unread post by javadi »

Dear kate

I ask you one question. Based on your suggestion, I use this cpp (bulk fluxes)for my model. Does this work correctly in the trunk branch? or should I use your branch to use this option?



#ifdef SOLVE3D
# define CORE_FORCING
# define BULK_FLUXES
# define CCSM_FLUXES
# if defined BULK_FLUXES || defined CCSM_FLUXES
# define LONGWAVE_OUT
# define DIURNAL_SRFLUX
# define EMINUSP
# undef ANA_SRFLUX
# undef ALBEDO_CLOUD
# define ALBEDO_CURVE
# undef LONGWAVE
# endif
#endif

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Wrong Temperature and salinity outputs

#22 Unread post by kate »

The trunk code does not have CCSM_FLUX, nor does it have all those albedo options. You should use the .h file consistent with your code.

javadi
Posts: 118
Joined: Mon Jan 27, 2020 5:55 pm
Location: UoT

Re: Wrong Temperature and salinity outputs

#23 Unread post by javadi »

Thanks for your response.

It was my problem. How should I change my .h file for trunk code to be compatible with trunk codes. Now my .h is:

#define UV_ADV
#define UV_COR
#define UV_LDRAG
#define UV_VIS2
#undef MIX_GEO_UV
#define MIX_S_UV
#define SPLINES_VDIFF
#define SPLINES_VVISC
#define DJ_GRADPS
#define TS_DIF2
#undef TS_DIF4
#undef MIX_GEO_TS
#define MIX_S_TS

#define SALINITY
#define SOLVE3D
#define AVERAGES
#define DIAGNOSTICS_TS
#define DIAGNOSTICS_UV

#undef ANA_GRID
#undef ANA_INITIAL
#undef ANA_SMFLUX
#define ANA_BTFLUX
#define ANA_BSFLUX

# define LMD_MIXING
# ifdef LMD_MIXING
# define LMD_RIMIX
# define LMD_CONVEC
# define LMD_SKPP
# define LI_FOX_KEMPER
# undef LMD_BKPP
# define LMD_NONLOCAL
# define LMD_SHAPIRO
# define LMD_DDMIX
# define LIMIT_VDIFF
# endif

# undef GLS_MIXING
# undef MY25_MIXING

# if defined GLS_MIXING || defined MY25_MIXING
# define KANTHA_CLAYSON
# define N2S2_HORAVG
# endif


#ifdef SOLVE3D
# define CORE_FORCING
# define BULK_FLUXES
# define CCSM_FLUXES
# if defined BULK_FLUXES || defined CCSM_FLUXES
# define LONGWAVE_OUT
# define DIURNAL_SRFLUX
# define EMINUSP
# undef ANA_SRFLUX
# undef ALBEDO_CLOUD
# define ALBEDO_CURVE
# undef LONGWAVE
# endif
#endif

#define MASKING
#undef ANA_PSOURCE

#ifdef PERFECT_RESTART
# undef AVERAGES
# undef DIAGNOSTICS_BIO
# undef DIAGNOSTICS_TS

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Wrong Temperature and salinity outputs

#24 Unread post by kate »

Why don't you look through the trunk code examples to see what they use?
#undef MIX_GEO_TS
#define MIX_S_TS
I would swap these.
# define LI_FOX_KEMPER
This is not in the trunk.

Post Reply