[cig-commits] commit 2035 by bangerth to /var/svn/dealii/aspect

dealii.demon at gmail.com dealii.demon at gmail.com
Thu Nov 21 14:00:12 PST 2013


Revision 2035

Minor updates.

U   trunk/aspect/tests/compressibility.cc
U   trunk/aspect/tests/compressibility.prm


http://www.dealii.org/websvn/revision.php?repname=Aspect+Repository&path=%2F&rev=2035&peg=2035

Diff:
Modified: trunk/aspect/tests/compressibility.cc
===================================================================
--- trunk/aspect/tests/compressibility.cc	2013-11-21 21:00:29 UTC (rev 2034)
+++ trunk/aspect/tests/compressibility.cc	2013-11-21 21:59:41 UTC (rev 2035)
@@ -49,18 +49,19 @@
              const std::vector<double> &composition,
              const Point<dim> &position) const
     {
-      return 1.0 + compressibility(temperature,pressure,composition,position) * pressure;
+      return 1.0 + pressure;
     }
 
     template <int dim>
     double
     Compressibility<dim>::
     compressibility (const double ,
-                     const double,
+                     const double pressure,
                      const std::vector<double> &,
                      const Point<dim> &) const
     {
-      return 1.0;
+      // compressibility = 1/rho drho/dp
+      return 1.0 / (1. + pressure);
     }
 
     template <int dim>
@@ -184,7 +185,7 @@
 	      for (unsigned int q=0; q<fe_face_values.n_quadrature_points; ++q)
 	    	top_flux_integral += out.densities[q] * velocity_values[q][1] * fe_face_values.JxW(q);
 	  }
-    
+
       std::ostringstream screen_text1;
       std::ostringstream screen_text2;
       screen_text1.precision(4);

Modified: trunk/aspect/tests/compressibility.prm
===================================================================
--- trunk/aspect/tests/compressibility.prm	2013-11-21 21:00:29 UTC (rev 2034)
+++ trunk/aspect/tests/compressibility.prm	2013-11-21 21:59:41 UTC (rev 2035)
@@ -3,8 +3,9 @@
 # (0,1) at the bottom boundary, a tangential velocity at the sides
 # and a free boundary at the top.
 #
-# We then have a constant compressibilty that should lead to an
-# exponential density profile. The mass flux (product of density
+# We then choose a density rho=1+p and a compressibility that leads
+# to an exponential density profile rho=e^z, i.e.
+# compressibility=1/rho drho/dp=1/(1+p). The mass flux (product of density
 # and velocity) into the box and out of the box should be the same.
 #
 # We can only tell that the correct mass flux is computed in a


More information about the CIG-COMMITS mailing list