I plan to first adjust the parameters of the static approximation model to better carry out the non-static simulation plan. However, in the shallow coastal areas and the offshore regions, there is a problem of negative temperature.
In my cpp.h, it is defined as:
define UV_HADV_TVD, UV_VADV_SPLINES, UV_MIX_S
define TS_HADV_WENO5 (TS_HADV_UP3 was also tried), TS_VADV_WENO5 (TS_VADV_C2 and TS_VADV_AKIMA were also tried), TS_MIX_S
define GLS_MIXING, GLS_KKL.
I also referred to the modifications suggested by other scholars on the forum to reduce the order of the table bottom in compute_vert_tracer_fluxes.h, such as FC(i,1) and FC(i,N-1). However, I found that there was no improvement and the temperature would still become negative when the WET_DRY area turned into a land area. This led to the gradual accumulation of temperature anomalies as the calculation progressed, spreading from the shallow areas to the river interior and the nearshore waters. The minimum value could reach -100°C.
I wonder if any scholar has relevant experience.
Thank you for your reading!
In winter, when the ebb tide coincides with darkness, the shallow areas that were dry become rapidly cooled. When the tide rises again, the seawater flowing through the previously dry areas cools down. Although the daily solar radiation causes the seawater to warm up, over the course of a day, the average temperature of these areas often drops by 3°C. Over three months, this results in a temperature drop of 100°C (though this is absurd). Could it be that my mixed diffusion scheme is too weak? This causes the cooled seawater to rapidly decrease in temperature over time, and eventually the entire coastal waters become negative values.
can please share with me your cppdefs.h and cppdefs_dev.h . actually I want to see where this temperature drops in WENO_Z code. LIMIT_STFLX_COOLING
Thank you!
I will attach my cppdefs.h file and cppdefs_dev.h file in the attachment. In the cppdefs.h file, I used the content within “define REGIONAL”. I will also attach my initial log file (croco1.txt), and attempt to turn off WET_DRY and modify GLS_MIX to LMD_MIX (file croco_1.txt). I found that after turning off the dry-wet grid, the speed would blow up very quickly. Moreover, since the cppdefs_dev.h file was not used during compilation, I did not modify it.
Now I will present my questions. The simulation starts on January 1, 2025. Due to the combined effect of tidal changes and night-time cooling, the area that becomes dry rapidly cools down at low tide, and it begins at 20:00 on January 2nd, 2025.
Fig 2 U-directional flow velocity Display (It can be proved that the negative temperature region is the dew point (the blue area represents the dew point).)
As the tide keeps receding and the temperature drops, the area of negative temperature becomes larger and larger, and the area of the negative temperature water mass gradually expands to the inner part of the estuary. At this point, the temperature dropped to -45℃.
Fig 3 Temperature display on January 12th, 2025 (The green area represents temperatures below 0 degrees Celsius)
When the simulation reached February 20th, 2025, the cold water mass had expanded throughout the entire coastal waters, and the temperature had dropped to an astonishing -100°C. Here, I have a question: In the Croco model, why didn’t it report an error for such an extreme temperature? This is already inconsistent with the physical properties of the water body.
Fig 4 Temperature display on February 20th, 2025 (The green area represents temperatures below 0 degrees Celsius)
The above are the simulated problems presented. At present, I still don’t know what the solution is. Such a temperature drop can be reduced to 2-3℃ within one day. Changing the vertical mixing schemes of GLS and LMD will provide a little improvement but not much.
I hope this can be helpful to you. Thank you again. Additional note: All the floor plans above are presented as the bottom floor. cppdefs.h (44.0 KB) cppdefs_dev.h (32.2 KB) croco_1.txt (171.4 KB) croco1.txt (1.8 MB)
Hi,
after this line add this and test it. (get_vbc.F line-417)
# ifdef SOLVE3D
# ifdef TEMPERATURE
# ifdef LIMIT_STFLX_COOLING
cff1=-2.0_r8 ! your threshold to cooling
DO j=JstrR,JendR
DO i=IstrR,IendR
cff2=stflx(i,j,itemp)
cff3=0.5_r8*(1.0_r8+SIGN(1.0_r8,cff1-t(i,j,N(ng),nrhs,itemp)))
stflx(i,j,itemp)=cff2-cff3*0.5_r8*(cff2-ABS(cff2))
END DO
END DO
# endif
# endif
# endif
and add LIMIT_STFLX_COOLING key below the BULK_FLUXES and TEMPERATURE in cppdefs.h
you may need to check below but above are just shortcut only.
a) Temperature preservation in step3D_t.F
b) Heat flux masking with rmask_wet
c) Solar radiation masking etc
Hi, I tried the method you provided. The code you gave was quite familiar to me, so I checked the source code in my ROMS. I found that it had been added in the set_vbc section. Thank you for your reminder. I immediately went to test it and added the code you gave at line 417 of get_vbc.F.(Since Croco lacks the “set_vbc” function and only has the “get_vbc” file, it is unknown whether it will be effective.)
However, I didn’t see much change. The temperature decreased significantly and accumulated every day. Finally, I thought that since I enabled ONLINE, the net heat flux would change. Could this be the cause of the problem? So, I added at line 640 of bulk_flux.F. : #ifdef LIMIT_STFLX_COOLING
cff1 = -2.0
cff2 = stflx(i,j,itemp)
SST = t(i,j,N,nrhs,itemp)
If (SST <= cff1 .and. cff2 < 0.0) then
stflx(i,j,itemp) = 0.0 endif #endif
The test results showed that the lowest temperature did indeed remain at around -2℃. However, the problem that followed was that the cold water mass still expanded over a wide area, resulting in the near-shore water mass being all at -2℃. In contrast, the temperature simulated by ROMS during the same period was between 7-10℃. What could be the reason for this? Why didn’t the other warmer seawater heat up these areas? The temperature at the source of my river was also between 8-10℃.
Apart from the operations mentioned above, I found that the previous setting of TNU2 was 0. When I changed it to 50*10.d0, it had a slight effect.
Thank you again for your enthusiastic response. Best wishes!
Attention:I would like to correct one point. As mentioned earlier, after the conversion of the dry-wet point, the dry point cooled down. In fact, it was the wet point that cooled down significantly because the water was too shallow, with a very small specific heat capacity. When the heat flux was less than 0, the water body lost its temperature rapidly.
Hi,
Yes it was done by ROMS long back
(but the solution provided by ROMS not perfect as per my understanding). subroutine set_vbc and others already there in get_vbc .
you already tried Nudging, its good (laplacian background diffusivity). 50-500 try.
and use # undef TS_HADV_RSUP3 # define TS_HADV_UP3
change Critical Depth for Drying cells as per your requarments:
after that we can try something in step3D_t.F and other file
#ifdef WET_DRY
DO k=1,N(ng)
DO j=JstrR,JendR
DO i=IstrR,IendR
IF ((rmask_wet(i,j).eq.0).AND.(rmask(i,j).eq.1)) THEN
t(i,j,k,nnew,itrc)=t(i,j,k,nstp,itrc)
END IF
END DO
END DO
END DO
#endif
can you share your croco src and input file in zip. and share the link.
Then i can reproduce it.
Thank you.