Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
G
GOSI9esm
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Consortium Members
UKMO
GOSI
GOSI9esm
Commits
f5d53a97
Commit
f5d53a97
authored
2 years ago
by
Guillaume Samson
Browse files
Options
Downloads
Patches
Plain Diff
Merge branch '74-issues-with-ssh-initialization-in-iceinit-with-vvl-and-agrif' into 'branch_4.2'
parent
215547f6
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/NST/agrif_ice_interp.F90
+61
-3
61 additions, 3 deletions
src/NST/agrif_ice_interp.F90
src/OCE/DOM/domain.F90
+8
-0
8 additions, 0 deletions
src/OCE/DOM/domain.F90
src/OCE/IOM/restart.F90
+5
-12
5 additions, 12 deletions
src/OCE/IOM/restart.F90
with
74 additions
and
15 deletions
src/NST/agrif_ice_interp.F90
+
61
−
3
View file @
f5d53a97
...
...
@@ -26,13 +26,17 @@ MODULE agrif_ice_interp
USE
phycst
,
ONLY
:
rt0
USE
icevar
USE
sbc_ice
,
ONLY
:
tn_ice
USE
lbclnk
USE
lbclnk
USE
iceistate
,
ONLY
:
rsshadj
USE
traqsr
,
ONLY
:
ln_traqsr
USE
lib_mpp
IMPLICIT
NONE
PRIVATE
PUBLIC
agrif_interp_ice
! called by agrif_user.F90
PUBLIC
agrif_istate_ice
! called by icerst.F90
PUBLIC
agrif_interp_ice
! called by agrif_user.F90
PUBLIC
agrif_istate_ice
! called by icerst.F90
PUBLIC
agrif_istate_icevol
! called by restart.F90
!!----------------------------------------------------------------------
!! NEMO/NST 4.0 , NEMO Consortium (2018)
...
...
@@ -87,6 +91,60 @@ CONTAINS
!
END
SUBROUTINE
agrif_istate_ice
SUBROUTINE
agrif_istate_icevol
(
Kbb
,
Kmm
,
Kaa
)
!!-----------------------------------------------------------------------
!! *** ROUTINE agrif_istate_icevol ***
!!
!! ** Method : Set initial ssh over child grids from the ice volume
!! computed over the parent grid.
!! This routine is call only if nn_ice/=2 (no ice), over
!! the child grid, hence it needs to know nn_ice
!!
!!-----------------------------------------------------------------------
INTEGER
,
INTENT
(
in
)
::
Kbb
,
Kmm
,
Kaa
! ocean time level indices
!
INTEGER
::
ios
!!
NAMELIST
/
namsbc
/
nn_fsbc
,
&
&
ln_usr
,
ln_flx
,
ln_blk
,
ln_abl
,
&
&
ln_cpl
,
ln_mixcpl
,
nn_components
,
&
&
nn_ice
,
ln_ice_embd
,
&
&
ln_traqsr
,
ln_dm2dc
,
&
&
ln_rnf
,
nn_fwb
,
ln_ssr
,
ln_apr_dyn
,
&
&
ln_wave
,
nn_lsm
!!----------------------------------------------------------------------
!
IF
(
Agrif_Root
()
)
RETURN
!
! !** read Surface Module namelist
! (we only need nn_ice actually which is unknown at the
! time this subroutine is called)
READ
(
numnam_ref
,
namsbc
,
IOSTAT
=
ios
,
ERR
=
901
)
901
IF
(
ios
/
=
0
)
CALL
ctl_nam
(
ios
,
'namsbc in reference namelist'
)
READ
(
numnam_cfg
,
namsbc
,
IOSTAT
=
ios
,
ERR
=
902
)
902
IF
(
ios
>
0
)
CALL
ctl_nam
(
ios
,
'namsbc in configuration namelist'
)
!
IF
(
(
nn_ice
/
=
2
)
.AND.
((
Agrif_Parent
(
nn_ice
)
==
2
)
.AND.
&
&
(
.NOT.
(
Agrif_Parent
(
ln_rstart
)
&
&
.OR.
(
Agrif_Parent
(
nn_iceini_file
)
==
2
)))
.AND.
&
&
(
.NOT.
Agrif_Parent
(
ln_ice_embd
))
&
&
))
THEN
IF
(
lwp
)
WRITE
(
numout
,
*
)
' '
IF
(
lwp
)
WRITE
(
numout
,
*
)
'Agrif_istate_icevol : Add an ssh increment coming from the parent grid sea-ice volume'
IF
(
lwp
)
WRITE
(
numout
,
*
)
'~~~~~~~~~~~~~~~~~~~~~'
IF
(
lwp
)
WRITE
(
numout
,
*
)
' '
WHERE
(
ssmask
(:,:)
==
1._wp
)
ssh
(:,:,
Kmm
)
=
ssh
(:,:,
Kmm
)
-
Agrif_Parent
(
rsshadj
)
ssh
(:,:,
Kbb
)
=
ssh
(:,:,
Kbb
)
-
Agrif_Parent
(
rsshadj
)
ENDWHERE
ENDIF
!
END
SUBROUTINE
agrif_istate_icevol
SUBROUTINE
agrif_interp_ice
(
cd_type
,
kiter
,
kitermax
)
!!-----------------------------------------------------------------------
!! *** ROUTINE agrif_interp_ice ***
...
...
This diff is collapsed.
Click to expand it.
src/OCE/DOM/domain.F90
+
8
−
0
View file @
f5d53a97
...
...
@@ -36,6 +36,9 @@ MODULE domain
#endif
#if defined key_agrif
USE
agrif_oce_interp
,
ONLY
:
Agrif_istate_ssh
! ssh interpolated from parent
#if defined key_si3
USE
agrif_ice_interp
,
ONLY
:
agrif_istate_icevol
! ssh increment from ice
#endif
#endif
USE
sbc_oce
! surface boundary condition: ocean
USE
trc_oce
! shared ocean & passive tracers variab
...
...
@@ -177,6 +180,11 @@ CONTAINS
ELSEIF
(
.NOT.
Agrif_root
()
.AND.
&
&
ln_init_chfrpar
)
THEN
!* Interpolate initial ssh from parent
CALL
Agrif_istate_ssh
(
Kbb
,
Kmm
,
Kaa
)
#if defined key_si3
! Possibly add ssh increment from parent grid
! only if there is no ice model in the child grid
CALL
Agrif_istate_icevol
(
Kbb
,
Kmm
,
Kaa
)
#endif
#endif
ELSE
!* Read in restart file or set by user
CALL
rst_read_ssh
(
Kbb
,
Kmm
,
Kaa
)
...
...
This diff is collapsed.
Click to expand it.
src/OCE/IOM/restart.F90
+
5
−
12
View file @
f5d53a97
...
...
@@ -32,8 +32,7 @@ MODULE restart
USE
diu_bulk
! ???
#if defined key_agrif
#if defined key_si3
USE
iceistate
,
ONLY
:
rsshadj
,
nn_iceini_file
USE
sbc_oce
,
ONLY
:
ln_ice_embd
USE
agrif_ice_interp
#endif
USE
agrif_oce_interp
#endif
...
...
@@ -426,18 +425,12 @@ CONTAINS
#if defined key_agrif
! Set ghosts points from parent
IF
(
.NOT.
Agrif_Root
())
THEN
! Set ghosts points from parent
CALL
Agrif_istate_ssh
(
Kbb
,
Kmm
,
Kaa
,
.true.
)
#if defined key_si3
IF
(
(
nn_ice
/
=
2
)
.AND.
((
Agrif_Parent
(
nn_ice
)
==
2
)
.AND.
&
&
(
.NOT.
(
Agrif_Parent
(
ln_rstart
)
&
&
.OR.
(
Agrif_Parent
(
nn_iceini_file
)
==
2
)))
.AND.
&
&
(
.NOT.
Agrif_Parent
(
ln_ice_embd
))
&
&
))
THEN
WHERE
(
ssmask
(:,:)
==
1._wp
)
ssh
(:,:,
Kmm
)
=
ssh
(:,:,
Kmm
)
-
Agrif_Parent
(
rsshadj
)
ssh
(:,:,
Kbb
)
=
ssh
(:,:,
Kbb
)
-
Agrif_Parent
(
rsshadj
)
ENDWHERE
ENDIF
! Possibly add ssh increment from parent grid
! only if there is no ice model in the child grid
CALL
Agrif_istate_icevol
(
Kbb
,
Kmm
,
Kaa
)
#endif
ENDIF
#endif
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment