<p><b>duda</b> 2010-10-06 12:22:15 -0600 (Wed, 06 Oct 2010)</p><p>BRANCH COMMIT<br>
<br>
Use the correct diagnostic fields in the first RK step of each<br>
time step in the non-hydrostatic solver. <br>
<br>
Previously, our main solver loop looked like<br>
<br>
0. Compute diagnostic fields in time_levs(1)<br>
<br>
BEGIN TIME LOOP<br>
<br>
   1. Copy prognostic fields from time_levs(1) to time_levs(2) in rk_integration_setup<br>
<br>
   BEGIN RK LOOP<br>
      2. Compute tendencies based on prognostic and diagnostic fields in time_levs(2)<br>
      ...<br>
      3. Compute diagnostic fields in time_levs(2)<br>
   END RK LOOP <br>
   <br>
   4. Swap time_levs(2) and time_levs(1) <br>
<br>
END TIME LOOP<br>
<br>
which led to the use of diagnostic fields from the previous<br>
time step in the first RK step. To correct this problem, we copy <br>
the diagnostic fields rho_edge, v, circulation, vorticity, divergence, <br>
ke, and pv_edge from time_levs(1) to time_levs(2) in rk_integration_setup<br>
in addition to prognostic fields.<br>
<br>
<br>
M    src/core_nhyd_atmos/module_time_integration.F<br>
</p><hr noshade><pre><font color="gray">Modified: branches/atmos_nonhydrostatic/src/core_nhyd_atmos/module_time_integration.F
===================================================================
--- branches/atmos_nonhydrostatic/src/core_nhyd_atmos/module_time_integration.F        2010-10-06 17:19:21 UTC (rev 519)
+++ branches/atmos_nonhydrostatic/src/core_nhyd_atmos/module_time_integration.F        2010-10-06 18:22:15 UTC (rev 520)
@@ -450,9 +450,16 @@
      s_old % rho % array = s_new % rho % array
      s_old % pressure % array = s_new % pressure % array
 
-
      s_old % scalars % array = s_new % scalars % array
 
+     s_old % rho_edge % array = s_new % rho_edge % array
+     s_old % v % array = s_new % v % array
+     s_old % circulation % array = s_new % circulation % array
+     s_old % vorticity % array = s_new % vorticity % array
+     s_old % divergence % array = s_new % divergence % array
+     s_old % ke % array = s_new % ke % array
+     s_old % pv_edge % array = s_new % pv_edge % array
+
    end subroutine rk_integration_setup
 
 !-----

</font>
</pre>