Commit 4bbaec20585e75c33ae0228983acf14aeac9c9b2

Authored by dumoda01
1 parent 9538a482
Exists in master and in 1 other branch snow

Correction d''un bogue qui empechait de rouler sans la biologie

src/gotm/gotm.F90
@@ -365,7 +365,9 @@ @@ -365,7 +365,9 @@
365 ! (see \sect{sec:extra}). 365 ! (see \sect{sec:extra}).
366 ! 366 !
367 ! !USES: 367 ! !USES:
  368 +#ifdef BIO
368 use bio_var, only: numcc,cc !CHG3 369 use bio_var, only: numcc,cc !CHG3
  370 +#endif
369 371
370 IMPLICIT NONE 372 IMPLICIT NONE
371 ! 373 !
@@ -431,12 +433,20 @@ @@ -431,12 +433,20 @@
431 433
432 ! update nitrate !CHG3 434 ! update nitrate !CHG3
433 if (n_prof_method .ne. 0) then 435 if (n_prof_method .ne. 0) then
  436 +#ifdef BIO
434 call nitrate(nlev,dt,cnpar,nus,gams,cc) 437 call nitrate(nlev,dt,cnpar,nus,gams,cc)
  438 +#else
  439 + call nitrate(nlev,dt,cnpar,nus,gams)
  440 +#endif
435 endif 441 endif
436 442
437 ! update ammonium !CHG5 443 ! update ammonium !CHG5
438 if (a_prof_method .ne. 0) then 444 if (a_prof_method .ne. 0) then
  445 +#ifdef BIO
439 call ammonium(nlev,dt,cnpar,nus,gams,cc) 446 call ammonium(nlev,dt,cnpar,nus,gams,cc)
  447 +#else
  448 + call ammonium(nlev,dt,cnpar,nus,gams)
  449 +#endif
440 endif 450 endif
441 451
442 ! update shear and stratification 452 ! update shear and stratification
src/meanflow/ammonium.F90
@@ -94,7 +94,7 @@ @@ -94,7 +94,7 @@
94 REALTYPE, intent(in) :: gams(0:nlev) 94 REALTYPE, intent(in) :: gams(0:nlev)
95 95
96 ! nitrate concentration after bio loop 96 ! nitrate concentration after bio loop
97 - REALTYPE, intent(in) :: cc(1:7,0:nlev) !CHG3 97 + REALTYPE, intent(in), optional :: cc(1:7,0:nlev) !CHG3
98 ! 98 !
99 ! !REVISION HISTORY: 99 ! !REVISION HISTORY:
100 ! Original author(s): Dany Dumont (dany_dumont@ete.inrs.ca) 100 ! Original author(s): Dany Dumont (dany_dumont@ete.inrs.ca)
@@ -154,9 +154,11 @@ @@ -154,9 +154,11 @@
154 end if 154 end if
155 155
156 ! redefinir amm apres un cyle bio 156 ! redefinir amm apres un cyle bio
  157 +#ifdef BIO
157 do i=1,nlev !CHG5 158 do i=1,nlev !CHG5
158 amm(i) = cc(6,i) 159 amm(i) = cc(6,i)
159 end do 160 end do
  161 +#endif
160 162
161 ! do advection step 163 ! do advection step
162 if (w_adv_method .ne. 0) then 164 if (w_adv_method .ne. 0) then
src/meanflow/nitrate.F90
@@ -94,7 +94,7 @@ @@ -94,7 +94,7 @@
94 REALTYPE, intent(in) :: gams(0:nlev) 94 REALTYPE, intent(in) :: gams(0:nlev)
95 95
96 ! nitrate concentration after bio loop 96 ! nitrate concentration after bio loop
97 - REALTYPE, intent(in) :: cc(1:7,0:nlev) !CHG3 97 + REALTYPE, intent(in), optional :: cc(1:7,0:nlev) !CHG3
98 ! 98 !
99 ! !REVISION HISTORY: 99 ! !REVISION HISTORY:
100 ! Original author(s): Dany Dumont (dany_dumont@ete.inrs.ca) 100 ! Original author(s): Dany Dumont (dany_dumont@ete.inrs.ca)
@@ -154,9 +154,11 @@ @@ -154,9 +154,11 @@
154 end if 154 end if
155 155
156 ! redefinir nit apres un cyle bio 156 ! redefinir nit apres un cyle bio
  157 +#ifdef BIO
157 do i=1,nlev !CHG3 158 do i=1,nlev !CHG3
158 nit(i) = cc(5,i) 159 nit(i) = cc(5,i)
159 end do 160 end do
  161 +#endif
160 162
161 ! do advection step 163 ! do advection step
162 if (w_adv_method .ne. 0) then 164 if (w_adv_method .ne. 0) then
src/observations/observations.F90
@@ -648,6 +648,15 @@ @@ -648,6 +648,15 @@
648 nprof = n_1 648 nprof = n_1
649 case (TWO_LAYERS) 649 case (TWO_LAYERS)
650 call analytical_profile(nlev,z,z_n1,n_1,z_n2,n_2,nprof) 650 call analytical_profile(nlev,z,z_n1,n_1,z_n2,n_2,nprof)
  651 +
  652 + LEVEL2 'Nitrate two-layer profile'
  653 + write(*,900) ' n_1 = ',n_1
  654 + write(*,900) ' z_n1 = ',z_n1
  655 + write(*,900) ' n_2 = ',n_2
  656 + write(*,900) ' z_n2 = ',z_n2
  657 +
  658 +900 format (A,F8.5)
  659 +
651 case default 660 case default
652 end select 661 end select
653 case (FROMFILE) 662 case (FROMFILE)