4
5
6
7
8
9
10
11
12
13
14
15
18# ifdef BBL_MODEL_NOT_YET
20# endif
22# ifdef SOLVE3D
24# endif
25# ifdef FOUR_DVAR
27# endif
32# ifdef SOLVE3D
34# endif
38
42# ifdef DISTRIBUTE
44# endif
46# ifdef WET_DRY
48# endif
49# ifdef TLM_CHECK
51# endif
53# if defined WAV_COUPLING_NOT_YET && defined MCT_LIB
55# endif
56# if !(defined SEDIMENT_NOT_YET && defined SED_MORPH_NOT_YET)
58# endif
59# ifdef SOLVE3D
68# endif
69# ifdef OBSERVATIONS
71# endif
72# ifdef WEAK_CONSTRAINT
74# endif
75# ifdef MASKING
77# endif
80# ifdef WET_DRY
82# endif
83# if defined PROPAGATOR || \
84 (defined masking && (defined read_water || defined write_water))
86# endif
87
88 implicit none
89
90
91
92 integer, intent(in) :: ng
93
94
95
96 logical :: update = .false.
97
98 integer :: LBi, UBi, LBj, UBj
99 integer :: Fcount, IniRec, Tindex
100 integer :: thread, tile
101
102 real(dp) :: my_dstart
103
104 character (len=*), parameter :: MyFile = &
105 & __FILE__
106
107
108
109
110
112# if defined PERTURBATION
114 10 FORMAT (/,' <<<< Ensemble/Perturbation Run: ',i5.5,' >>>>',/)
115# elif defined R4DVAR || defined R4DVAR_ANA_SENSITIVITY || \
116 defined tl_r4dvar
118 10 FORMAT (/,' <<<< 4D Variational Data Assimilation, ', &
119 & 'Outer = ',i3.3, ', Inner = ',i3.3,' >>>>',/)
120# endif
121 WRITE (
stdout,20)
'RP_INITIAL: Configuring and ', &
122 & 'initializing representer model ...'
123 20 FORMAT (/,1x,a,a,/)
124 END IF
125
126
127
128
129
137
142# ifdef FLOATS_NOT_YET
148# endif
149
152
153# ifdef GENERIC_DSTART
154
155
156
157
158
159
160
161
162
163
164 IF (
initime(ng).lt.0.0_dp)
THEN
166 ELSE
167 my_dstart=
initime(ng)/86400.0_dp
168 END IF
170# else
172# endif
177
179
181 tindex=1
182
183 lbi=lbound(
grid(ng)%h,dim=1)
184 ubi=ubound(
grid(ng)%h,dim=1)
185 lbj=lbound(
grid(ng)%h,dim=2)
186 ubj=ubound(
grid(ng)%h,dim=2)
187
188
189
194
195# ifdef PROFILE
196
197
198
199
200
201 DO thread=thread_range
203 END DO
204# endif
205
206# ifdef WEAK_CONSTRAINT
207
208
209
210
211
212
213
214
215
217# ifdef ANA_INITIAL
219# endif
222 END IF
223 inirec=
irp(ng)%Rindex
224
225# ifdef ADJUST_BOUNDARY
226
227
228
230# endif
231# if defined ADJUST_STFLUX || defined ADJUST_WSTRESS
232
233
234
236# endif
237
238
239
240
241
244 fcount=
tlm(ng)%Fcount
245 tlm(ng)%Nrec(fcount)=0
246# endif
247
248
249
250
251
252
256 END IF
257
258
259
260
261# ifndef ANA_SPONGE
262
263
264# endif
265
266
269 END DO
270
271# ifdef ANA_SPONGE
272
273
274
275
276
277
281 END DO
282 END IF
283# endif
284
285
286
287
288
289
290# if defined PICARD_TEST || defined WEAK_CONSTRAINT
291
292
293
297# ifdef SOLVE3D
300# endif
301
305 END DO
306# endif
307
308# if defined SOLVE3D && !defined INI_FILE
309
310
311
312
313
314
317 END DO
318# endif
319
320# if !(defined SEDIMENT_NOT_YET && defined SED_MORPH_NOT_YET)
321
322
323
324
325
326
329 END DO
330# endif
331
332
333
334
335
336
337# ifdef ANA_INITIAL
338
339 IF (
nrrec(ng).eq.0)
THEN
342 END DO
343 END IF
344# endif
345
346# if defined ANA_PASSIVE && defined SOLVE3D
347
348
349
350 IF (
nrrec(ng).eq.0)
THEN
353 END DO
354 END IF
355# endif
356
357# if defined ANA_BIOLOGY && defined SOLVE3D
358
359
360
361 IF (
nrrec(ng).eq.0)
THEN
364 END DO
365 END IF
366# endif
367
368# if defined ANA_SEDIMENT_NOT_YET && defined SOLVE3D
369
370
371
372 IF (
nrrec(ng).eq.0)
THEN
375 END DO
376 END IF
377# endif
378
379
380
381# ifdef INI_FILE
384# else
385 IF (
nrrec(ng).ne.0)
THEN
388# ifdef DISTRIBUTE
390# endif
391 END IF
392# endif
394
395# ifdef WET_DRY
396
397
398
399
400
401
402
403 IF (
nrrec(ng).ne.0)
THEN
404# ifdef DISTRIBUTE
407# else
409# endif
411 ELSE
413 CALL wetdry (ng, tile, tindex(ng), .true.)
414 END DO
415 END IF
416# endif
417
418# ifdef OBSERVATIONS
419
420
421
422
423
424
425
426
427
430# endif
431
432# if defined ANA_PERTURB && defined SANITY_CHECK
433
434
435
436
437
438
441 END DO
442# endif
443
444# ifdef SOLVE3D
445
446
447
448
449
453 END DO
454
455
456
457
458
462 END DO
463
464
465
466
467
468
472 END DO
473# endif
474
475#ifdef ANA_PSOURCE
476
477
478
479
480
481
482
483
487 END DO
488 END IF
489#endif
490
491
492
493
494
495
496
497
498
499
502# ifdef DISTRIBUTE
504# endif
506
507
508
509
510
511
512
516
517# ifdef MASKING
518
519
520
521
522
525 END DO
526# endif
527
528# if defined PROPAGATOR || \
529 (defined masking && (defined read_water || defined write_water ))
530
531
532
533
534
535
538 END DO
539# endif
540
541# ifdef SOLVE3D
542
543
544
545
546
550 END DO
551# endif
552
553# if defined ANA_DRAG && defined UV_DRAG_GRID
554
555
556
557
558
562 END DO
563 END IF
564# endif
565
566
567
568
569
574 END DO
575 END IF
576
577# if defined FLOATS_NOT_YET || defined STATIONS
578
579
580
581
582
583
585# endif
586
587# if defined WAV_COUPLING_NOT_YET && defined MCT_LIB
588
589
590
591
592
594 CALL ocn2wav_coupling (ng, tile)
595 END DO
596# endif
597
598
599
600
601
602
603
604
607
608# ifdef PROFILE
609
610
611
612
613
614 DO thread=thread_range
616 END DO
617# endif
618
619 RETURN
subroutine check_multifile(ng, model)
subroutine grid_coords(ng, model)
subroutine ana_sediment(ng, tile, model)
subroutine ana_initial(ng, tile, model)
subroutine ana_sponge(ng, tile, model)
subroutine ana_drag(ng, tile, model)
subroutine ana_psource(ng, tile, model)
subroutine ana_perturb(ng, tile, model)
subroutine ana_biology(ng, tile, model)
subroutine ana_passive(ng, tile, model)
subroutine, public close_inp(ng, model)
subroutine, public time_string(mytime, date_string)
subroutine, public get_state(ng, model, msg, s, inirec, tindex)
subroutine, public get_wetdry(ng, tile, model, inirec)
subroutine, public tl_ini_perturb(ng, tile, linp, lout)
subroutine, public ini_hmixcoef(ng, tile, model)
subroutine, public initialize_coupling(ng, tile, model)
subroutine, public initialize_forces(ng, tile, model)
type(t_grid), dimension(:), allocatable grid
type(t_io), dimension(:), allocatable irp
type(t_io), dimension(:), allocatable tlm
subroutine, public initialize_mixing(ng, tile, model)
subroutine, public initialize_ocean(ng, tile, model)
integer, dimension(:), allocatable first_tile
integer, dimension(:), allocatable last_tile
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
integer, dimension(:), allocatable next_kstp
logical, dimension(:), allocatable synchro_flag
logical, dimension(:), allocatable predictor_2d_step
real(dp), dimension(:), allocatable tdays
logical, dimension(:), allocatable lwsrc
integer, dimension(:), allocatable ntend
logical, dimension(:), allocatable lcycletlm
logical, dimension(:), allocatable ldefirp
integer, dimension(:), allocatable first_time
character(len=22), dimension(:), allocatable time_code
integer, dimension(:), allocatable indx1
integer, dimension(:), allocatable sfcount
integer, dimension(:), allocatable ntfirst
real(dp), dimension(:), allocatable time
integer, dimension(:), allocatable ntstart
integer, dimension(:), allocatable iif
real(dp), dimension(:), allocatable initime
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)
subroutine, public omega(ng, tile, model)
subroutine, public rho_eos(ng, tile, model)
subroutine, public rp_def_ini(ng)
subroutine, public rp_omega(ng, tile, model)
subroutine, public rp_rho_eos(ng, tile, model)
subroutine, public rp_set_depth(ng, tile, model)
subroutine, public rp_bath(ng, tile)
subroutine, public rp_set_massflux(ng, tile, model)
subroutine, public set_depth(ng, tile, model)
subroutine, public set_masks(ng, tile, model)
subroutine, public set_massflux(ng, tile, model)
subroutine, public stiffness(ng, tile, model)
logical function, public founderror(flag, noerr, line, routine)
subroutine wetdry(ng, tile, tindex, linitialize)
subroutine rp_get_data(ng)
subroutine rp_get_idata(ng)
subroutine set_grid(ng, model)
recursive subroutine wclock_off(ng, model, region, line, routine)
recursive subroutine wclock_on(ng, model, region, line, routine)
subroutine wpoints(ng, tile, model)