Index: palm/trunk/SOURCE/CURRENT_MODIFICATIONS
===================================================================
--- palm/trunk/SOURCE/CURRENT_MODIFICATIONS	(revision 40)
+++ palm/trunk/SOURCE/CURRENT_MODIFICATIONS	(revision 46)
@@ -2,15 +2,10 @@
 ---
 
-A heatflux can be prescribed at the top with new inipar parameters
-top_heatflux and use_top_fluxes. New 2d-arrays qswst, qswst_m, tswst and
-tswst_m are used to store this flux. Use of fluxes are controlled with new
-index variable nzt_diff. A Neumann boundary condition for
-temperature can be applied under these conditions. Additionally, a Dirichlet
-condition for temperature can be used at the top.
+new d3par-parameter netcdf_64bit_3d to switch on 64bit offset only for 3D files
 
-check_parameters, diffusion_s, flow_statistics, header, init_grid,
-init_3d_model, modules, parin,
-production_e, prognostic_equations, read_var_list, read_3d_binary,
-swap_timelevel, write_var_list, write_3d_binary
+new initializing action "by_user" calls user_init_3d_model and allows the
+initial setting of all 3d arrays
+
+check_open, check_parameters, header, init_3d_model, modules, parin, user_interface
 
 
@@ -18,17 +13,8 @@
 -------
 
-Prognostic equations for all scalars are now solved up to gridpoint nzt
-(formerly nzt-1). Boundary conditions for scalars at top adjusted respectively
-(now applied only at nzt+1).
+Move call of user_actions( 'after_integration' ) below increment of times
+and counters
 
-The default top boundary condition for temperature has been renamed to
-"initial gradient".
-
-dvrp_output_local, which was commented out for a long time, is now activated
-for all streams.
-
-advec_s_pw, boundary_conds, calc_precipitation, check_parameters, diffusion_e,
-diffusion_s, impact_of_latent_heat, init_dvrp,
-init_pt_anomaly, modules, production_e, prognostic_equations, spline_z
+time_integration
 
 
@@ -36,11 +22,5 @@
 ------
 
-Bugfix: 3d-array p is not a pointer any more.
+Bugfix: preset of tendencies te_em, te_um, te_vm in init_1d_model
 
-Bugfix in init_particles: MPI_REAL in MPI_ALLREDUCE replaced by
-MPI_INTEGER (caused error on NEC only)
-
-Bugfix:  ddzw dimensioned 1:nzt"+1"
-
-diffusion_e, diffusion_s, diffusion_u, diffusion_v, diffusion_w,
-init_particles, modules
+init_1d_model
Index: palm/trunk/SOURCE/check_open.f90
===================================================================
--- palm/trunk/SOURCE/check_open.f90	(revision 40)
+++ palm/trunk/SOURCE/check_open.f90	(revision 46)
@@ -4,5 +4,5 @@
 ! Actual revisions:
 ! -----------------
-! 
+! +netcdf_64bit_3d to switch on 64bit offset only for 3D files
 !
 ! Former revisions:
@@ -989,5 +989,5 @@
 !
 !--          Create a new NetCDF output file
-             IF ( netcdf_64bit )  THEN
+             IF ( netcdf_64bit .AND. netcdf_64bit_3d )  THEN
 #if defined( __netcdf_64bit )
                 nc_stat = NF90_CREATE( filename,                               &
Index: palm/trunk/SOURCE/check_parameters.f90
===================================================================
--- palm/trunk/SOURCE/check_parameters.f90	(revision 40)
+++ palm/trunk/SOURCE/check_parameters.f90	(revision 46)
@@ -4,5 +4,5 @@
 ! Actual revisions:
 ! -----------------
-! 
+! "by_user" allowed as initializing action
 !
 ! Former revisions:
@@ -292,5 +292,5 @@
 
              CASE ( 'set_constant_profiles', 'set_1d-model_profiles', &
-                    'initialize_vortex',     'initialize_ptanom' )
+                    'by_user', 'initialize_vortex',     'initialize_ptanom' )
                 action = action(position+1:)
 
@@ -308,4 +308,18 @@
        IF ( myid == 0 )  PRINT*, '+++ check_parameters: initializing_actions', &
           '"set_constant_profiles" and "set_1d-model_profiles" are not', &
+          ' allowed simultaneously'
+       CALL local_stop
+    ENDIF
+    IF ( INDEX( initializing_actions, 'set_constant_profiles' ) /= 0  .AND. &
+         INDEX( initializing_actions, 'by_user' ) /= 0 )  THEN
+       IF ( myid == 0 )  PRINT*, '+++ check_parameters: initializing_actions', &
+          '"set_constant_profiles" and "by_user" are not', &
+          ' allowed simultaneously'
+       CALL local_stop
+    ENDIF
+    IF ( INDEX( initializing_actions, 'by_user' ) /= 0  .AND. &
+         INDEX( initializing_actions, 'set_1d-model_profiles' ) /= 0 )  THEN
+       IF ( myid == 0 )  PRINT*, '+++ check_parameters: initializing_actions', &
+          '"by_user" and "set_1d-model_profiles" are not', &
           ' allowed simultaneously'
        CALL local_stop
Index: palm/trunk/SOURCE/header.f90
===================================================================
--- palm/trunk/SOURCE/header.f90	(revision 40)
+++ palm/trunk/SOURCE/header.f90	(revision 46)
@@ -4,5 +4,5 @@
 ! Actual revisions:
 ! -----------------
-! 
+! Output of netcdf_64bit_3d
 !
 ! Former revisions:
@@ -696,5 +696,5 @@
           output_format = ''
           IF ( netcdf_output )  THEN
-             IF ( netcdf_64bit )  THEN
+             IF ( netcdf_64bit .AND. netcdf_64bit_3d )  THEN
                 output_format = 'netcdf (64 bit offset)'
              ELSE
Index: palm/trunk/SOURCE/init_1d_model.f90
===================================================================
--- palm/trunk/SOURCE/init_1d_model.f90	(revision 40)
+++ palm/trunk/SOURCE/init_1d_model.f90	(revision 46)
@@ -4,5 +4,5 @@
 ! Actual revisions:
 ! -----------------
-! 
+! Bugfix: preset of tendencies te_em, te_um, te_vm
 !
 ! Former revisions:
@@ -128,4 +128,11 @@
 
 !
+!-- Tendencies must be preset in order to avoid runtime errors within the
+!-- first Runge-Kutta step
+    te_em = 0.0
+    te_um = 0.0
+    te_vm = 0.0
+
+!
 !-- Set start time in hh:mm:ss - format
     simulated_time_chr = time_to_string( simulated_time_1d )
Index: palm/trunk/SOURCE/init_3d_model.f90
===================================================================
--- palm/trunk/SOURCE/init_3d_model.f90	(revision 40)
+++ palm/trunk/SOURCE/init_3d_model.f90	(revision 46)
@@ -7,5 +7,5 @@
 ! Actual revisions:
 ! -----------------
-! 
+! New initializing action "by_user" calls user_init_3d_model
 !
 ! Former revisions:
@@ -422,4 +422,10 @@
           IF ( sloping_surface )  CALL init_slope
 
+       ELSEIF ( INDEX(initializing_actions, 'by_user') /= 0 ) &
+       THEN
+!
+!--       Initialization will completely be done by the user
+          CALL user_init_3d_model
+
        ENDIF
 
Index: palm/trunk/SOURCE/modules.f90
===================================================================
--- palm/trunk/SOURCE/modules.f90	(revision 40)
+++ palm/trunk/SOURCE/modules.f90	(revision 46)
@@ -5,11 +5,15 @@
 ! Actual revisions:
 ! -----------------
+! +netcdf_64bit_3d
+!
+! Former revisions:
+! -----------------
+! $Id$
+!
+! 37 2007-03-01 08:33:54Z raasch
 ! +constant_top_heatflux, top_heatflux, use_top_fluxes, +arrays for top fluxes,
 ! +nzt_diff, default of bc_pt_t renamed "initial_gradient"
 ! Bugfix: p is not a pointer
 !
-! Former revisions:
-! -----------------
-! $Id$
 ! RCS Log replace by Id keyword, revision history cleaned up
 !
@@ -279,4 +283,5 @@
                 mg_switch_to_pe0 = .FALSE., moisture = .FALSE., &
                 netcdf_output = .FALSE., netcdf_64bit = .FALSE., &
+                netcdf_64bit_3d = .TRUE., &
                 outflow_l = .FALSE., outflow_n = .FALSE., outflow_r = .FALSE., &
                 outflow_s = .FALSE., passive_scalar = .FALSE., &
Index: palm/trunk/SOURCE/parin.f90
===================================================================
--- palm/trunk/SOURCE/parin.f90	(revision 40)
+++ palm/trunk/SOURCE/parin.f90	(revision 46)
@@ -4,5 +4,5 @@
 ! Actual revisions:
 ! -----------------
-! 
+! +netcdf_64bit_3d in d3par
 !
 ! Former revisions:
@@ -100,5 +100,5 @@
                        dt_do2d_yz, dt_do3d, dt_restart, dt_run_control, &
                        end_time, force_print_header, mg_cycles, &
-                       mg_switch_to_pe0_level, netcdf_64bit, &
+                       mg_switch_to_pe0_level, netcdf_64bit, netcdf_64bit_3d, &
                        ngsrb, normalizing_region, nsor, nz_do3d, omega_sor, &
                        prandtl_number, profile_columns, profile_rows, psolver, &
Index: palm/trunk/SOURCE/time_integration.f90
===================================================================
--- palm/trunk/SOURCE/time_integration.f90	(revision 40)
+++ palm/trunk/SOURCE/time_integration.f90	(revision 46)
@@ -4,5 +4,6 @@
 ! Actual revisions:
 ! -----------------
-! 
+! Move call of user_actions( 'after_integration' ) below increment of times
+! and counters
 !
 ! Former revisions:
@@ -243,8 +244,4 @@
 
 !
-!--    Execute user-defined actions
-       CALL user_actions( 'after_integration' )
-
-!
 !--    Increase simulation time and output times
        current_timestep_number = current_timestep_number + 1
@@ -279,4 +276,8 @@
        time_dopr_listing          = time_dopr_listing        + dt_3d
        time_run_control   = time_run_control + dt_3d
+
+!
+!--    Execute user-defined actions
+       CALL user_actions( 'after_integration' )
 
 !
Index: palm/trunk/SOURCE/user_interface.f90
===================================================================
--- palm/trunk/SOURCE/user_interface.f90	(revision 40)
+++ palm/trunk/SOURCE/user_interface.f90	(revision 46)
@@ -4,5 +4,6 @@
 ! Actual revisions:
 ! -----------------
-! 
+! New routine user_init_3d_model which allows the initial setting of all 3d
+! arrays under control of the user
 !
 ! Former revisions:
@@ -228,4 +229,28 @@
 
  END SUBROUTINE user_init_grid
+
+
+
+ SUBROUTINE user_init_3d_model
+
+!------------------------------------------------------------------------------!
+!
+! Description:
+! ------------
+! Allows the complete initialization of the 3d model.
+!
+! CAUTION: The user is responsible to set at least all those quantities which
+! ------   are normally set within init_3d_model!
+!------------------------------------------------------------------------------!
+
+    USE arrays_3d
+    USE control_parameters
+    USE indices
+    USE user
+
+    IMPLICIT NONE
+
+
+ END SUBROUTINE user_init_3d_model
 
 
