I'm a beginner at ROMS modeling. I want to know how to turn off the horizontal advection term just for phytoplankton (NT=6).
I define fennel model and I find all the tracers in pre_step3d.F and step3d_t.F. I have already tested the model that I cannot simply skip the phytoplankton tracer because the result will show all the passive tracers only appearing on the boundary. Now I have two main confusions.
1. I am thinking about if I can define a value for t(i, j, k,3, itrc) before calculating in Time-step horizontal advection that can avoid calculating horizontal advection. But I don't how to find a suitable value.
2. Pre_step3d.F is like initial file and step3d_t.Fis is like calculation steps based on the time steps. Do I need to make changes both in these two files, because I just edit code in Pre_step3d.F in my test.
Could anyone tell me how to edit the code in ROMS? Which file should I edit? Anyone have better suggestions?
I have copied the modified location and my confusion for t(i,j,k,3,itrc). Please tell me if there is any other information that might be useful.
Thanks for any replies you have,
Yunpeng
Code: Select all
Time-step horizontal advection (m Tunits).
!
IF (itrc.eq.6) THEN ! NT=6 is phytoplankton
CYCLE
END IF
IF (iic(ng).eq.ntfirst(ng)) THEN
cff=0.5_r8*dt(ng)
cff1=1.0_r8
cff2=0.0_r8
ELSE
cff=(1.0_r8-Gamma)*dt(ng)
cff1=0.5_r8+Gamma
cff2=0.5_r8-Gamma
END IF
! my confusion
DO j=Jstr,Jend
DO i=Istr,Iend
IF (itrc.eq.6) THEN
t(i,j,k,3,itrc)= ?
else
t(i,j,k,3,itrc)=Hz(i,j,k)*(cff1*t(i,j,k,nstp,itrc)+ &
& cff2*t(i,j,k,nnew,itrc))- &
& cff*pm(i,j)*pn(i,j)* &
& (FX(i+1,j)-FX(i,j)+ &
& FE(i,j+1)-FE(i,j))
end if
END DO
END DO
END DO K_LOOP
END DO T_LOOP1