branch: devel-logari81
commit 4d1d1f9124dc9fed19eb5b6eb318042b71fb1ba8
Author: Konstantinos Poulios <logar...@gmail.com>
Date:   Mon Aug 7 01:22:51 2017 +0200

    function/class naming normalization
---
 interface/src/gf_mesh.cc             |  2 +-
 src/bgeot_convex_ref.cc              | 16 ++++++++--------
 src/bgeot_convex_ref_simplexified.cc |  4 ++--
 src/bgeot_convex_structure.cc        | 14 +++++++-------
 src/bgeot_geometric_trans.cc         | 22 +++++++++++-----------
 src/getfem/bgeot_convex_ref.h        |  6 +++---
 src/getfem/bgeot_convex_structure.h  |  2 +-
 src/getfem/bgeot_geometric_trans.h   |  2 +-
 src/getfem_fem.cc                    | 18 +++++++++---------
 src/getfem_import.cc                 |  2 +-
 src/getfem_integration.cc            |  4 ++--
 src/getfem_integration_composite.cc  |  2 +-
 src/getfem_mesh.cc                   |  2 +-
 src/getfem_regular_meshes.cc         |  2 +-
 14 files changed, 49 insertions(+), 49 deletions(-)

diff --git a/interface/src/gf_mesh.cc b/interface/src/gf_mesh.cc
index c59ea36..050baf5 100644
--- a/interface/src/gf_mesh.cc
+++ b/interface/src/gf_mesh.cc
@@ -133,7 +133,7 @@ pyramidal_mesh(getfem::mesh *pmesh, getfemint::mexargs_in 
&in) {
   std::vector<int> ipt(dim);
   std::vector<getfem::base_node> pts(1 << (dim+1));
 
-  bgeot::pgeometric_trans pgt = bgeot::pyramidal_geotrans(1);
+  bgeot::pgeometric_trans pgt = bgeot::pyramid_geotrans(1);
 
   /* add the convexes */
   for (size_type i=0; i < grid_nconvex; i++) {
diff --git a/src/bgeot_convex_ref.cc b/src/bgeot_convex_ref.cc
index 2b3abe4..00386c8 100644
--- a/src/bgeot_convex_ref.cc
+++ b/src/bgeot_convex_ref.cc
@@ -280,11 +280,11 @@ namespace bgeot {
   };
 
 
-  DAL_SIMPLE_KEY(Q2_incomplete_reference_key_, dim_type);
+  DAL_SIMPLE_KEY(Q2_incomplete_of_reference_key_, dim_type);
 
-  pconvex_ref Q2_incomplete_reference(dim_type nc) {
+  pconvex_ref Q2_incomplete_of_reference(dim_type nc) {
      dal::pstatic_stored_object_key
-      pk = std::make_shared<Q2_incomplete_reference_key_>(nc);
+      pk = std::make_shared<Q2_incomplete_of_reference_key_>(nc);
     dal::pstatic_stored_object o = dal::search_stored_object(pk);
     if (o) return std::dynamic_pointer_cast<const convex_of_reference>(o);
     pconvex_ref p = std::make_shared<Q2_incomplete_of_ref_>(nc);
@@ -321,13 +321,13 @@ namespace bgeot {
       GMM_ASSERT1(k == 1 || k == 2,
                   "Sorry exist only in degree 1 or 2, not " << k);
 
-      cvs = pyramidal_structure(k);
+      cvs = pyramid_structure(k);
       convex<base_node>::points().resize(cvs->nb_points());
       normals_.resize(cvs->nb_faces());
       if (k == 1)
         auto_basic = true;
       else
-        basic_convex_ref_ = pyramidal_element_of_reference(1);
+        basic_convex_ref_ = pyramid_of_reference(1);
 
       sc(normals_[0]) =  0., 0., -1.;
       sc(normals_[1]) =  0.,-1.,  1.;
@@ -365,11 +365,11 @@ namespace bgeot {
   };
 
 
-  DAL_SIMPLE_KEY(pyramidal_reference_key_, dim_type);
+  DAL_SIMPLE_KEY(pyramid_reference_key_, dim_type);
 
-  pconvex_ref pyramidal_element_of_reference(dim_type k) {
+  pconvex_ref pyramid_of_reference(dim_type k) {
      dal::pstatic_stored_object_key
-      pk = std::make_shared<pyramidal_reference_key_>(k);
+      pk = std::make_shared<pyramid_reference_key_>(k);
     dal::pstatic_stored_object o = dal::search_stored_object(pk);
     if (o) return std::dynamic_pointer_cast<const convex_of_reference>(o);
     pconvex_ref p = std::make_shared<pyramid_of_ref_>(k);
diff --git a/src/bgeot_convex_ref_simplexified.cc 
b/src/bgeot_convex_ref_simplexified.cc
index 94292bb..4e1a230 100644
--- a/src/bgeot_convex_ref_simplexified.cc
+++ b/src/bgeot_convex_ref_simplexified.cc
@@ -251,7 +251,7 @@ namespace bgeot {
 
   static size_type simplexified_prism_6_nb = 6;
  
-  static size_type simplexified_pyramid[30] = {
+  static size_type simplexified_pyramid[8] = {
      0, 1, 2, 4, 3, 2, 1, 4
   };
 
@@ -305,7 +305,7 @@ namespace bgeot {
       return simplexified_prism_6_nb;
     }
 
-    if (cvs == pyramidal_structure(1)) {
+    if (cvs == pyramid_structure(1)) {
       *tab = simplexified_pyramid;
       return simplexified_pyramid_nb;
     }
diff --git a/src/bgeot_convex_structure.cc b/src/bgeot_convex_structure.cc
index fe14175..cfa49fa 100644
--- a/src/bgeot_convex_structure.cc
+++ b/src/bgeot_convex_structure.cc
@@ -465,22 +465,22 @@ namespace bgeot {
   /*        Pyramidal 3D structure for k=1 or 2.                          */
   /* ******************************************************************** */
 
-  struct pyramidal_structure_ : public convex_structure {
-    friend pconvex_structure pyramidal_structure(dim_type k);
+  struct pyramid_structure_ : public convex_structure {
+    friend pconvex_structure pyramid_structure(dim_type k);
   };
 
-  DAL_SIMPLE_KEY(pyramidal_structure_key_, dim_type);
+  DAL_SIMPLE_KEY(pyramid_structure_key_, dim_type);
 
-  pconvex_structure pyramidal_structure(dim_type k) {
+  pconvex_structure pyramid_structure(dim_type k) {
     GMM_ASSERT1(k == 1 || k == 2, "Sorry, pyramidal elements implemented "
                 "only for degree one or two.");
     dal::pstatic_stored_object_key
-      pcsk = std::make_shared<pyramidal_structure_key_>(k);
+      pcsk = std::make_shared<pyramid_structure_key_>(k);
     dal::pstatic_stored_object o = dal::search_stored_object(pcsk);
     if (o)
       return std::dynamic_pointer_cast<const convex_structure>(o);
 
-    auto p = std::make_shared<pyramidal_structure_>();
+    auto p = std::make_shared<pyramid_structure_>();
     pconvex_structure pcvs(p);
 
     p->Nc = 3;
@@ -522,7 +522,7 @@ namespace bgeot {
     } else {
       p->nbpt = 14;
       p->nbf = 5;
-      p->basic_pcvs = pyramidal_structure(1);
+      p->basic_pcvs = pyramid_structure(1);
       //    13
       //   /  |
       //  11--12
diff --git a/src/bgeot_geometric_trans.cc b/src/bgeot_geometric_trans.cc
index b07fc04..2886324 100644
--- a/src/bgeot_geometric_trans.cc
+++ b/src/bgeot_geometric_trans.cc
@@ -783,7 +783,7 @@ namespace bgeot {
 
   struct Q2_incomplete_trans_: public poly_geometric_trans  {
     Q2_incomplete_trans_(dim_type nc) {
-      cvr = Q2_incomplete_reference(nc);
+      cvr = Q2_incomplete_of_reference(nc);
       size_type R = cvr->structure()->nb_points();
       is_lin = false;
       complexity_ = 2;
@@ -846,7 +846,7 @@ namespace bgeot {
     int n = int(::floor(params[0].num() + 0.01));
     GMM_ASSERT1(n == 2 || n == 3, "Bad parameter, expected value 2 or 3");
 
-    dependencies.push_back(Q2_incomplete_reference(dim_type(n)));
+    dependencies.push_back(Q2_incomplete_of_reference(dim_type(n)));
     return std::make_shared<Q2_incomplete_trans_>(dim_type(n));
   }
 
@@ -860,9 +860,9 @@ namespace bgeot {
   /*    Pyramidal geometric transformation of order k=1 or 2.             */
   /* ******************************************************************** */
 
-  struct pyramidal_trans_: public fraction_geometric_trans  {
-    pyramidal_trans_(short_type k) {
-      cvr = pyramidal_element_of_reference(k);
+  struct pyramid_trans_: public fraction_geometric_trans  {
+    pyramid_trans_(short_type k) {
+      cvr = pyramid_of_reference(k);
       size_type R = cvr->structure()->nb_points();
       is_lin = false;
       complexity_ = k;
@@ -907,18 +907,18 @@ namespace bgeot {
   };
 
   static pgeometric_trans
-  pyramidal_gt(gt_param_list& params,
-               std::vector<dal::pstatic_stored_object> &deps) {
+  pyramid_gt(gt_param_list& params,
+             std::vector<dal::pstatic_stored_object> &deps) {
     GMM_ASSERT1(params.size() == 1, "Bad number of parameters : "
                 << params.size() << " should be 1.");
     GMM_ASSERT1(params[0].type() == 0, "Bad type of parameters");
     int k = int(::floor(params[0].num() + 0.01));
 
-    deps.push_back(pyramidal_element_of_reference(dim_type(k)));
-    return std::make_shared<pyramidal_trans_>(dim_type(k));
+    deps.push_back(pyramid_of_reference(dim_type(k)));
+    return std::make_shared<pyramid_trans_>(dim_type(k));
   }
 
-  pgeometric_trans pyramidal_geotrans(short_type k) {
+  pgeometric_trans pyramid_geotrans(short_type k) {
     static short_type k_ = -1;
     static pgeometric_trans pgt = 0;
     if (k != k_) {
@@ -1007,7 +1007,7 @@ namespace bgeot {
       add_suffix("LINEAR_PRODUCT", linear_product_gt);
       add_suffix("LINEAR_QK", linear_qk);
       add_suffix("Q2_INCOMPLETE", Q2_incomplete_gt);
-      add_suffix("PYRAMID", pyramidal_gt);
+      add_suffix("PYRAMID", pyramid_gt);
     }
   };
 
diff --git a/src/getfem/bgeot_convex_ref.h b/src/getfem/bgeot_convex_ref.h
index 66db71e..340e0bb 100644
--- a/src/getfem/bgeot_convex_ref.h
+++ b/src/getfem/bgeot_convex_ref.h
@@ -145,11 +145,11 @@ namespace bgeot {
   /** incomplete Q2 quadrilateral/hexahedral of reference of dimension
       d = 2 or 3
   */
-  pconvex_ref Q2_incomplete_reference(dim_type d);
+  pconvex_ref Q2_incomplete_of_reference(dim_type d);
+  /** pyramidal element of reference of degree k (k = 1 or 2 only) */
+  pconvex_ref pyramid_of_reference(dim_type k);
   /** tensorial product of two convex ref.
       in order to ensure unicity, it is required the a->dim() >= b->dim() */
-  /** Pyramidal element of reference of degree k (k = 1 or 2 only) */
-  pconvex_ref pyramidal_element_of_reference(dim_type k);
   pconvex_ref convex_ref_product(pconvex_ref a, pconvex_ref b);
   /** equilateral simplex (degree 1). used only for mesh quality estimations */
   pconvex_ref equilateral_simplex_of_reference(dim_type nc);
diff --git a/src/getfem/bgeot_convex_structure.h 
b/src/getfem/bgeot_convex_structure.h
index 9a8cbe3..e3aba51 100644
--- a/src/getfem/bgeot_convex_structure.h
+++ b/src/getfem/bgeot_convex_structure.h
@@ -194,7 +194,7 @@ namespace bgeot {
                                     simplex_structure(1));
   }
   /// Give a pointer on the 3D pyramid structure for a degree k = 1 or 2.
-  pconvex_structure pyramidal_structure(short_type k);
+  pconvex_structure pyramid_structure(short_type k);
   
 
   /** Simplex structure with the Lagrange grid of degree k.
diff --git a/src/getfem/bgeot_geometric_trans.h 
b/src/getfem/bgeot_geometric_trans.h
index 9851024..b5fff62 100644
--- a/src/getfem/bgeot_geometric_trans.h
+++ b/src/getfem/bgeot_geometric_trans.h
@@ -221,7 +221,7 @@ namespace bgeot {
   pgeometric_trans APIDECL linear_product_geotrans(pgeometric_trans pg1,
                                            pgeometric_trans pg2);
   pgeometric_trans APIDECL Q2_incomplete_geotrans(dim_type nc);
-  pgeometric_trans APIDECL pyramidal_geotrans(short_type k);
+  pgeometric_trans APIDECL pyramid_geotrans(short_type k);
 
   /**
      Get the geometric transformation from its string name.
diff --git a/src/getfem_fem.cc b/src/getfem_fem.cc
index 5d81180..dfcd9e1 100644
--- a/src/getfem_fem.cc
+++ b/src/getfem_fem.cc
@@ -1257,9 +1257,9 @@ namespace getfem {
   // |       |
   // 0---1---2
 
-  static pfem build_pyramidal_pk_fem(short_type k, bool disc) {
+  static pfem build_pyramid_pk_fem(short_type k, bool disc) {
     auto p = std::make_shared<fem<base_rational_fraction>>();
-    p->mref_convex() = bgeot::pyramidal_element_of_reference(1);
+    p->mref_convex() = bgeot::pyramid_of_reference(1);
     p->dim() = 3;
     p->is_standard() = p->is_equivalent() = true;
     p->is_polynomial() = false;
@@ -1339,7 +1339,7 @@ namespace getfem {
   }
 
 
-  static pfem pyramidal_pk_fem
+  static pfem pyramid_pk_fem
   (fem_param_list &params, std::vector<dal::pstatic_stored_object> &deps) {
     GMM_ASSERT1(params.size() <= 1, "Bad number of parameters");
     short_type k = 2;
@@ -1347,13 +1347,13 @@ namespace getfem {
       GMM_ASSERT1(params[0].type() == 0, "Bad type of parameters");
       k = dim_type(::floor(params[0].num() + 0.01));
     }
-    pfem p = build_pyramidal_pk_fem(k, false);
+    pfem p = build_pyramid_pk_fem(k, false);
     deps.push_back(p->ref_convex(0));
     deps.push_back(p->node_tab(0));
     return p;
   }
 
-  static pfem pyramidal_disc_pk_fem
+  static pfem pyramid_disc_pk_fem
   (fem_param_list &params, std::vector<dal::pstatic_stored_object> &deps) {
     GMM_ASSERT1(params.size() <= 1, "Bad number of parameters");
     short_type k = 2;
@@ -1361,7 +1361,7 @@ namespace getfem {
       GMM_ASSERT1(params[0].type() == 0, "Bad type of parameters");
       k = dim_type(::floor(params[0].num() + 0.01));
     }
-    pfem p = build_pyramidal_pk_fem(k, true);
+    pfem p = build_pyramid_pk_fem(k, true);
     deps.push_back(p->ref_convex(0));
     deps.push_back(p->node_tab(0));
     return p;
@@ -3575,7 +3575,7 @@ namespace getfem {
 
     /* Identifying pyramids.                                              */
     if (!found && nbp == 5)
-      if (pgt->basic_structure() == bgeot::pyramidal_structure(1)) {
+      if (pgt->basic_structure() == bgeot::pyramid_structure(1)) {
         name << "FEM_PYRAMID" << suffix << "_LAGRANGE(";
         found = true; spec_dim = false;
       }
@@ -3660,8 +3660,8 @@ namespace getfem {
       add_suffix("RT0", P1_RT0);
       add_suffix("RT0Q", P1_RT0Q);
       add_suffix("NEDELEC", P1_nedelec);
-      add_suffix("PYRAMID_LAGRANGE", pyramidal_pk_fem);
-      add_suffix("PYRAMID_DISCONTINUOUS_LAGRANGE", pyramidal_disc_pk_fem);
+      add_suffix("PYRAMID_LAGRANGE", pyramid_pk_fem);
+      add_suffix("PYRAMID_DISCONTINUOUS_LAGRANGE", pyramid_disc_pk_fem);
     }
   };
 
diff --git a/src/getfem_import.cc b/src/getfem_import.cc
index 524f7ed..4894a85 100644
--- a/src/getfem_import.cc
+++ b/src/getfem_import.cc
@@ -56,7 +56,7 @@ namespace getfem {
         pgt = bgeot::prism_geotrans(3,1);
       } break;
       case 7: { /* PYRAMID */
-       pgt = bgeot::pyramidal_geotrans(1);
+        pgt = bgeot::pyramid_geotrans(1);
       } break;
       case 8: { /* 2ND ORDER LINE */
         pgt = bgeot::simplex_geotrans(1,2);
diff --git a/src/getfem_integration.cc b/src/getfem_integration.cc
index 85f5233..1f5094a 100644
--- a/src/getfem_integration.cc
+++ b/src/getfem_integration.cc
@@ -844,7 +844,7 @@ namespace getfem {
                             size_type ip1, size_type ip2=size_type(-1)) :
       approx_integration
       ((base_im->structure() == bgeot::parallelepiped_structure(3)) ?
-       bgeot::pyramidal_element_of_reference(1)
+       bgeot::pyramid_of_reference(1)
        : bgeot::simplex_of_reference(base_im->dim()))  {
       size_type N = base_im->dim();
 
@@ -867,7 +867,7 @@ namespace getfem {
       bgeot::pgeometric_trans pgt2 = bgeot::simplex_geotrans(N, 1);
       std::vector<base_node> nodes2(N+1);
       if (what == PYRAMID) {
-        pgt2 = bgeot::pyramidal_geotrans(1);
+        pgt2 = bgeot::pyramid_geotrans(1);
         nodes2.resize(5);
       }
       std::vector<size_type> other_nodes; // for the construction of node2
diff --git a/src/getfem_integration_composite.cc 
b/src/getfem_integration_composite.cc
index 828d0de..54d6271 100644
--- a/src/getfem_integration_composite.cc
+++ b/src/getfem_integration_composite.cc
@@ -213,7 +213,7 @@ namespace getfem {
     pintegration_method
       p = std::make_shared<integration_method>
       (composite_approx_int_method(jfs.mp, mi,
-                                  bgeot::pyramidal_element_of_reference(1)));
+                                   bgeot::pyramid_of_reference(1)));
     dependencies.push_back(p->approx_method()->ref_convex());
     dependencies.push_back(p->approx_method()->pintegration_points());
     return p;
diff --git a/src/getfem_mesh.cc b/src/getfem_mesh.cc
index 84a21d5..dbc701f 100644
--- a/src/getfem_mesh.cc
+++ b/src/getfem_mesh.cc
@@ -301,7 +301,7 @@ namespace getfem {
   size_type mesh::add_pyramid(size_type a, size_type b,
                               size_type c, size_type d, size_type e) {
     size_type ipt[5] = {a, b, c, d, e};
-    return add_convex(bgeot::pyramidal_geotrans(1), &(ipt[0]));
+    return add_convex(bgeot::pyramid_geotrans(1), &(ipt[0]));
   }
 
   size_type mesh::add_tetrahedron_by_points
diff --git a/src/getfem_regular_meshes.cc b/src/getfem_regular_meshes.cc
index 50d061c..bd4c5c4 100644
--- a/src/getfem_regular_meshes.cc
+++ b/src/getfem_regular_meshes.cc
@@ -254,7 +254,7 @@ namespace getfem
     } else if (pgt->basic_structure() == bgeot::prism_structure(N)) {
       getfem::parallelepiped_regular_prism_mesh
         (msh, N, org, vtab.begin(), nsubdiv.begin());
-    } else if (pgt->basic_structure() == bgeot::pyramidal_structure(1)) {
+    } else if (pgt->basic_structure() == bgeot::pyramid_structure(1)) {
       getfem::parallelepiped_regular_pyramid_mesh
         (msh, org, vtab.begin(), nsubdiv.begin());
     } else {

Reply via email to