1 | MODULE sedstp |
---|
2 | #if defined key_sed |
---|
3 | !!====================================================================== |
---|
4 | !! *** MODULE sedstp *** |
---|
5 | !! Sediment model : Sediment model time-stepping |
---|
6 | !!====================================================================== |
---|
7 | USE sed ! sediment global variables |
---|
8 | USE seddta ! data read |
---|
9 | USE sedchem ! chemical constant |
---|
10 | USE sedco3 ! carbonate in sediment pore water |
---|
11 | USE seddsr ! dissolution reaction |
---|
12 | USE sedbtb ! bioturbation |
---|
13 | USE sedadv ! vertical advection |
---|
14 | USE sedmbc ! mass balance calculation |
---|
15 | USE sedsfc ! sediment surface data |
---|
16 | USE sedrst ! restart |
---|
17 | USE sedwri ! outputs |
---|
18 | |
---|
19 | IMPLICIT NONE |
---|
20 | PRIVATE |
---|
21 | |
---|
22 | !! * Routine accessibility |
---|
23 | PUBLIC sed_stp ! called by step.F90 |
---|
24 | |
---|
25 | CONTAINS |
---|
26 | |
---|
27 | SUBROUTINE sed_stp ( kt ) |
---|
28 | !!--------------------------------------------------------------------- |
---|
29 | !! *** ROUTINE sed_stp *** |
---|
30 | !! |
---|
31 | !! ** Purpose : Sediment time stepping |
---|
32 | !! Simulation of pore water chemistry |
---|
33 | !! |
---|
34 | !! ** Action : |
---|
35 | !! |
---|
36 | !! |
---|
37 | !! History : |
---|
38 | !! ! 98-08 (E. Maier-Reimer, Christoph Heinze ) Original code |
---|
39 | !! ! 04-10 (N. Emprin, M. Gehlen ) coupled with PISCES |
---|
40 | !! ! 06-04 (C. Ethe) Re-organization |
---|
41 | !!---------------------------------------------------------------------- |
---|
42 | INTEGER, INTENT(in) :: kt ! number of iteration |
---|
43 | |
---|
44 | !!---------------------------------------------------------------------- |
---|
45 | |
---|
46 | IF( kt /= nitsed000 ) THEN |
---|
47 | CALL sed_dta( kt ) ! Load Data for bot. wat. Chem and fluxes |
---|
48 | CALL sed_chem( kt ) ! update of chemical constant to account for salinity, temperature changes |
---|
49 | ENDIF |
---|
50 | CALL sed_dsr( kt ) ! Dissolution reaction |
---|
51 | CALL sed_adv( kt ) ! advection |
---|
52 | CALL sed_btb( kt ) ! Bioturbation |
---|
53 | |
---|
54 | IF ( ( MOD( kt, nwrised ) == 0 ) .OR. ( MOD( kt, nstock ) == 0 ) .OR. ( kt == nitsedend ) ) & |
---|
55 | CALL sed_co3( kt ) ! pH actualization for saving |
---|
56 | CALL sed_mbc( kt ) ! cumulation for mass balance calculation |
---|
57 | #if ! defined key_sed_off |
---|
58 | CALL sed_sfc( kt ) ! Give back new bottom wat chem to tracer model |
---|
59 | #endif |
---|
60 | CALL sed_rst_write( kt ) ! restart file output |
---|
61 | CALL sed_wri( kt ) ! outputs |
---|
62 | |
---|
63 | IF( kt == nitsedend ) CLOSE( numsed ) |
---|
64 | |
---|
65 | END SUBROUTINE sed_stp |
---|
66 | |
---|
67 | #else |
---|
68 | !!====================================================================== |
---|
69 | !! MODULE sedstp : Dummy module |
---|
70 | !!====================================================================== |
---|
71 | CONTAINS |
---|
72 | SUBROUTINE sed_stp( kt ) ! Empty routine |
---|
73 | INTEGER, INTENT(in) :: kt |
---|
74 | WRITE(*,*) 'sed_stp: You should not have seen this print! error?', kt |
---|
75 | END SUBROUTINE sed_stp |
---|
76 | #endif |
---|
77 | |
---|
78 | END MODULE sedstp |
---|
79 | |
---|
80 | |
---|
81 | |
---|
82 | |
---|
83 | |
---|
84 | |
---|
85 | |
---|