ROMS
Loading...
Searching...
No Matches
post_initial.F
Go to the documentation of this file.
1#include "cppdefs.h"
3#ifdef NONLINEAR
4!
5!git $Id$
6!svn $Id$
7!================================================== Hernan G. Arango ===
8! Copyright (c) 2002-2025 The ROMS Group !
9! Licensed under a MIT/X style license !
10! See License_ROMS.md !
11!=======================================================================
12! !
13! On the first timestep, it computes the initial depths and level !
14! thicknesses from the initial free-surface field. Additionally, it !
15! initializes the nonlinear state variables for all time levels and !
16! applies lateral boundary conditions. !
17! !
18!=======================================================================
19!
20 USE mod_param
21 USE mod_parallel
22# ifdef NESTING
23 USE mod_scalars
24# endif
25!
27# ifdef SOLVE3D
28 USE set_depth_mod, ONLY : set_depth
29# endif
30!
31 implicit none
32!
33 PUBLIC :: post_initial
34 PRIVATE
35!
36 CONTAINS
37!
38!***********************************************************************
39 SUBROUTINE post_initial (ng, model)
40!***********************************************************************
41!
42! Imported variable declarations.
43!
44 integer, intent(in) :: ng, model
45!
46! Local variable declarations.
47!
48 integer :: tile
49!
50!-----------------------------------------------------------------------
51! Initialize free-surface and compute initial level thicknesses and
52! depths.
53!-----------------------------------------------------------------------
54!
55 DO tile=first_tile(ng),last_tile(ng),+1
56 CALL ini_zeta (ng, tile, model)
57 CALL set_depth (ng, tile, model)
58 END DO
59!$OMP BARRIER
60!
61!-----------------------------------------------------------------------
62! Initialize other state variables.
63!-----------------------------------------------------------------------
64!
65 DO tile=last_tile(ng),first_tile(ng),-1
66 CALL ini_fields (ng, tile, model)
67 END DO
68!$OMP BARRIER
69
70# ifdef NESTING
71!
72!-----------------------------------------------------------------------
73! Extract donor grid initial data at contact points and store it in
74! REFINED structure so it can be used for the space-time interpolation.
75!-----------------------------------------------------------------------
76!
77 IF (refinedgrid(ng)) THEN
78 CALL nesting (ng, model, ngetd)
79 END IF
80# endif
81!
82 RETURN
83 END SUBROUTINE post_initial
84#endif
85 END MODULE post_initial_mod
subroutine, public ini_zeta(ng, tile, model)
Definition ini_fields.F:709
subroutine, public ini_fields(ng, tile, model)
Definition ini_fields.F:67
integer, dimension(:), allocatable first_tile
integer, dimension(:), allocatable last_tile
logical, dimension(:), allocatable refinedgrid
subroutine, public post_initial(ng, model)
subroutine, public set_depth(ng, tile, model)
Definition set_depth.F:34