source: palm/trunk/SOURCE/local_stop.f90 @ 112

Last change on this file since 112 was 110, checked in by raasch, 17 years ago

New:
---
Allows runs for a coupled atmosphere-ocean LES,
coupling frequency is controlled by new d3par-parameter dt_coupling,
the coupling mode (atmosphere_to_ocean or ocean_to_atmosphere) for the
respective processes is read from environment variable coupling_mode,
which is set by the mpiexec-command,
communication between the two models is done using the intercommunicator
comm_inter,
local files opened by the ocean model get the additional suffic "_O".
Assume saturation at k=nzb_s_inner(j,i) for atmosphere coupled to ocean.

A momentum flux can be set as top boundary condition using the new
inipar parameter top_momentumflux_u|v.

Non-cyclic boundary conditions can be used along all horizontal directions.

Quantities w*p* and w"e can be output as vertical profiles.

Initial profiles are reset to constant profiles in case that initializing_actions /= 'set_constant_profiles'. (init_rankine)

Optionally calculate km and kh from initial TKE e_init.

Changed:


Remaining variables iran changed to iran_part (advec_particles, init_particles).

In case that the presure solver is not called for every Runge-Kutta substep
(call_psolver_at_all_substeps = .F.), it is called after the first substep
instead of the last. In that case, random perturbations are also added to the
velocity field after the first substep.

Initialization of km,kh = 0.00001 for ocean = .T. (for ocean = .F. it remains 0.01).

Allow data_output_pr= q, wq, w"q", w*q* for humidity = .T. (instead of cloud_physics = .T.).

Errors:


Bugs from code parts for non-cyclic boundary conditions are removed: loops for
u and v are starting from index nxlu, nysv, respectively. The radiation boundary
condition is used for every Runge-Kutta substep. Velocity phase speeds for
the radiation boundary conditions are calculated for the first Runge-Kutta
substep only and reused for the further substeps. New arrays c_u, c_v, and c_w
are defined for this purpose. Several index errors are removed from the
radiation boundary condition code parts. Upper bounds for calculating
u_0 and v_0 (in production_e) are nxr+1 and nyn+1 because otherwise these
values are not available in case of non-cyclic boundary conditions.

+dots_num_palm in module user, +module netcdf_control in user_init (both in user_interface)

Bugfix: wrong sign removed from the buoyancy production term in the case use_reference = .T. (production_e)

Bugfix: Error message concerning output of particle concentration (pc) modified (check_parameters).

Bugfix: Rayleigh damping for ocean fixed.

  • Property svn:keywords set to Id
File size: 3.4 KB
Line 
1 SUBROUTINE local_stop
2
3!------------------------------------------------------------------------------!
4! Actual revisions:
5! -----------------
6!
7!
8!
9! Former revisions:
10! -----------------
11! $Id: local_stop.f90 110 2007-10-05 05:13:14Z raasch $
12!
13! 108 2007-08-24 15:10:38Z letzel
14! modifications to terminate coupled runs
15!
16! RCS Log replace by Id keyword, revision history cleaned up
17!
18! Revision 1.2  2003/03/16 09:40:28  raasch
19! Two underscores (_) are placed in front of all define-strings
20!
21! Revision 1.1  2002/12/19 15:46:23  raasch
22! Initial revision
23!
24!
25! Description:
26! ------------
27! Stop program execution
28!------------------------------------------------------------------------------!
29
30    USE pegrid
31    USE control_parameters
32
33#if defined( __parallel )
34    IF ( coupling_mode == 'uncoupled' )  THEN
35       CALL MPI_FINALIZE( ierr )
36    ELSE
37
38       SELECT CASE ( terminate_coupled_remote )
39
40          CASE ( 0 )
41             IF ( myid == 0 )  THEN
42                PRINT*, '+++ local_stop:'
43                PRINT*, '    local model "', TRIM( coupling_mode ), &
44                     '" stops now'
45             ENDIF
46!
47!--          Inform the remote model of the termination and its reason, provided
48!--          the remote model has not already been informed of another
49!--          termination reason (terminate_coupled > 0) before.
50             IF ( terminate_coupled == 0 )  THEN
51                terminate_coupled = 1
52                CALL MPI_SENDRECV( &
53                     terminate_coupled,        1, MPI_INTEGER, myid,  0, &
54                     terminate_coupled_remote, 1, MPI_INTEGER, myid,  0, &
55                     comm_inter, status, ierr )
56             ENDIF
57             CALL MPI_FINALIZE( ierr )
58
59          CASE ( 1 )
60             IF ( myid == 0 )  THEN
61                PRINT*, '+++ local_stop:'
62                PRINT*, '    remote model "', TRIM( coupling_mode_remote ), &
63                     '" stopped'
64             ENDIF
65             CALL MPI_FINALIZE( ierr )
66
67          CASE ( 2 )
68             IF ( myid == 0 )  THEN
69                PRINT*, '+++ local_stop:'
70                PRINT*, '    remote model "', TRIM( coupling_mode_remote ), &
71                     '" terminated'
72                PRINT*, '    with stop_dt = .T.'
73             ENDIF
74             stop_dt = .TRUE.
75
76          CASE ( 3 )
77             IF ( myid == 0 )  THEN
78                PRINT*, '+++ local_stop:'
79                PRINT*, '    remote model "', TRIM( coupling_mode_remote ), &
80                     '" terminated'
81                PRINT*, '    with terminate_run = .T. (CPU-time limit)'
82             ENDIF
83             terminate_run = .TRUE.
84
85          CASE ( 4 )
86             IF ( myid == 0 )  THEN
87                PRINT*, '+++ local_stop:'
88                PRINT*, '    remote model "', TRIM( coupling_mode_remote ), &
89                     '" terminated'
90                PRINT*, '    with terminate_run = .T. (restart)'
91             ENDIF
92             terminate_run = .TRUE.
93             time_restart = time_restart + dt_restart
94
95          CASE ( 5 )
96             IF ( myid == 0 )  THEN
97                PRINT*, '+++ local_stop:'
98                PRINT*, '    remote model "', TRIM( coupling_mode_remote ), &
99                     '" terminated'
100                PRINT*, '    with terminate_run = .T. (single restart)'
101             ENDIF
102             terminate_run = .TRUE.
103             time_restart = 9999999.9
104
105       END SELECT
106
107    ENDIF
108
109#else
110
111    STOP
112
113#endif
114
115 END SUBROUTINE local_stop   
Note: See TracBrowser for help on using the repository browser.