Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • nemo/nemo
  • sparonuz/nemo
  • hatfield/nemo
  • extdevs/nemo
4 results
Show changes
Commits on Source (104)
Showing
with 698 additions and 609 deletions
......@@ -35,8 +35,8 @@
%CPP cpp -Dkey_nosignedzero
%FC mpif90
%PROD_FCFLAGS -fdefault-real-8 -O3 -funroll-all-loops -fcray-pointer -ffree-line-length-none -fallow-argument-mismatch
%DEBUG_FCFLAGS -fdefault-real-8 -O0 -g -fbacktrace -funroll-all-loops -fcray-pointer -ffree-line-length-none -fcheck=all -finit-real=nan
%PROD_FCFLAGS -fdefault-real-8 -O3 -funroll-all-loops -fcray-pointer -ffree-line-length-none -fallow-argument-mismatch
%DEBUG_FCFLAGS -fdefault-real-8 -O0 -g -fbacktrace -funroll-all-loops -fcray-pointer -ffree-line-length-none -fcheck=all -finit-real=nan -fallow-argument-mismatch
%FFLAGS %FCFLAGS
%LD %FC
%LDFLAGS
......
......@@ -34,6 +34,8 @@
<field field_ref="qt_oce" name="qt_oce" />
<field field_ref="saltflx" name="sfx" />
<field field_ref="taum" name="taum" />
<field field_ref="utau" name="tauuo" />
<field field_ref="vtau" name="tauvo" />
<field field_ref="wspd" name="windsp" />
<field field_ref="precip" name="precip" />
<!-- ice and snow -->
......@@ -44,7 +46,6 @@
<field field_ref="e3u" />
<field field_ref="ssu" name="uos" />
<field field_ref="uoce" name="uo" operation="instant" freq_op="5d" > @uoce_e3u / @e3u </field>
<field field_ref="utau" name="tauuo" />
<field field_ref="uocetr_eff" name="uocetr_eff" />
<!-- available with diaar5 -->
<field field_ref="u_masstr" name="vozomatr" />
......@@ -56,7 +57,6 @@
<field field_ref="e3v" />
<field field_ref="ssv" name="vos" />
<field field_ref="voce" name="vo" operation="instant" freq_op="5d" > @voce_e3v / @e3v </field>
<field field_ref="vtau" name="tauvo" />
<field field_ref="vocetr_eff" name="vocetr_eff" />
<!-- available with diaar5 -->
<field field_ref="v_masstr" name="vomematr" />
......
......@@ -100,6 +100,8 @@
<field field_ref="qsr" name="rsntds" />
<field field_ref="qt" name="tohfls" />
<field field_ref="taum" />
<field field_ref="utau" name="tauuo" />
<field field_ref="vtau" name="tauvo" />
<field field_ref="mldkz5" />
<field field_ref="mldr10_1" />
</file>
......@@ -107,13 +109,11 @@
<file id="file5" name_suffix="_grid_U" description="ocean U grid variables" >
<field field_ref="uoce" name="uo" />
<field field_ref="ssu" name="uos" />
<field field_ref="utau" name="tauuo" />
</file>
<file id="file6" name_suffix="_grid_V" description="ocean V grid variables" >
<field field_ref="voce" name="vo" />
<field field_ref="ssv" name="vos" />
<field field_ref="vtau" name="tauvo" />
</file>
<file id="file7" name_suffix="_grid_W" description="ocean W grid variables" >
......
......@@ -32,16 +32,16 @@
<field field_ref="qt" name="sohefldo" />
<field field_ref="mldr10_1" name="somxl010" />
<field field_ref="mldkz5" name="somixhgt" />
<field field_ref="utau" name="sozotaux" />
<field field_ref="vtau" name="sometauy" />
</file>
<file id="file2" name_suffix="_grid_U" description="ocean U grid variables" >
<field field_ref="uoce" name="vozocrtx" />
<field field_ref="utau" name="sozotaux" />
</file>
<file id="file3" name_suffix="_grid_V" description="ocean V grid variables" >
<field field_ref="voce" name="vomecrty" />
<field field_ref="vtau" name="sometauy" />
</file>
<file id="file4" name_suffix="_grid_W" description="ocean W grid variables" >
......
......@@ -30,6 +30,8 @@
<field field_ref="qt_oce" name="qt_oce" />
<field field_ref="saltflx" name="sfx" />
<field field_ref="taum" name="taum" />
<field field_ref="utau" name="tauuo" />
<field field_ref="vtau" name="tauvo" />
<field field_ref="wspd" name="windsp" />
<field field_ref="precip" name="precip" />
<!-- ice and snow -->
......@@ -40,14 +42,12 @@
<field field_ref="e3u" />
<field field_ref="ssu" name="uos" />
<field field_ref="uoce" name="uo" />
<field field_ref="utau" name="tauuo" />
</file>
<file id="file13" name_suffix="_grid_V" description="ocean V grid variables" >
<field field_ref="e3v" />
<field field_ref="ssv" name="vos" />
<field field_ref="voce" name="vo" />
<field field_ref="vtau" name="tauvo" />
</file>
<file id="file14" name_suffix="_grid_ABL" description="ABL grid variables" >
......
......@@ -34,6 +34,8 @@
<field field_ref="qt_oce" name="qt_oce" />
<field field_ref="saltflx" name="sfx" />
<field field_ref="taum" name="taum" />
<field field_ref="utau" name="tauuo" />
<field field_ref="vtau" name="tauvo" />
<field field_ref="wspd" name="windsp" />
<field field_ref="precip" name="precip" />
<!-- ice and snow -->
......@@ -44,7 +46,6 @@
<field field_ref="e3u" />
<field field_ref="ssu" name="uos" />
<field field_ref="uoce" name="uo" operation="instant" freq_op="5d" > @uoce_e3u / @e3u </field>
<field field_ref="utau" name="tauuo" />
<field field_ref="uocetr_eff" name="uocetr_eff" />
<!-- available with diaar5 -->
<field field_ref="u_masstr" name="vozomatr" />
......@@ -56,7 +57,6 @@
<field field_ref="e3v" />
<field field_ref="ssv" name="vos" />
<field field_ref="voce" name="vo" operation="instant" freq_op="5d" > @voce_e3v / @e3v </field>
<field field_ref="vtau" name="tauvo" />
<field field_ref="vocetr_eff" name="vocetr_eff" />
<!-- available with diaar5 -->
<field field_ref="v_masstr" name="vomematr" />
......
......@@ -118,6 +118,17 @@
&namsbc_abl ! Atmospheric Boundary Layer formulation (ln_abl = T)
!-----------------------------------------------------------------------
cn_dom = 'dom_cfg_abl_L25Z10'
nn_dyn_restore = 2 ! restoring option for dynamical ABL variables: = 0 no restoring
! = 1 equatorial restoring
! = 2 global restoring
! = 1 equatorial restoring
! = 2 global restoring
rn_ldyn_min = 24. ! dynamics nudging magnitude inside the ABL [hour] (~3 rn_Dt)
rn_ldyn_max = 6. ! dynamics nudging magnitude above the ABL [hour] (~1 rn_Dt)
rn_ltra_min = 24. ! tracers nudging magnitude inside the ABL [hour] (~3 rn_Dt)
rn_ltra_max = 6. ! tracers nudging magnitude above the ABL [hour] (~1 rn_Dt)
rn_vfac = 1.
/
!-----------------------------------------------------------------------
&namtra_qsr ! penetrative solar radiation (ln_traqsr =T)
......
......@@ -36,12 +36,23 @@
<field field_ref="ssh" name="zos" />
</file>
<file id="file1" name_suffix="_trc" description="passive tracers variables" >
<file id="file2" name_suffix="_trc" description="passive tracers variables" >
<field field_ref="Age" name="Age" operation="average" freq_op="1y" > @Age_e3t / @e3t </field>
<field field_ref="CFC11" name="CFC11" operation="average" freq_op="1y" > @CFC11_e3t / @e3t </field>
<field field_ref="CFC12" name="CFC12" operation="average" freq_op="1y" > @CFC12_e3t / @e3t </field>
<field field_ref="SF6" name="SF6" operation="average" freq_op="1y" > @SF6_e3t / @e3t </field>
<field field_ref="RC14" name="RC14" operation="average" freq_op="1y" > @RC14_e3t / @e3t </field>
<field field_ref="RC14" name="RC14" operation="average" freq_op="1y" > @RC14_e3t / @e3t </field>
<field field_ref="qtr_CFC11" />
<field field_ref="qint_CFC11" />
<field field_ref="qtr_CFC12" />
<field field_ref="qint_CFC12" />
<field field_ref="qtr_SF6" />
<field field_ref="qint_SF6" />
<field field_ref="qtr_c14" />
<field field_ref="qint_c14" />
<field field_ref="DeltaC14" />
<field field_ref="C14Age" />
<field field_ref="RAge" />
</file>
</file_group>
......
......@@ -34,6 +34,8 @@
<field field_ref="qt_oce" name="qt_oce" />
<field field_ref="saltflx" name="sfx" />
<field field_ref="taum" name="taum" />
<field field_ref="utau" name="tauuo" />
<field field_ref="vtau" name="tauvo" />
<field field_ref="wspd" name="windsp" />
<field field_ref="precip" name="precip" />
<!-- ice and snow -->
......@@ -44,7 +46,6 @@
<field field_ref="e3u" />
<field field_ref="ssu" name="uos" />
<field field_ref="uoce" name="uo" operation="instant" freq_op="5d" > @uoce_e3u / @e3u </field>
<field field_ref="utau" name="tauuo" />
<field field_ref="uocetr_eff" name="uocetr_eff" />
<!-- available with diaar5 -->
<field field_ref="u_masstr" name="vozomatr" />
......@@ -56,7 +57,6 @@
<field field_ref="e3v" />
<field field_ref="ssv" name="vos" />
<field field_ref="voce" name="vo" operation="instant" freq_op="5d" > @voce_e3v / @e3v </field>
<field field_ref="vtau" name="tauvo" />
<field field_ref="vocetr_eff" name="vocetr_eff" />
<!-- available with diaar5 -->
<field field_ref="v_masstr" name="vomematr" />
......
......@@ -18,7 +18,7 @@
<field_group id="SBC" > <!-- time step automaticaly defined based on nn_fsbc -->
<!-- 2D variables -->
<field_group id="SBC_2D" grid_ref="grid_T_2D" >
<field_group id="SBC_2D" grid_ref="grid_T_2D_inner" >
<!-- =================== -->
<!-- standard ice fields -->
......@@ -311,7 +311,7 @@
</field_group> <!-- SBC_2D -->
<!-- categories -->
<field_group id="SBC_3D" grid_ref="grid_T_ncatice" >
<field_group id="SBC_3D" grid_ref="grid_T_ncatice_inner" >
<!-- standard ice fields -->
<field id="iceconc_cat" long_name="Sea-ice concentration per category" unit="" />
......@@ -386,7 +386,7 @@
-->
<!-- output variables for my configuration (example) -->
<field_group id="myvarICE" grid_ref="grid_T_2D" >
<field_group id="myvarICE" >
<!-- ice mask -->
<field field_ref="icemask" name="simsk" />
<field field_ref="icemask05" name="simsk05" />
......@@ -495,7 +495,7 @@
</field_group>
<field_group id="myvarICE_cat" grid_ref="grid_T_ncatice" >
<field_group id="myvarICE_cat" >
<!-- categories -->
<field field_ref="icemask_cat" name="simskcat"/>
......@@ -524,7 +524,7 @@
<field field_ref="ilbgvol_tot" name="ilbgvol_tot" />
</field_group>
<field_group id="ICE_budget" grid_ref="grid_T_2D" >
<field_group id="ICE_budget" >
<!-- general -->
<field field_ref="icemask" name="simsk" />
<field field_ref="iceconc" name="siconc" />
......@@ -579,7 +579,7 @@
</field_group>
<!-- SIMIP daily fields -->
<field_group id="SIday_fields" grid_ref="grid_T_2D" >
<field_group id="SIday_fields" >
<field field_ref="icepres" name="sitimefrac" />
<field field_ref="iceconc_pct" name="siconc" />
<field field_ref="icethic_cmip" name="sithick" />
......@@ -591,7 +591,7 @@
</field_group>
<!-- SIMIP monthly fields -->
<field_group id="SImon_fields" grid_ref="grid_T_2D" >
<field_group id="SImon_fields" >
<!-- Sea-ice state variables -->
<field field_ref="icepres" name="sitimefrac" />
<field field_ref="iceconc_pct" name="siconc" />
......
......@@ -16,7 +16,7 @@
-->
<field_group id="inerttrc" grid_ref="grid_T_2D">
<field_group id="inerttrc" grid_ref="grid_T_2D_inner">
<!-- CFC11 : variables available with ln_cfc11 -->
<field id="CFC11" long_name="Chlorofluoro carbon11 Concentration" unit="umol/m3" grid_ref="grid_T_3D" />
......@@ -39,8 +39,8 @@
<!-- C14 : variables available with ln_c14 -->
<field id="RC14" long_name="Radiocarbon ratio" unit="-" grid_ref="grid_T_3D" />
<field id="RC14_e3t" long_name="RC14 * e3t" unit="m" grid_ref="grid_T_3D" > RC14 * e3t </field >
<field id="DeltaC14" long_name="Delta C14" unit="permil" grid_ref="grid_T_3D" />
<field id="C14Age" long_name="Radiocarbon age" unit="yr" grid_ref="grid_T_3D" />
<field id="DeltaC14" long_name="Delta C14" unit="permil" grid_ref="grid_T_3D_inner" />
<field id="C14Age" long_name="Radiocarbon age" unit="yr" grid_ref="grid_T_3D_inner" />
<field id="RAge" long_name="Reservoir Age" unit="yr" />
<field id="qtr_c14" long_name="Air-sea flux of C14" unit="1/m2/s" />
<field id="qint_c14" long_name="Cumulative air-sea flux of C14" unit="1/m2" />
......@@ -52,7 +52,7 @@
<!-- AGE : variables available with ln_age -->
<field id="Age" long_name="Sea water age since surface contact" unit="yr" grid_ref="grid_T_3D" />
<field id="Age_e3t" long_name="Age * e3t" unit="yr * m" grid_ref="grid_T_3D" > Age * e3t </field >
<field id="Age_e3t" long_name="Age * e3t" unit="yr * m" grid_ref="grid_T_3D" > Age * e3t </field >
</field_group>
......
This diff is collapsed.
This diff is collapsed.
......@@ -318,14 +318,14 @@
<!-- ABL grid definition -->
<grid id="grid_TA_2D">
<domain domain_ref="grid_T" />
<domain domain_ref="grid_T_inner" />
</grid>
<grid id="grid_TA_3D">
<domain domain_ref="grid_T" />
<domain domain_ref="grid_T_inner" />
<axis id="ght_abl" />
</grid>
<grid id="grid_WA_3D">
<domain domain_ref="grid_T" />
<domain domain_ref="grid_T_inner" />
<axis id="ghw_abl" />
</grid>
<!-- -->
......@@ -336,41 +336,44 @@
<scalar />
</grid>
<grid id="diamlr_grid_T_2D" >
<domain domain_ref="grid_T" />
<domain domain_ref="grid_T_inner" />
<scalar />
</grid>
<grid id="diamlr_grid_T_2D_inner" >
<domain domain_ref="grid_T_inner" />
</grid>
<grid id="diamlr_grid_U_2D" >
<domain domain_ref="grid_U" />
<domain domain_ref="grid_U_inner" />
<scalar />
</grid>
<grid id="diamlr_grid_V_2D" >
<domain domain_ref="grid_V" />
<domain domain_ref="grid_V_inner" />
<scalar />
</grid>
<grid id="diamlr_grid_W_2D" >
<domain domain_ref="grid_W" />
<domain domain_ref="grid_W_inner" />
<scalar />
</grid>
<grid id="diamlr_grid_2D_to_grid_T_3D" >
<domain domain_ref="grid_T" />
<domain domain_ref="grid_T_inner" />
<axis axis_ref="deptht">
<duplicate_scalar />
</axis>
</grid>
<grid id="diamlr_grid_2D_to_grid_U_3D" >
<domain domain_ref="grid_U" />
<domain domain_ref="grid_U_inner" />
<axis axis_ref="depthu">
<duplicate_scalar />
</axis>
</grid>
<grid id="diamlr_grid_2D_to_grid_V_3D" >
<domain domain_ref="grid_V" />
<domain domain_ref="grid_V_inner" />
<axis axis_ref="depthv">
<duplicate_scalar />
</axis>
</grid>
<grid id="diamlr_grid_2D_to_grid_W_3D" >
<domain domain_ref="grid_W" />
<domain domain_ref="grid_W_inner" />
<axis axis_ref="depthw">
<duplicate_scalar />
</axis>
......@@ -383,37 +386,37 @@
</grid>
<!-- grid definitions for the computation of daily detided model diagnostics (diadetide) -->
<grid id="diadetide_grid_T_2D" >
<domain domain_ref="grid_T" />
<domain domain_ref="grid_T_inner" />
<scalar />
</grid>
<grid id="diadetide_grid_U_2D" >
<domain domain_ref="grid_U" />
<domain domain_ref="grid_U_inner" />
<scalar />
</grid>
<grid id="diadetide_grid_V_2D" >
<domain domain_ref="grid_V" />
<domain domain_ref="grid_V_inner" />
<scalar />
</grid>
<grid id="diadetide_grid_2D_to_grid_T_3D" >
<domain domain_ref="grid_T" />
<domain domain_ref="grid_T_inner" />
<axis axis_ref="deptht">
<duplicate_scalar />
</axis>
</grid>
<grid id="diadetide_grid_2D_to_grid_U_3D" >
<domain domain_ref="grid_U" />
<domain domain_ref="grid_U_inner" />
<axis axis_ref="depthu">
<duplicate_scalar />
</axis>
</grid>
<grid id="diadetide_grid_2D_to_grid_V_3D" >
<domain domain_ref="grid_V" />
<domain domain_ref="grid_V_inner" />
<axis axis_ref="depthv">
<duplicate_scalar />
</axis>
</grid>
<grid id="diadetide_grid_2D_to_grid_W_3D" >
<domain domain_ref="grid_W" />
<domain domain_ref="grid_W_inner" />
<axis axis_ref="depthw">
<duplicate_scalar />
</axis>
......
......@@ -312,7 +312,7 @@
&namsbc_abl ! Atmospheric Boundary Layer formulation (ln_abl = T)
!-----------------------------------------------------------------------
cn_dir = './' ! root directory for the location of the ABL grid file
cn_dom = 'dom_cfg_abl.nc'
cn_dom = 'dom_cfg_abl'
cn_ablrst_in = "restart_abl" ! suffix of abl restart name (input)
cn_ablrst_out = "restart_abl" ! suffix of abl restart name (output)
......@@ -326,11 +326,11 @@
nn_dyn_restore = 0 ! restoring option for dynamical ABL variables: = 0 no restoring
! = 1 equatorial restoring
! = 2 global restoring
rn_vfac = 0.
rn_ldyn_min = 4.5 ! dynamics nudging magnitude inside the ABL [hour] (~3 rn_Dt)
rn_ldyn_max = 1.5 ! dynamics nudging magnitude above the ABL [hour] (~1 rn_Dt)
rn_ltra_min = 4.5 ! tracers nudging magnitude inside the ABL [hour] (~3 rn_Dt)
rn_ltra_max = 1.5 ! tracers nudging magnitude above the ABL [hour] (~1 rn_Dt)
rn_ldyn_min = 0. ! dynamics nudging magnitude inside the ABL [hour] (~3 rn_Dt)
rn_ldyn_max = 0. ! dynamics nudging magnitude above the ABL [hour] (~1 rn_Dt)
rn_ltra_min = 0. ! tracers nudging magnitude inside the ABL [hour] (~3 rn_Dt)
rn_ltra_max = 0. ! tracers nudging magnitude above the ABL [hour] (~1 rn_Dt)
rn_vfac = 0.
nn_amxl = 0 ! mixing length: = 0 Deardorff 80 length-scale
! = 1 length-scale based on the distance to the PBL height
! = 2 Bougeault & Lacarrere 89 length-scale
......@@ -370,7 +370,7 @@
!*** receive ***
sn_rcv_w10m = 'none' , 'no' , '' , '' , ''
sn_rcv_taumod = 'coupled' , 'no' , '' , '' , ''
sn_rcv_tau = 'oce only' , 'no' , 'cartesian' , 'eastward-northward' , 'U,V'
sn_rcv_tau = 'oce only' , 'no' , 'cartesian' , 'eastward-northward' , ''
sn_rcv_dqnsdt = 'coupled' , 'no' , '' , '' , ''
sn_rcv_qsr = 'oce and ice' , 'no' , '' , '' , ''
sn_rcv_qns = 'oce and ice' , 'no' , '' , '' , ''
......@@ -381,21 +381,22 @@
sn_rcv_iceflx = 'none' , 'no' , '' , '' , ''
sn_rcv_mslp = 'none' , 'no' , '' , '' , ''
sn_rcv_ts_ice = 'none' , 'no' , '' , '' , ''
sn_rcv_qtrice = 'none' , 'no' , '' , '' , ''
sn_rcv_isf = 'none' , 'no' , '' , '' , ''
sn_rcv_icb = 'none' , 'no' , '' , '' , ''
sn_rcv_hsig = 'none' , 'no' , '' , '' , 'T'
sn_rcv_phioc = 'none' , 'no' , '' , '' , 'T'
sn_rcv_sdrfx = 'none' , 'no' , '' , '' , 'T'
sn_rcv_sdrfy = 'none' , 'no' , '' , '' , 'T'
sn_rcv_wper = 'none' , 'no' , '' , '' , 'T'
sn_rcv_wnum = 'none' , 'no' , '' , '' , 'T'
sn_rcv_wstrf = 'none' , 'no' , '' , '' , 'T'
sn_rcv_wdrag = 'none' , 'no' , '' , '' , 'T'
sn_rcv_charn = 'none' , 'no' , '' , '' , 'T'
sn_rcv_taw = 'none' , 'no' , '' , '' , 'U,V'
sn_rcv_bhd = 'none' , 'no' , '' , '' , 'T'
sn_rcv_tusd = 'none' , 'no' , '' , '' , 'T'
sn_rcv_tvsd = 'none' , 'no' , '' , '' , 'T'
sn_rcv_hsig = 'none' , 'no' , '' , '' , ''
sn_rcv_phioc = 'none' , 'no' , '' , '' , ''
sn_rcv_sdrfx = 'none' , 'no' , '' , '' , ''
sn_rcv_sdrfy = 'none' , 'no' , '' , '' , ''
sn_rcv_wper = 'none' , 'no' , '' , '' , ''
sn_rcv_wnum = 'none' , 'no' , '' , '' , ''
sn_rcv_wstrf = 'none' , 'no' , '' , '' , ''
sn_rcv_wdrag = 'none' , 'no' , '' , '' , ''
sn_rcv_charn = 'none' , 'no' , '' , '' , ''
sn_rcv_taw = 'none' , 'no' , '' , '' , ''
sn_rcv_bhd = 'none' , 'no' , '' , '' , ''
sn_rcv_tusd = 'none' , 'no' , '' , '' , ''
sn_rcv_tvsd = 'none' , 'no' , '' , '' , ''
/
!-----------------------------------------------------------------------
&namsbc_sas ! Stand-Alone Surface module: ocean data (SAS_SRC only)
......@@ -883,6 +884,9 @@
!
! ! S-EOS coefficients (ln_seos=T):
! ! rd(T,S,Z)*rho0 = -a0*(1+.5*lambda*dT+mu*Z+nu*dS)*dT+b0*dS
! ! dT = T-rn_T0 ; dS = S-rn_S0
rn_T0 = 10. ! reference temperature
rn_S0 = 35. ! reference salinity
rn_a0 = 1.6550e-1 ! thermal expension coefficient
rn_b0 = 7.6554e-1 ! saline expension coefficient
rn_lambda1 = 5.9520e-2 ! cabbeling coeff in T^2 (=0 for linear eos)
......
......@@ -34,6 +34,8 @@
<field field_ref="qt_oce" name="qt_oce" />
<field field_ref="saltflx" name="sfx" />
<field field_ref="taum" name="taum" />
<field field_ref="utau" name="tauuo" />
<field field_ref="vtau" name="tauvo" />
<field field_ref="wspd" name="windsp" />
<field field_ref="precip" name="precip" />
<!-- ice and snow -->
......@@ -44,7 +46,6 @@
<field field_ref="e3u" />
<field field_ref="ssu" name="uos" />
<field field_ref="uoce" name="uo" operation="instant" freq_op="5d" > @uoce_e3u / @e3u </field>
<field field_ref="utau" name="tauuo" />
<field field_ref="uocetr_eff" name="uocetr_eff" />
<!-- available with diaar5 -->
<field field_ref="u_masstr" name="vozomatr" />
......@@ -56,7 +57,6 @@
<field field_ref="e3v" />
<field field_ref="ssv" name="vos" />
<field field_ref="voce" name="vo" operation="instant" freq_op="5d" > @voce_e3v / @e3v </field>
<field field_ref="vtau" name="tauvo" />
<field field_ref="vocetr_eff" name="vocetr_eff" />
<!-- available with diaar5 -->
<field field_ref="v_masstr" name="vomematr" />
......
......@@ -31,6 +31,8 @@
<field field_ref="qt_oce" name="qt_oce" />
<field field_ref="saltflx" name="sfx" />
<field field_ref="taum" name="taum" />
<field field_ref="utau" name="tauuo" />
<field field_ref="vtau" name="tauvo" />
<field field_ref="wspd" name="windsp" />
<field field_ref="precip" name="precip" />
<field field_ref="snowpre" />
......@@ -67,14 +69,12 @@
<field field_ref="e3u" />
<field field_ref="ssu" name="uos" />
<field field_ref="uoce" name="uo" operation="instant" freq_op="5d" > @uoce_e3u / @e3u </field>
<field field_ref="utau" name="tauuo" />
</file>
<file id="file13" name_suffix="_grid_V" description="ocean V grid variables" >
<field field_ref="e3v" />
<field field_ref="ssv" name="vos" />
<field field_ref="voce" name="vo" operation="instant" freq_op="5d" > @voce_e3v / @e3v </field>
<field field_ref="vtau" name="tauvo" />
</file>
<file id="file14" name_suffix="_grid_W" description="ocean W grid variables" >
......
......@@ -86,6 +86,7 @@ set -o posix
x_d=''; x_h=''; x_n=''; x_r=''; x_c='';
x_u=''; x_a=''; x_m=''; x_t=''; x_b='';
x_j='1'; x_e='none'; x_s='src'; x_v='1'
x_c_cfg=0
x_nocdf=0
x_name=''
......@@ -101,7 +102,7 @@ MAIN_DIR=${MAIN_DIR%/ext*}
MAIN_DIR=${MAIN_DIR%/arch*}
export MAIN_DIR
#
export CONFIG_DIR=${MAIN_DIR}/cfgs
export CFGS_DIR=${MAIN_DIR}/cfgs
export TESTS_DIR=${MAIN_DIR}/tests
export TOOLS_DIR=${MAIN_DIR}/tools
export COMPIL_DIR=${MAIN_DIR}/mk
......@@ -109,41 +110,48 @@ export NEMO_DIR=${MAIN_DIR}/${x_s}
export AGRIFUSE='10'
list_key='0'; chk_key='1'
list_add_key=''; list_def_key=''; list_del_key=''
conf_file=ref_cfgs.txt
#-
#- FCM and functions location ---
export PATH=${MAIN_DIR}/ext/FCM/bin:$PATH
#-
#- Choice of the options ---
## Get clean, clean_config options
while [ ${#1} -gt 0 ]; do
case "$1" in
-h|--help) cat <<EOF
Usage:
------
./makenemo -[arn] CONFIG -m ARCH [-[...] ...] [{list_key,clean,clean_config}]
./makenemo -[arn] CONFIG -m ARCH [-[...] ...]
Mandatory
-m, --mach, --machine, --arch <machine_name>
Computing architecture, will use the file arch_<machine_name>.fcm located in ./arch (sub)directory(ies)
Computing architecture, will use the file arch_<machine_name>.fcm located
in ./arch (sub)directory(ies)
-n, --name <config_name>
Name of the configuration to compile
and, if -n defines a new configuration, one of the following option (use 'all' arg to list available items):
and, if -n defines a new configuration, one of the following option (use 'all' arg to
list available items):
-r, --ref <ref_config_name>
To specify which reference configuration (./cfgs) must be used to buit the new configuration
To specify which reference configuration (./cfgs) must be used to buit the
new configuration
-a, --test <test_config_name>
To specify which academic test case (./tests) must be used to buit the new configuration
To specify which academic test case (./tests) must be used to buit the new
configuration
Optional
--add_key, key_add, add_key "<list of keys>"
list of cpp keys to be added in cpp_<config_name>.fcm file
-b, --dbg, --debug
add it to compile in debug mode
--clean, --clean_compil, clean
Clean all files and directories used for compilation + the REPRO_* and
the SHORT directories
--clean_config, clean_config
Completly delete a configuration
-d, --dirs, --comp <sub-components>
New set of sub-components (subfolders from ./src directory) to be used
--def_key, key_def, def_key "<list of keys>"
......@@ -157,8 +165,10 @@ Optional
-j, --jobs <nb_job>
Number of processes to compile (0: dry run with no build)
-k, --chkkey <O/1>
Set to 0 to bypass the check of the cpp keys (takes time at the beginning of makenemo).
Default is 1
Set to 0 to bypass the check of the cpp keys (takes time at the beginning
of makenemo). Default is 1
--list_key, --key_list, list_key
List all existing cpp keys in the configuration and exit without compiling
--nonc, --nocdf, --nonetcdf, --no_nc, --no_cdf, --no_netcdf
Compile without the NetCDF Library
-s, --srcpath, --src_path <path>
......@@ -174,9 +184,9 @@ Examples
Copy : ./makenemo -n ... -[ar] ... [...]
¤ Configuration management
List CPP keys : ./makenemo -n ... list_key
Add-Remove keys: ./makenemo -n ... add_key '...' del_key '...'
Fresh start : ./makenemo -n ... clean
Removal : ./makenemo -n ... clean_config
Add-Remove keys: ./makenemo -n ... --add_key '...' --del_key '...'
Fresh start : ./makenemo -n ... --clean
Removal : ./makenemo -n ... --clean_config
EOF
exit 0 ;;
......@@ -205,18 +215,15 @@ EOF
chk_key=${2} ; shift ;;
--nonc|--nocdf|--nonetcdf|--no_nc|--no_cdf|--no_netcdf)
x_nocdf=1 ;;
--clean|clean)
x_c="--$1" ;;
--clean|--clean_compil|clean)
x_c="--clean" ;;
--clean_config|clean_config)
. ${COMPIL_DIR}/Fclean_config.sh; exit ;;
## Checking if argument has anything other than whitespace
x_c_cfg=1 ;;
--add_key|--key_add|add_key ) [[ ! "$2" =~ ^\ +$ ]] && list_add_key=$2; shift;;
--def_key|--key_def|def_key ) [[ ! "$2" =~ ^\ +$ ]] && list_def_key=$2; shift;;
--del_key|--key_del|del_key ) [[ ! "$2" =~ ^\ +$ ]] && list_del_key=$2; shift;;
--list_key|list_key ) list_key='1' ;;
'*' ) echo " \"$1\" BAD OPTION"; exit 2 ;;
':') echo ${b_n}" : -"${1}" option : missing value" 1>&2; exit 2 ;;
'?') echo ${b_n}" : -"${1}" option : not supported" 1>&2; exit 2 ;;
--list_key|--key_list|list_key) list_key='1' ;;
*) echo -e "\033[0;31m\n \"$1\" BAD OPTION\033[0m\n"; exit 2 ;;
esac
shift
......@@ -224,11 +231,30 @@ done
if [ -n "$x_name" ] # is the configuration existing in cfgs or tests? or is it a new conf?
then
incfg=$( find $CONFIG_DIR -type d -name $x_name | wc -l ) # this configuration exists in CONFIG_DIR
intst=$( find $TESTS_DIR -type d -name $x_name | wc -l ) # this configuration exists in TESTS_DIR
[[ $incfg -eq 0 && $intst -eq 0 ]] && x_n=$x_name # this is a new configuration -> dedine/overwrite x_n
[[ $incfg -eq 1 && -z "$x_r" ]] && x_r=$x_name # this is a reference configuration -> dedine/overwrite x_r
[[ $intst -eq 1 && -z "$x_a" ]] && x_a=$x_name # this is a test configuration -> dedine/overwrite x_a
incfg=$( find $CFGS_DIR -type d -name $x_name | wc -l ) # this configuration exists in CFGS_DIR
intst=$( find $TESTS_DIR -type d -name $x_name | wc -l ) # this configuration exists in TESTS_DIR
if [ $(( $incfg + $intst )) -eq 2 ] ; then
echo -e "\033[0;31m\nERROR: the $x_name directory is found twice: in $CFGS_DIR and in $TESTS_DIR\033[0m\n"
exit 4
fi
if [ $(( $incfg + $intst )) -gt 0 ] ; then
if [ $x_c_cfg -eq 1 ] ; then # if we just want to clean the config (do it here as it must exist)
x_n=$x_name # must define x_n as it is used in Fclean_config.sh
. ${COMPIL_DIR}/Fclean_config.sh
exit 0
fi
[ -n "$x_r" ] && echo -e "\nWARNING: $x_name configuration is already existing, we ignore \"-r $x_r\"\n"
[ -n "$x_a" ] && echo -e "\nWARNING: $x_name configuration is already existing, we ignore \"-a $x_a\"\n"
fi
if [ $incfg -eq 1 ] ; then
x_r=$x_name ; x_a='' # reference configuration existing -> define/overwrite x_r
elif [ $intst -eq 1 ] ; then
x_a=$x_name ; x_r='' # test configuration existing -> define/overwrite x_a
else
[ ${#x_c} -ne 0 ] && echo -e "\nWARNING: Compilation cleaning of a non-existing configuration, we ignore\n" && exit 0
[ $x_c_cfg -eq 1 ] && echo -e "\nWARNING: Configuration cleaning of a non-existing configuration, we ignore\n" && exit 0
x_n=$x_name # this is a new configuration -> define
fi
fi
export NEW_CONF=${x_n}
......@@ -237,74 +263,63 @@ CMP_NAM=${x_m}
NEM_SUBDIR=${x_d}
REF_CONF=${x_r}
DEMO_CONF=${x_a}
TML_CONF=${REF_CONF}
export NEMO_DIR=${MAIN_DIR}/${x_s}
NEMO_DBG=${x_b}
[ "${CMP_NAM}" == 'all' ] && . ${COMPIL_DIR}/Flist_archfile.sh all && exit
## No ref. cfg, demo case, nor remote cfg selected
## No ref. cfg or demo selected
if [[ -z "${REF_CONF}" && -z "${DEMO_CONF}" ]]; then
## Reuse last configuration compiled if any (existing 'work_cfgs.txt')
# if [[ $( find ./cfgs ./tests -name work_cfgs.txt ) ]]; then
# CONFIG_DIR=${MAIN_DIR}/$( ls -rt */work_cfgs.txt | awk -F/ 'END{ print $1}' )
# TML_CONF=$( tail -1 ${CONFIG_DIR}/work_cfgs.txt | awk '{ print $1 }' )
# else
## No ${REF_CONF}, ${DEMO_CONF} nor ${NEM_SUBDIR} and 1st compilation => exit
# echo -e "\033[0;33m\nNo previous build found!"
echo -e "\033[0;31m\nAt least a reference configuration ('-r'), a test case ('-a'), "
echo -e "a remote configuration ('-u') has to be choosen!!!\033[0m"
${COMPIL_DIR}/Flist_cfgs.sh
exit 2
# fi
echo -e "\033[0;31m\nAt least a reference configuration ('-r'), a test case ('-a'), "
echo -e "a remote configuration ('-u') has to be choosen to build a new configuration!!!\033[0m"
${COMPIL_DIR}/Flist_cfgs.sh
exit 2
fi
## At least one config has been requested
else
## 'all' arg: list all available configurations
if [[ "${REF_CONF}" == 'all' || "${DEMO_CONF}" == 'all' ]]; then
${COMPIL_DIR}/Flist_cfgs.sh
exit 2
## Probably useless but who knows?
elif [[ -n "${REF_CONF}" && -n "${DEMO_CONF}" ]]; then
echo -e "\033[0;31m\nYou have to choose whether you work with:"
echo -e " - LTS configurations in ./cfgs ('-r') or"
echo -e " - Unsupported cases in ./tests ('-a')\033[0m\n"
exit 2
fi
## Demo case
if [ -n "${DEMO_CONF}" ]; then
conf_file=demo_cfgs.txt; CONFIG_DIR=${MAIN_DIR}/tests; TML_CONF=${DEMO_CONF}
fi
## 'all' arg: list all available configurations
if [[ "${REF_CONF}" == 'all' || "${DEMO_CONF}" == 'all' ]]; then
${COMPIL_DIR}/Flist_cfgs.sh
exit 2
## Probably useless but who knows?
elif [[ -n "${REF_CONF}" && -n "${DEMO_CONF}" ]]; then
echo -e "\033[0;31m\nYou have to choose whether you work with:"
echo -e " - LTS configurations in ./cfgs ('-r') or"
echo -e " - Unsupported cases in ./tests ('-a')\033[0m\n"
exit 2
elif [ -n "${REF_CONF}" ]; then
conf_file=ref_cfgs.txt ; export CONFIG_DIR=${CFGS_DIR} ; TML_CONF=${REF_CONF}
elif [ -n "${DEMO_CONF}" ]; then
conf_file=demo_cfgs.txt; export CONFIG_DIR=${TESTS_DIR}; TML_CONF=${DEMO_CONF}
fi
## Reuse a working cfg
grep -q "${TML_CONF} " ${CONFIG_DIR}/work_cfgs.txt 2>/dev/null && conf_file=work_cfgs.txt
## Test if ref. cfg or demo case does exist
if [[ ! $( grep "${TML_CONF} " ${CONFIG_DIR}/*_cfgs.txt ) ]]; then
echo -e "\033[0;31m\nThe reference configuration ('-r'), demonstration case ('-a') or "
echo -e "remote configuration ('-u') selected is not available!!!"
echo -e "Check the option used and the available items in .txt files\033[0m"
${COMPIL_DIR}/Flist_cfgs.sh
exit 2
if (! grep -q "${TML_CONF} " ${CONFIG_DIR}/$conf_file ); then
echo -e "\033[0;31m\nThe reference configuration ('-r') or "
echo -e "demonstration case ('-a') selected is not available!!!"
echo -e "Check the option used and the available items in .txt files\033[0m"
${COMPIL_DIR}/Flist_cfgs.sh
exit 2
fi
## If new cfg exists, work in it
if [ -n "${NEW_CONF}" ]
then
echo
printf "\nYou are installing a new configuration %s from %s " ${NEW_CONF} ${TML_CONF}
printf "with sub-components: %s\n" "${NEM_SUBDIR}"
echo
else
NEW_CONF=${TML_CONF}
fi
## Reuse a working cfg
if [[ -f ${CONFIG_DIR}/work_cfgs.txt && $( grep "${TML_CONF} " ${CONFIG_DIR}/work_cfgs.txt ) ]]; then
conf_file=work_cfgs.txt
fi
## If new cfg exists, work in it
[ -z "${NEW_CONF}" ] && NEW_CONF=${TML_CONF}
## Update sub-comps if needed
if [ -z "${NEM_SUBDIR}" ]; then
NEM_SUBDIR=$( grep "${TML_CONF} " ${CONFIG_DIR}/${conf_file} | awk '{$1 = ""; print $0}' )
fi
## Update sub-comps if needed
if [ -z "${NEM_SUBDIR}" ]; then
NEM_SUBDIR=$( grep "${TML_CONF} " ${CONFIG_DIR}/${conf_file} | awk '{$1 = ""; print $0}' )
fi
export NEMO_TDIR=${x_t:-$CONFIG_DIR}
......@@ -316,14 +331,6 @@ echo ${NEW_CONF} "${NEM_SUBDIR}" >> ${CONFIG_DIR}/work_cfgs.txt
cd ${CONFIG_DIR}
if [ -n "${NEW_CONF}" ]
then
echo
printf "\nYou are installing a new configuration %s from %s " ${NEW_CONF} ${TML_CONF}
printf "with sub-components: %s\n" "${NEM_SUBDIR}"
echo
fi
## Create new config even in existing one (mkdir with -p option, cp with -n)
${COMPIL_DIR}/Fmake_config.sh ${NEW_CONF} ${TML_CONF}
......@@ -338,15 +345,13 @@ ${COMPIL_DIR}/Fmake_config.sh ${NEW_CONF} ${TML_CONF}
. ${COMPIL_DIR}/Fmake_bld.sh ${CONFIG_DIR} ${NEW_CONF} ${NEMO_TDIR} || exit 3
# build the complete list of the cpp keys of this configuration
if [ ${chk_key} -eq 1 ] ; then
for i in $( grep "^ *#.* key_" ${NEW_CONF}/WORK/* ); do
echo $i | grep key_ | sed -e "s/=.*//"
done \
if [[ ${chk_key} -eq 1 || ${list_key} -eq 1 ]] ; then
for i in $( grep "^ *#.* key_" ${NEW_CONF}/WORK/* ); do
echo $i | grep key_ | sed -e "s/=.*//"
done \
| sort -d | uniq > ${COMPIL_DIR}/full_key_list.txt
[ ${list_key} -eq 1 ] && cat ${COMPIL_DIR}/full_key_list.txt && exit 0
[ ${list_key} -eq 1 ] && echo && cat ${COMPIL_DIR}/full_key_list.txt && exit 0
fi
#- At this stage new configuration has been added, we add or remove keys
......@@ -356,24 +361,18 @@ fi
#- check that all keys are really existing...
if [ $chk_key -eq 1 ] ; then
for kk in $( cat ${NEW_CONF}/cpp_${NEW_CONF}.fcm ); do
if [ "$( echo $kk | cut -c 1-4 )" == "key_" ]; then
kk=${kk/=*/}
if [ ! $( grep -w $kk ${COMPIL_DIR}/full_key_list.txt ) ]; then
echo
echo "E R R O R : key "$kk" is not found in ${NEW_CONF}/WORK routines..."
echo "we stop..."
echo
exit 1
fi
fi
done
for kk in $( cat ${NEW_CONF}/cpp_${NEW_CONF}.fcm ); do
if [ "$( echo $kk | cut -c 1-4 )" == "key_" ]; then
kk=${kk/=*/}
if [ ! $( grep -w $kk ${COMPIL_DIR}/full_key_list.txt ) ]; then
echo
echo "E R R O R : key "$kk" is not found in ${NEW_CONF}/WORK routines..."
echo "we stop..."
echo
exit 1
fi
fi
done
fi
#- At this stage cpp keys have been updated. we can check the arch file
......@@ -396,39 +395,35 @@ grep key_agrif ${COMPIL_DIR}/cpp.fcm && export AGRIFUSE=1 && export USEBLD=${USE
#- Compile ---
if [ "${NBR_PRC}" -gt 0 ]; then
cd ${NEMO_TDIR}/${NEW_CONF} || cd -
## if AGRIF we do a first preprocessing
if [[ ${#x_c} -eq 0 && "$AGRIFUSE" -eq 1 ]]; then
fcm build --ignore-lock -j 1 ${COMPIL_DIR}/bld_preproagr.cfg ||{ cd - ; exit 1 ;}
echo ''
echo "---------------------------------"
echo "CONV preprocessing successfull !!"
echo "---------------------------------"
echo ''
fi
fcm build ${x_c} --ignore-lock -v ${x_v} -j ${NBR_PRC} ${COMPIL_DIR}/$USEBLD ||{ cd - ; exit 1 ;}
if [ -f ${NEMO_TDIR}/${NEW_CONF}/BLD/bin/nemo.exe ]; then
ln -sf ${NEMO_TDIR}/${NEW_CONF}/BLD/bin/nemo.exe ${CONFIG_DIR}/${NEW_CONF}/EXP00/nemo
fi
## add remove for clean option
if [ ${#x_c} -ne 0 ]; then
echo 'Cleaning in '${NEW_CONF}' the building folders'
for dir in AGRIFLIB BLD LONG NEMOFILES REPRO_* SHORT WORK; do
rm -rf ${NEMO_TDIR}/${NEW_CONF}/$dir
done
for file in cpp.history cpp.fcm full_key_list.txt; do
rm -f ${COMPIL_DIR}/$file
done
cd ${NEMO_TDIR}/${NEW_CONF} || cd -
## if AGRIF we do a first preprocessing
if [[ ${#x_c} -eq 0 && "$AGRIFUSE" -eq 1 ]]; then
fcm build --ignore-lock -j 1 ${COMPIL_DIR}/bld_preproagr.cfg ||{ cd - ; exit 1 ;}
echo ''
echo "---------------------------------"
echo "CONV preprocessing successfull !!"
echo "---------------------------------"
echo ''
fi
fcm build ${x_c} --ignore-lock -v ${x_v} -j ${NBR_PRC} ${COMPIL_DIR}/$USEBLD ||{ cd - ; exit 1 ;}
fi
if [ -f ${NEMO_TDIR}/${NEW_CONF}/BLD/bin/nemo.exe ]; then
ln -sf ${NEMO_TDIR}/${NEW_CONF}/BLD/bin/nemo.exe ${CONFIG_DIR}/${NEW_CONF}/EXP00/nemo
fi
## add remove for clean option
if [ ${#x_c} -ne 0 ]; then
echo -e '\nCleaning '${NEW_CONF}' building directories and variables\n'
for dir in AGRIFLIB BLD LONG NEMOFILES REPRO_* SHORT WORK; do
rm -rf ${NEMO_TDIR}/${NEW_CONF}/$dir
done
for file in cpp.history cpp.fcm full_key_list.txt; do
rm -f ${COMPIL_DIR}/$file
done
fi
fi
#- Come back to original directory ---
......
......@@ -69,6 +69,7 @@ if [ ${#NEW_CONF} -eq 0 ] ; then
echo " "
echo "No configuration specified, please use makenemo -n CONFIG clean_config "
else
echo " "
echo "Are you sure that you want to remove this directory $NEW_CONF? [y/n] "
read answer
answer=`echo $answer | sed 's/^[y].*$/y/'`
......
#!/bin/bash
######################################################
# Author :
# Contact :
#
# Some functions called from makenemo
# Fdef_keys : define keys in cpp.fcm file
######################################################
#set -x
set -o posix
#set -u
#set -e
#+
#
# ================
# Fdef_keys.sh
# ================
#
# --------------------------
# Add compilation keys
# --------------------------
#
# SYNOPSIS
# ========
#
# ::
#
# $ Fdef_keys.sh CONFIG_NAME def_key "LIST_KEYS"
#
#
# DESCRIPTION
# ===========
#
#
# define cpp keys when compiling a configuration, key list has to be enclosed with " ".
#
# EXAMPLES
# ========
#
# ::
#
# $ ./Fdef_keys.sh CONFIG_NAME def_key "key_agrif"
#
#
# TODO
# ====
#
# option debug
#
#
# EVOLUTIONS
# ==========
#
#
# * creation
#
#-
echo "Defining keys in : ${NEW_CONF}"
echo " bld::tool::fppkeys ${list_def_key}" > ${CONFIG_DIR}/${NEW_CONF}/cpp_${NEW_CONF}.fcm
unset -v list_def_key