ROMS
Loading...
Searching...
No Matches
ad_initial.F File Reference
#include "cppdefs.h"
Include dependency graph for ad_initial.F:

Go to the source code of this file.

Functions/Subroutines

subroutine ad_initial (ng)
 

Function/Subroutine Documentation

◆ ad_initial()

subroutine ad_initial ( integer, intent(in) ng)

Definition at line 3 of file ad_initial.F.

4!
5!git $Id$
6!================================================== Hernan G. Arango ===
7! Copyright (c) 2002-2025 The ROMS Group !
8! Licensed under a MIT/X style license !
9! See License_ROMS.md !
10!=======================================================================
11! !
12! This routine initializes all adjoint model variables. !
13! !
14!=======================================================================
15!
16 USE mod_param
17 USE mod_parallel
18# ifdef BBL_MODEL_NOT_YET
19 USE mod_bbl
20# endif
21# ifdef ADJUST_BOUNDARY
22 USE mod_boundary
23# endif
24# ifdef SOLVE3D
25 USE mod_coupling
26# endif
27 USE mod_forces
28# ifdef FOUR_DVAR
29 USE mod_fourdvar
30# endif
31 USE mod_grid
32 USE mod_iounits
33# ifdef SOLVE3D
34 USE mod_mixing
35# endif
36 USE mod_ncparam
37 USE mod_ocean
38 USE mod_scalars
39 USE mod_stepping
40!
42# if defined AD_SENSITIVITY || defined I4DVAR_ANA_SENSITIVITY || \
43 defined opt_observations || defined sensitivity_4dvar || \
44 defined so_semi
46# endif
47# if defined STEP2D_FB_AB3_AM4 || defined STEP2D_FB_LF_AM3
48!! USE ad_load_sol_mod, ONLY : ad_load_sol
49# endif
50 USE close_io_mod, ONLY : close_inp
51 USE dateclock_mod, ONLY : time_string
52# ifdef DISTRIBUTE
53 USE distribute_mod, ONLY : mp_bcasti
54# endif
55# ifdef WET_DRY
56 USE get_wetdry_mod, ONLY : get_wetdry
57# endif
58 USE get_state_mod, ONLY : get_state
59# if defined SOLVE3D && defined NONLINEAR
61# endif
63# if defined WAV_COUPLING_NOT_YET && defined MCT_LIB
64 USE mct_coupler_mod, ONLY : ocn2wav_coupling
65# endif
66# ifdef SOLVE3D
67 USE set_depth_mod, ONLY : set_depth
68 USE omega_mod, ONLY : omega
69 USE rho_eos_mod, ONLY : rho_eos
71# endif
72# ifdef OBSERVATIONS
74# endif
75# ifdef MASKING
76 USE set_masks_mod, ONLY : set_masks
77# endif
78 USE stiffness_mod, ONLY : stiffness
79 USE strings_mod, ONLY : founderror
80# ifdef WET_DRY
81 USE wetdry_mod, ONLY : wetdry
82# endif
83# if defined PROPAGATOR || \
84 (defined masking && (defined read_water || defined write_water))
85 USE wpoints_mod, ONLY : wpoints
86# endif
87!
88 implicit none
89!
90! Imported variable declarations.
91!
92 integer, intent(in) :: ng
93!
94! Local variable declarations.
95!
96 logical :: update = .false.
97!
98 integer :: Fcount, IniRec, Tindex
99 integer :: thread, tile
100!
101 real(dp) :: my_dstart
102!
103 character (len=*), parameter :: MyFile = &
104 & __FILE__
105!
106!=======================================================================
107! Initialize model variables.
108!=======================================================================
109!
110 IF (master) THEN
111# if defined PERTURBATION
112 WRITE (stdout,10) nrun
113 10 FORMAT (/,' <<<< Ensemble/Perturbation Run: ',i5.5,' >>>>',/)
114# elif defined I4DVAR || defined SENSITIVITY_4DVAR || \
115 defined rbl4dvar || defined r4dvar
116 WRITE (stdout,10) outer, inner
117 10 FORMAT (/,' <<<< 4D Variational Data Assimilation, ', &
118 & 'Outer = ',i3.3, ', Inner = ',i3.3,' >>>>',/)
119# endif
120 WRITE (stdout,20) 'AD_INITIAL: Configuring and ', &
121 & 'initializing adjoint model ...'
122 20 FORMAT (/,1x,a,a,/)
123 END IF
124!
125!-----------------------------------------------------------------------
126! Initialize time stepping indices and counters.
127!-----------------------------------------------------------------------
128!
129 iif(ng)=1
130 indx1(ng)=1
131 next_kstp(ng)=1
132# if defined STEP2D_FB_AB3_AM4 || defined STEP2D_FB_LF_AM3
133 kstp(ng)=1
134 knew(ng)=1
135# else
136 kstp(ng)=1
137 krhs(ng)=3
138 knew(ng)=2
139# endif
140 predictor_2d_step(ng)=.false.
141!
142 iic(ng)=0
143# ifdef SOLVE3D
144 nstp(ng)=1
145 nnew(ng)=2
146 nrhs(ng)=nstp(ng)
147# endif
148# ifdef FLOATS_NOT_YET
149 nf(ng)=0
150 nfp1(ng)=1
151 nfm1(ng)=4
152 nfm2(ng)=3
153 nfm3(ng)=2
154# endif
155!
156 synchro_flag(ng)=.true.
157 first_time(ng)=0
158 ad_ubar_xs=0.0_r8
159
160# ifdef GENERIC_DSTART
161!
162! Rarely, the adjoint model is initialized from a NetCDF file, so we do
163! not know its actual initialization time. Usually, it is computed from
164! DSTART, implying that its value is correct in the ROMS input script.
165! Therefore, the user needs to check and update its value to every time
166! that ROMS is executed. Alternatively, if available, we can use the
167! initialization time from the nonlinear model, INItime. This variable
168! is assigned when computing or processing the basic state trajectory
169! needed to linearize the adjoint model.
170!
171 IF (initime(ng).lt.0.0_dp) THEN
172 my_dstart=dstart ! ROMS input script
173 ELSE
174 my_dstart=initime(ng)/86400.0_dp ! NLM IC time is known
175 END IF
176 tdays(ng)=my_dstart+dt(ng)*real(ntimes(ng),r8)*sec2day
177 time(ng)=tdays(ng)*day2sec
178 ntstart(ng)=int((time(ng)-dstart*day2sec)/dt(ng))+1
179 ntend(ng)=ntstart(ng)-ntimes(ng)
180 ntfirst(ng)=ntend(ng)
181#else
182 tdays(ng)=dstart+dt(ng)*real(ntimes(ng)-ntfirst(ng)+1,r8)*sec2day
183 time(ng)=tdays(ng)*day2sec
184 ntstart(ng)=ntimes(ng)+1
185 ntend(ng)=ntfirst(ng)
186 ntfirst(ng)=ntend(ng)
187#endif
188 step_counter(ng)=0
189!
190 inirec=nrrec(ng)
191 tindex=1
192!
193! Initialize global diagnostics variables.
194!
195 avgke=0.0_dp
196 avgpe=0.0_dp
197 avgkp=0.0_dp
198 volume=0.0_dp
199
200# ifdef PROFILE
201!
202!-----------------------------------------------------------------------
203! Start time wall clocks.
204!-----------------------------------------------------------------------
205!
206 DO thread=thread_range
207 CALL wclock_on (ng, iadm, 2, __line__, myfile)
208 END DO
209# endif
210
211# if defined FOUR_DVAR && \
212 !(defined I4DVAR_ANA_SENSITIVITY || defined OPT_OBSERVATIONS)
213!
214!-----------------------------------------------------------------------
215! If variational data assimilation, reset several IO switches and
216! variables.
217!-----------------------------------------------------------------------
218!
219! Set switch to create adjoint NetCDF file or append to an existing
220! adjoint NetCDF file.
221!
222 IF (nrun.eq.erstr) THEN
223 ldefadj(ng)=.true.
224 END IF
225!
226! Activate switch to write adjoint NetCDF file.
227!
228 lwrtadj(ng)=.true.
229
230# ifdef ADJUST_BOUNDARY
231!
232! Initialize open boundary counter for storage arrays.
233!
234 obccount(ng)=0
235# endif
236# if defined ADJUST_STFLUX || defined ADJUST_WSTRESS
237!
238! Initialize surface forcing counter for storage arrays.
239!
240 sfcount(ng)=nfrec(ng)+1
241# endif
242# endif
243!
244!-----------------------------------------------------------------------
245! Set application grid, metrics, and associated variables and
246! parameters.
247!-----------------------------------------------------------------------
248!
249 IF (setgridconfig(ng)) THEN
250 CALL set_grid (ng, itlm)
251 setgridconfig(ng)=.false.
252 END IF
253!
254!-----------------------------------------------------------------------
255! Initialize horizontal mixing coefficients. If applicable, scale
256! mixing coefficients according to the grid size (smallest area).
257# ifndef ANA_SPONGE
258! Also increase their values in sponge areas using the "visc_factor"
259! and/or "diff_factor" read from input Grid NetCDF file.
260# endif
261!-----------------------------------------------------------------------
262!
263 DO tile=first_tile(ng),last_tile(ng),+1
264 CALL ini_hmixcoef (ng, tile, iadm)
265 END DO
266
267# ifdef ANA_SPONGE
268!
269!-----------------------------------------------------------------------
270! Increase horizontal mixing coefficients in sponge areas using
271! analytical functions.
272!-----------------------------------------------------------------------
273!
274 IF (lsponge(ng)) THEN
275 DO tile=first_tile(ng),last_tile(ng),+1
276 CALL ana_sponge (ng, tile, iadm)
277 END DO
278 END IF
279# endif
280!
281!=======================================================================
282! Initialize model state variables and forcing. This part is
283! executed for each ensemble/perturbation/iteration pass.
284!=======================================================================
285
286# if defined AD_SENSITIVITY || defined I4DVAR_ANA_SENSITIVITY || \
287 defined opt_observations || defined so_semi
288!
289!-----------------------------------------------------------------------
290! Clear all adjoint and nonlinear variables.
291!-----------------------------------------------------------------------
292!
293 DO tile=first_tile(ng),last_tile(ng),+1
294 CALL initialize_ocean (ng, tile, inlm)
295 CALL initialize_ocean (ng, tile, iadm)
296# if defined SOLVE3D
297 CALL initialize_coupling (ng, tile, iadm)
298 CALL initialize_mixing (ng, tile, iadm)
299# endif
300 CALL initialize_forces (ng, tile, iadm)
301 CALL initialize_grid (ng, tile, iadm)
302# ifdef ADJUST_BOUNDARY
303 CALL initialize_boundary (ng, tile, iadm)
304# endif
305 END DO
306
307# elif defined FOUR_DVAR && !defined I4DVAR_ANA_SENSITIVITY
308!
309!-----------------------------------------------------------------------
310! Clear all adjoint variables. In variational data assimilation the
311! initial condition are always zero and the forcing is only via the
312! (model-observations) misfit terms.
313!-----------------------------------------------------------------------
314!
315 DO tile=first_tile(ng),last_tile(ng),+1
316 CALL initialize_ocean (ng, tile, inlm)
317 CALL initialize_forces (ng, tile, inlm)
318 CALL initialize_ocean (ng, tile, iadm)
319# if defined SOLVE3D
320 CALL initialize_coupling (ng, tile, iadm)
321 CALL initialize_mixing (ng, tile, iadm)
322# endif
323 CALL initialize_forces (ng, tile, iadm)
324 CALL initialize_grid (ng, tile, iadm)
325# ifdef ADJUST_BOUNDARY
326 CALL initialize_boundary (ng, tile, iadm)
327# endif
328 END DO
329
330# else
331
332# if defined SOLVE3D && !defined INI_FILE
333!
334!-----------------------------------------------------------------------
335! If analytical initial conditions, compute initial time-evolving
336! depths with zero free-surface.
337!-----------------------------------------------------------------------
338!
339 DO tile=first_tile(ng),last_tile(ng),+1
340 CALL set_depth (ng, tile, iadm)
341 END DO
342# endif
343!
344!-----------------------------------------------------------------------
345! Set adjoint primitive variables initial conditions.
346!-----------------------------------------------------------------------
347!
348# ifdef ANA_INITIAL
349!
350! Analytical initial conditions for momentum and active tracers.
351!
352 IF (nrrec(ng).eq.0) THEN
353 DO tile=first_tile(ng),last_tile(ng),+1
354 CALL ana_initial (ng, tile, iadm)
355 END DO
356 END IF
357# endif
358
359# if defined ANA_PASSIVE && defined SOLVE3D
360!
361! Analytical initial conditions for inert passive tracers
362!
363 IF (nrrec(ng).eq.0) THEN
364 DO tile=first_tile(ng),last_tile(ng),+1
365 CALL ana_passive (ng, tile, iadm)
366 END DO
367 END IF
368# endif
369
370# if defined ANA_BIOLOGY && defined SOLVE3D
371!
372! Analytical initial conditions for biology tracers.
373!
374 IF (nrrec(ng).eq.0) THEN
375 DO tile=first_tile(ng),last_tile(ng),+1
376 CALL ana_biology (ng, tile, iadm)
377 END DO
378 END IF
379# endif
380
381# if defined ANA_SEDIMENT_NOT_YET && defined SOLVE3D
382!
383! Analytical initial conditions for sediment tracers.
384!
385 IF (nrrec(ng).eq.0) THEN
386 DO tile=first_tile(ng),last_tile(ng),+1
387 CALL ana_sediment (ng, tile, iadm)
388 END DO
389 END IF
390# endif
391!
392! Read in initial conditions for initial or restart NetCDF file.
393!
394# ifdef INI_FILE
395 CALL get_state (ng, iadm, 1, iad(ng), inirec, tindex)
396 time(ng)=io_time ! needed for shared-memory
397# ifdef DISTRIBUTE
398 CALL mp_bcasti (ng, iadm, exit_flag)
399# endif
400 IF (founderror(exit_flag, noerror, __line__, myfile)) RETURN
401# else
402 IF (nrrec(ng).ne.0) THEN
403 CALL get_state (ng, iadm, 1, iad(ng), inirec, tindex)
404 time(ng)=io_time ! needed for shared-memory
405# ifdef DISTRIBUTE
406 CALL mp_bcasti (ng, iadm, exit_flag)
407# endif
408 IF (founderror(exit_flag, noerror, __line__, myfile)) RETURN
409 END IF
410# endif
411
412# ifdef INI_FILE
413# if defined STEP2D_FB_AB3_AM4 || defined STEP2D_FB_LF_AM3
414!!
415!! Load initial fields to adjoint solution arrays for I/O purposes.
416!!
417!! DO tile=first_tile(ng),last_tile(ng),+1
418!! CALL ad_load_sol (ng, tile, iADM, Tindex)
419!! END DO
420# endif
421# endif
422# endif
423
424# ifdef WET_DRY
425!
426!-----------------------------------------------------------------------
427! Process initial wet/dry masks.
428!-----------------------------------------------------------------------
429!
430! If restart, read in wet/dry masks.
431!
432 IF (nrrec(ng).ne.0) THEN
433# ifdef DISTRIBUTE
434 CALL get_wetdry (ng, myrank, iadm, inirec(ng))
435 CALL mp_bcasti (ng, iadm, exit_flag)
436# else
437 CALL get_wetdry (ng, -1, iadm, inirec(ng))
438# endif
439 IF (founderror(exit_flag, noerror, __line__, myfile)) RETURN
440 ELSE
441 DO tile=first_tile(ng),last_tile(ng),+1
442 CALL wetdry (ng, tile, tindex(ng), .true.)
443 END DO
444 END IF
445# endif
446
447# ifdef OBSERVATIONS
448!
449!-----------------------------------------------------------------------
450! Initialize various variables needed for processing observations
451! backwards in time. Need to be done after processing initial
452! conditions since the correct initial time is needed to determine
453! the first "ObsTime" to process.
454!-----------------------------------------------------------------------
455!
456# ifdef RBL4DVAR_FCT_SENSITIVITY
457 IF (.not.lsen4dvar(ng).and.lsenfct(ng)) THEN
458# ifdef OBS_SPACE
459 IF (lobspace(ng)) THEN
460# endif
461# endif
462 CALL obs_initial (ng, iadm, .true.)
463# ifdef OBS_SPACE
464 END IF
465# endif
466# ifdef RBL4DVAR_FCT_SENSITIVITY
467 END IF
468# endif
469 IF (founderror(exit_flag, noerror, __line__, myfile)) RETURN
470# endif
471
472# if defined ANA_PERTURB && \
473 (defined sanity_check || defined r_symmetry)
474!
475!-----------------------------------------------------------------------
476! Perturb adjoint initial conditions with analitical expressions.
477!-----------------------------------------------------------------------
478!
479 DO tile=first_tile(ng),last_tile(ng),+1
480 CALL ana_perturb (ng, tile, iadm)
481 END DO
482# endif
483
484# ifdef SOLVE3D
485!!
486!!----------------------------------------------------------------------
487!! Compute initial time-evolving depths.
488!!----------------------------------------------------------------------
489!!
490!! DO tile=first_tile(ng),last_tile(ng),+1
491!! CALL ad_set_depth (ng, tile, iADM)
492!! END DO
493!!
494!!----------------------------------------------------------------------
495!! Compute initial horizontal mass fluxes, Hz*u/n and Hz*v/m.
496!!----------------------------------------------------------------------
497!!
498!! DO tile=first_tile(ng),last_tile(ng),+1
499!! CALL ad_set_massflux (ng, tile, iADM)
500!! END DO
501!!
502!!----------------------------------------------------------------------
503!! Compute initial S-coordinates vertical velocity. Compute initial
504!! density anomaly from potential temperature and salinity via equation
505!! of state for seawater. Also compute other equation of state related
506!! quatities.
507!!----------------------------------------------------------------------
508!!
509!! DO tile=first_tile(ng),last_tile(ng),+1
510!! CALL ad_omega (ng, tile, iADM)
511!! CALL ad_rho_eos (ng, tile, iADM)
512!! END DO
513# endif
514
515#ifdef ANA_PSOURCE
516!
517!-----------------------------------------------------------------------
518! Set point Sources/Sinks position, direction, special flag, and mass
519! transport nondimensional shape profile with analytcal expressions.
520! Point sources are at U- and V-points. We need to get their positions
521! to process internal Land/Sea masking arrays during initialization.
522!-----------------------------------------------------------------------
523!
524 IF (luvsrc(ng).or.lwsrc(ng).or.any(ltracersrc(:,ng))) THEN
525 DO tile=first_tile(ng),last_tile(ng),+1
526 CALL ana_psource (ng, tile, iadm)
527 END DO
528 END IF
529#endif
530!
531!-----------------------------------------------------------------------
532! If applicable, close all input boundary, climatology, and forcing
533! NetCDF files and set associated parameters to the closed state. This
534! step is essential in iterative algorithms that run the full TLM
535! repetitively. Then, Initialize several parameters in their file
536! structure, so the appropriate input single or multi-file is selected
537! during initialization/restart.
538!-----------------------------------------------------------------------
539!
540 CALL close_inp (ng, iadm)
541 CALL check_multifile (ng, iadm)
542# ifdef DISTRIBUTE
543 CALL mp_bcasti (ng, iadm, exit_flag)
544# endif
545 IF (founderror(exit_flag, noerror, __line__, myfile)) RETURN
546!
547!-----------------------------------------------------------------------
548! Read in initial forcing, climatology and assimilation data from
549! input NetCDF files. It loads the first relevant data record for
550! the time-interpolation between snapshots.
551!-----------------------------------------------------------------------
552!
553 CALL ad_get_idata (ng)
554 CALL ad_get_data (ng)
555# ifdef DISTRIBUTE
556 CALL mp_bcasti (ng, iadm, exit_flag)
557# endif
558 IF (founderror(exit_flag, noerror, __line__, myfile)) RETURN
559
560# if defined SOLVE3D && defined ADM_DRIVER
561!
562!-----------------------------------------------------------------------
563! Compute nonlinear initial time-evolving depths.
564!-----------------------------------------------------------------------
565!
566 DO tile=first_tile(ng),last_tile(ng),+1
567# ifdef NONLINEAR
568 CALL set_zeta_timeavg (ng, tile, itlm)
569# endif
570 CALL set_depth (ng, tile, itlm)
571 END DO
572# endif
573
574# ifdef MASKING
575!
576!-----------------------------------------------------------------------
577! Set internal I/O mask arrays.
578!-----------------------------------------------------------------------
579!
580 DO tile=first_tile(ng),last_tile(ng),+1
581 CALL set_masks (ng, tile, iadm)
582 END DO
583# endif
584
585# if defined PROPAGATOR || \
586 (defined masking && (defined read_water || defined write_water) )
587!
588!-----------------------------------------------------------------------
589! Set variables associated with the processing water points and/or
590! size of packed state arrays.
591!-----------------------------------------------------------------------
592!
593 DO tile=first_tile(ng),last_tile(ng),+1
594 CALL wpoints (ng, tile, iadm)
595 END DO
596# endif
597
598# if defined AD_SENSITIVITY || defined I4DVAR_ANA_SENSITIVITY || \
599 defined opt_observations || defined sensitivity_4dvar || \
600 defined so_semi
601!
602!-----------------------------------------------------------------------
603! Initialize adjoint state with the functional whose sensitivity is
604! is required.
605!-----------------------------------------------------------------------
606!
607# ifdef SENSITIVITY_4DVAR
608 IF (lsen4dvar(ng)) THEN
609# endif
610# if !defined AD_IMPULSE
611 DO tile=first_tile(ng),last_tile(ng),+1
612 CALL adsen_initial (ng, tile)
613 END DO
614# endif
615# ifdef SENSITIVITY_4DVAR
616 END IF
617# endif
618# endif
619
620# if defined ANA_DRAG && defined UV_DRAG_GRID
621!
622!-----------------------------------------------------------------------
623! Set analytical spatially varying bottom friction parameter.
624!-----------------------------------------------------------------------
625!
626 IF (nrun.eq.erstr) THEN
627 DO tile=first_tile(ng),last_tile(ng),+1
628 CALL ana_drag (ng, tile, iadm)
629 END DO
630 END IF
631# endif
632!
633!-----------------------------------------------------------------------
634! Compute grid stiffness.
635!-----------------------------------------------------------------------
636!
637 IF (lstiffness) THEN
638 lstiffness=.false.
639 DO tile=first_tile(ng),last_tile(ng),+1
640 CALL stiffness (ng, tile, iadm)
641 END DO
642 END IF
643
644# if defined FLOATS_NOT_YET || defined STATIONS
645!
646!-----------------------------------------------------------------------
647! If applicable, convert initial locations to fractional grid
648! coordinates.
649!-----------------------------------------------------------------------
650!
651 CALL grid_coords (ng, iadm)
652# endif
653
654# if defined WAV_COUPLING_NOT_YET && defined MCT_LIB
655!
656!-----------------------------------------------------------------------
657! Read in initial forcing from coupled wave model.
658!-----------------------------------------------------------------------
659!
660 DO tile=first_tile(ng),last_tile(ng),+1
661 CALL ocn2wav_coupling (ng, tile)
662 END DO
663# endif
664!
665!-----------------------------------------------------------------------
666! Initialize time-stepping counter.
667!-----------------------------------------------------------------------
668!
669 iic(ng)=ntstart(ng)
670 CALL time_string (time(ng), time_code(ng))
671
672# ifdef PROFILE
673!
674!-----------------------------------------------------------------------
675! Turn off initiialization time wall clock.
676!-----------------------------------------------------------------------
677!
678 DO thread=thread_range
679 CALL wclock_off (ng, iadm, 2, __line__, myfile)
680 END DO
681# endif
682 RETURN
subroutine ad_get_data(ng)
Definition ad_get_data.F:4
subroutine ad_get_idata(ng)
Definition ad_get_idata.F:4
subroutine check_multifile(ng, model)
subroutine grid_coords(ng, model)
Definition grid_coords.F:4
subroutine, public adsen_initial(ng, tile)
subroutine ana_sediment(ng, tile, model)
Definition ana_sediment.h:3
subroutine ana_initial(ng, tile, model)
Definition ana_initial.h:3
subroutine ana_sponge(ng, tile, model)
Definition ana_hmixcoef.h:3
subroutine ana_drag(ng, tile, model)
Definition ana_drag.h:3
subroutine ana_psource(ng, tile, model)
Definition ana_psource.h:3
subroutine ana_perturb(ng, tile, model)
Definition ana_perturb.h:3
subroutine ana_biology(ng, tile, model)
Definition ana_biology.h:3
subroutine ana_passive(ng, tile, model)
Definition ana_passive.h:3
subroutine, public close_inp(ng, model)
Definition close_io.F:92
subroutine, public time_string(mytime, date_string)
Definition dateclock.F:1272
subroutine, public get_state(ng, model, msg, s, inirec, tindex)
Definition get_state.F:90
subroutine, public get_wetdry(ng, tile, model, inirec)
Definition get_wetdry.F:45
subroutine, public set_zeta_timeavg(ng, tile, model)
Definition ini_fields.F:986
subroutine, public ini_hmixcoef(ng, tile, model)
subroutine, public initialize_boundary(ng, tile, model)
subroutine, public initialize_coupling(ng, tile, model)
subroutine, public initialize_forces(ng, tile, model)
logical, dimension(:), allocatable lsenfct
logical, dimension(:), allocatable lsen4dvar
logical, dimension(:), allocatable lobspace
subroutine, public initialize_grid(ng, tile, model)
Definition mod_grid.F:1241
type(t_io), dimension(:), allocatable iad
integer stdout
subroutine, public initialize_mixing(ng, tile, model)
subroutine, public initialize_ocean(ng, tile, model)
Definition mod_ocean.F:1526
integer, dimension(:), allocatable first_tile
logical master
integer, dimension(:), allocatable last_tile
integer, parameter inlm
Definition mod_param.F:662
integer, parameter iadm
Definition mod_param.F:665
integer, parameter itlm
Definition mod_param.F:663
logical, dimension(:), allocatable luvsrc
real(dp), parameter day2sec
integer, dimension(:), allocatable obccount
integer, dimension(:), allocatable nrrec
logical, dimension(:,:), allocatable ltracersrc
integer, dimension(:), allocatable ntimes
integer, dimension(:), allocatable iic
real(dp), dimension(:), allocatable dt
logical, dimension(:), allocatable lsponge
logical, dimension(:), allocatable setgridconfig
logical lstiffness
real(dp) avgke
real(dp) avgpe
integer, dimension(:), allocatable next_kstp
logical, dimension(:), allocatable synchro_flag
logical, dimension(:), allocatable predictor_2d_step
integer, dimension(:), allocatable nfrec
real(dp), dimension(:), allocatable tdays
logical, dimension(:), allocatable ldefadj
real(dp) dstart
logical, dimension(:), allocatable lwrtadj
logical, dimension(:), allocatable lwsrc
real(dp), parameter sec2day
integer, dimension(:), allocatable ntend
real(dp) ad_ubar_xs
real(dp) volume
integer, dimension(:), allocatable first_time
character(len=22), dimension(:), allocatable time_code
integer exit_flag
integer, dimension(:), allocatable indx1
integer, dimension(:), allocatable sfcount
integer erstr
real(dp) avgkp
integer, dimension(:), allocatable ntfirst
real(dp), dimension(:), allocatable time
integer, dimension(:), allocatable ntstart
integer nrun
integer, dimension(:), allocatable step_counter
integer inner
integer, dimension(:), allocatable iif
real(dp) io_time
real(dp), dimension(:), allocatable initime
integer noerror
integer outer
integer, dimension(:), allocatable nfm2
integer, dimension(:), allocatable kstp
integer, dimension(:), allocatable knew
integer, dimension(:), allocatable nfm1
integer, dimension(:), allocatable nrhs
integer, dimension(:), allocatable nf
integer, dimension(:), allocatable nfm3
integer, dimension(:), allocatable nnew
integer, dimension(:), allocatable nfp1
integer, dimension(:), allocatable krhs
integer, dimension(:), allocatable nstp
subroutine, public obs_initial(ng, model, backward)
Definition obs_initial.F:41
subroutine, public omega(ng, tile, model)
Definition omega.F:42
subroutine, public rho_eos(ng, tile, model)
Definition rho_eos.F:48
subroutine, public set_depth(ng, tile, model)
Definition set_depth.F:34
subroutine, public set_masks(ng, tile, model)
Definition set_masks.F:44
subroutine, public set_massflux(ng, tile, model)
subroutine, public stiffness(ng, tile, model)
Definition stiffness.F:32
logical function, public founderror(flag, noerr, line, routine)
Definition strings.F:52
subroutine wetdry(ng, tile, tindex, linitialize)
Definition wetdry.F:22
subroutine set_grid(ng, model)
Definition set_grid.F:3
recursive subroutine wclock_off(ng, model, region, line, routine)
Definition timers.F:148
recursive subroutine wclock_on(ng, model, region, line, routine)
Definition timers.F:3
subroutine wpoints(ng, tile, model)
Definition wpoints.F:40

References ad_get_data(), ad_get_idata(), mod_scalars::ad_ubar_xs, adsen_initial_mod::adsen_initial(), analytical_mod::ana_biology(), analytical_mod::ana_drag(), analytical_mod::ana_initial(), analytical_mod::ana_passive(), analytical_mod::ana_perturb(), analytical_mod::ana_psource(), analytical_mod::ana_sediment(), analytical_mod::ana_sponge(), mod_scalars::avgke, mod_scalars::avgkp, mod_scalars::avgpe, check_multifile(), close_io_mod::close_inp(), mod_scalars::day2sec, mod_scalars::dstart, mod_scalars::dt, mod_scalars::erstr, mod_scalars::exit_flag, mod_parallel::first_tile, mod_scalars::first_time, strings_mod::founderror(), get_state_mod::get_state(), get_wetdry_mod::get_wetdry(), grid_coords(), mod_iounits::iad, mod_param::iadm, mod_scalars::iic, mod_scalars::iif, mod_scalars::indx1, ini_hmixcoef_mod::ini_hmixcoef(), mod_boundary::initialize_boundary(), mod_coupling::initialize_coupling(), mod_forces::initialize_forces(), mod_grid::initialize_grid(), mod_mixing::initialize_mixing(), mod_ocean::initialize_ocean(), mod_scalars::initime, mod_param::inlm, mod_scalars::inner, mod_scalars::io_time, mod_param::itlm, mod_stepping::knew, mod_stepping::krhs, mod_stepping::kstp, mod_parallel::last_tile, mod_scalars::ldefadj, mod_fourdvar::lobspace, mod_fourdvar::lsen4dvar, mod_fourdvar::lsenfct, mod_scalars::lsponge, mod_scalars::lstiffness, mod_scalars::ltracersrc, mod_scalars::luvsrc, mod_scalars::lwrtadj, mod_scalars::lwsrc, mod_parallel::master, mod_parallel::myrank, mod_scalars::next_kstp, mod_stepping::nf, mod_stepping::nfm1, mod_stepping::nfm2, mod_stepping::nfm3, mod_stepping::nfp1, mod_scalars::nfrec, mod_stepping::nnew, mod_scalars::noerror, mod_stepping::nrhs, mod_scalars::nrrec, mod_scalars::nrun, mod_stepping::nstp, mod_scalars::ntend, mod_scalars::ntfirst, mod_scalars::ntimes, mod_scalars::ntstart, mod_scalars::obccount, obs_initial_mod::obs_initial(), omega_mod::omega(), mod_scalars::outer, mod_scalars::predictor_2d_step, rho_eos_mod::rho_eos(), mod_scalars::sec2day, set_depth_mod::set_depth(), set_grid(), set_masks_mod::set_masks(), set_massflux_mod::set_massflux(), ini_fields_mod::set_zeta_timeavg(), mod_scalars::setgridconfig, mod_scalars::sfcount, mod_iounits::stdout, mod_scalars::step_counter, stiffness_mod::stiffness(), mod_scalars::synchro_flag, mod_scalars::tdays, mod_scalars::time, mod_scalars::time_code, dateclock_mod::time_string(), mod_scalars::volume, wclock_off(), wclock_on(), wetdry_mod::wetdry(), and wpoints().

Referenced by i4dvar_mod::increment(), r4dvar_mod::increment(), rbl4dvar_mod::increment(), propagator_mod::propagator_so_semi(), roms_kernel_mod::roms_initialize(), and roms_kernel_mod::roms_run().

Here is the call graph for this function:
Here is the caller graph for this function: