]> https://gitweb.dealii.org/ - dealii.git/commitdiff
use beta_dot_n
authorTimo Heister <timo.heister@gmail.com>
Thu, 24 Oct 2019 09:16:49 +0000 (11:16 +0200)
committerTimo Heister <timo.heister@gmail.com>
Thu, 24 Oct 2019 09:16:49 +0000 (11:16 +0200)
examples/step-12/step-12.cc

index 619f7882d0ac37de8c90dfa6959d59028eeabd0d..badf5073ebb075ef85ad76b0b0b8b2ff395c507b 100644 (file)
@@ -354,23 +354,23 @@ namespace Step12
 
       for (unsigned int point = 0; point < q_points.size(); ++point)
         {
-          const double beta_n = beta(q_points[point]) * normals[point];
+          const double beta_dot_n = beta(q_points[point]) * normals[point];
 
-          if (beta_n > 0)
+          if (beta_dot_n > 0)
             {
               for (unsigned int i = 0; i < n_facet_dofs; ++i)
                 for (unsigned int j = 0; j < n_facet_dofs; ++j)
                   copy_data.cell_matrix(i, j) +=
                     fe_face.shape_value(i, point)   // \phi_i
                     * fe_face.shape_value(j, point) // \phi_j
-                    * beta_n                        // \beta . n
+                    * beta_dot_n                    // \beta . n
                     * JxW[point];                   // dx
             }
           else
             for (unsigned int i = 0; i < n_facet_dofs; ++i)
               copy_data.cell_rhs(i) += -fe_face.shape_value(i, point) // \phi_i
                                        * g[point]                     // g
-                                       * beta_n      // \beta . n
+                                       * beta_dot_n  // \beta . n
                                        * JxW[point]; // dx
         }
     };
@@ -403,14 +403,15 @@ namespace Step12
 
       for (unsigned int qpoint = 0; qpoint < q_points.size(); ++qpoint)
         {
-          const double beta_n = beta(q_points[qpoint]) * normals[qpoint];
+          const double beta_dot_n = beta(q_points[qpoint]) * normals[qpoint];
           for (unsigned int i = 0; i < n_dofs; ++i)
             for (unsigned int j = 0; j < n_dofs; ++j)
               copy_data_face.cell_matrix(i, j) +=
-                fe_iv.jump(i, qpoint)                        // [\phi_i]
-                * fe_iv.shape_value((beta_n > 0), j, qpoint) // phi_j^{upwind}
-                * beta_n                                     // (\beta . n)
-                * JxW[qpoint];                               // dx
+                fe_iv.jump(i, qpoint) // [\phi_i]
+                *
+                fe_iv.shape_value((beta_dot_n > 0), j, qpoint) // phi_j^{upwind}
+                * beta_dot_n                                   // (\beta . n)
+                * JxW[qpoint];                                 // dx
         }
     };
 

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.