From: Simon Sticko Date: Fri, 29 Mar 2024 08:11:57 +0000 (+0100) Subject: Add codimension in get_name() for a few elements X-Git-Tag: v9.6.0-rc1~425^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F16814%2Fhead;p=dealii.git Add codimension in get_name() for a few elements --- diff --git a/source/fe/fe_bernstein.cc b/source/fe/fe_bernstein.cc index a40c07773c..81e95083d5 100644 --- a/source/fe/fe_bernstein.cc +++ b/source/fe/fe_bernstein.cc @@ -340,7 +340,8 @@ FE_Bernstein::get_name() const // kept in synch std::ostringstream namebuf; - namebuf << "FE_Bernstein<" << dim << ">(" << this->degree << ")"; + namebuf << "FE_Bernstein<" << Utilities::dim_string(dim, spacedim) << ">(" + << this->degree << ")"; return namebuf.str(); } diff --git a/source/fe/fe_hermite.cc b/source/fe/fe_hermite.cc index e98507f646..f8a03ae255 100644 --- a/source/fe/fe_hermite.cc +++ b/source/fe/fe_hermite.cc @@ -510,8 +510,8 @@ std::string FE_Hermite::get_name() const { std::ostringstream name_buffer; - name_buffer << "FE_Hermite<" << dim << "," << spacedim << ">(" << this->degree - << ")"; + name_buffer << "FE_Hermite<" << Utilities::dim_string(dim, spacedim) << ">(" + << this->degree << ")"; return name_buffer.str(); } diff --git a/source/fe/fe_nedelec_sz.cc b/source/fe/fe_nedelec_sz.cc index a870d6acef..b06c0e18fd 100644 --- a/source/fe/fe_nedelec_sz.cc +++ b/source/fe/fe_nedelec_sz.cc @@ -3342,7 +3342,8 @@ FE_NedelecSZ::get_name() const // note that the FETools::get_fe_by_name function depends on the particular // format of the string this function returns, so they have to be kept in sync std::ostringstream namebuf; - namebuf << "FE_NedelecSZ<" << dim << ">(" << this->degree - 1 << ")"; + namebuf << "FE_NedelecSZ<" << Utilities::dim_string(dim, spacedim) << ">(" + << this->degree - 1 << ")"; return namebuf.str(); } diff --git a/source/fe/fe_pyramid_p.cc b/source/fe/fe_pyramid_p.cc index 3189df2ea2..053798fc69 100644 --- a/source/fe/fe_pyramid_p.cc +++ b/source/fe/fe_pyramid_p.cc @@ -163,7 +163,8 @@ std::string FE_PyramidP::get_name() const { std::ostringstream namebuf; - namebuf << "FE_PyramidP<" << dim << ">(" << this->degree << ")"; + namebuf << "FE_PyramidP<" << Utilities::dim_string(dim, spacedim) << ">(" + << this->degree << ")"; return namebuf.str(); } @@ -332,7 +333,8 @@ std::string FE_PyramidDGP::get_name() const { std::ostringstream namebuf; - namebuf << "FE_PyramidDGP<" << dim << ">(" << this->degree << ")"; + namebuf << "FE_PyramidDGP<" << Utilities::dim_string(dim, spacedim) << ">(" + << this->degree << ")"; return namebuf.str(); } diff --git a/source/fe/fe_q_bubbles.cc b/source/fe/fe_q_bubbles.cc index 0f0c6be5bf..7ed79ffb47 100644 --- a/source/fe/fe_q_bubbles.cc +++ b/source/fe/fe_q_bubbles.cc @@ -330,10 +330,11 @@ FE_Q_Bubbles::get_name() const break; } if (type == true) - namebuf << "FE_Q_Bubbles<" << dim << ">(" << this->degree - 1 << ")"; + namebuf << "FE_Q_Bubbles<" << Utilities::dim_string(dim, spacedim) + << ">(" << this->degree - 1 << ")"; else - namebuf << "FE_Q_Bubbles<" << dim << ">(QUnknownNodes(" << this->degree - << "))"; + namebuf << "FE_Q_Bubbles<" << Utilities::dim_string(dim, spacedim) + << ">(QUnknownNodes(" << this->degree << "))"; } return namebuf.str(); } diff --git a/source/fe/fe_simplex_p.cc b/source/fe/fe_simplex_p.cc index dacae09f06..4e342f3453 100644 --- a/source/fe/fe_simplex_p.cc +++ b/source/fe/fe_simplex_p.cc @@ -647,7 +647,8 @@ std::string FE_SimplexP::get_name() const { std::ostringstream namebuf; - namebuf << "FE_SimplexP<" << dim << ">(" << this->degree << ")"; + namebuf << "FE_SimplexP<" << Utilities::dim_string(dim, spacedim) << ">(" + << this->degree << ")"; return namebuf.str(); } @@ -893,7 +894,8 @@ std::string FE_SimplexDGP::get_name() const { std::ostringstream namebuf; - namebuf << "FE_SimplexDGP<" << dim << ">(" << this->degree << ")"; + namebuf << "FE_SimplexDGP<" << Utilities::dim_string(dim, spacedim) << ">(" + << this->degree << ")"; return namebuf.str(); } diff --git a/source/fe/fe_wedge_p.cc b/source/fe/fe_wedge_p.cc index e579221d63..c3004825e4 100644 --- a/source/fe/fe_wedge_p.cc +++ b/source/fe/fe_wedge_p.cc @@ -183,7 +183,8 @@ std::string FE_WedgeP::get_name() const { std::ostringstream namebuf; - namebuf << "FE_WedgeP<" << dim << ">(" << this->degree << ")"; + namebuf << "FE_WedgeP<" << Utilities::dim_string(dim, spacedim) << ">(" + << this->degree << ")"; return namebuf.str(); } @@ -352,7 +353,8 @@ std::string FE_WedgeDGP::get_name() const { std::ostringstream namebuf; - namebuf << "FE_WedgeDGP<" << dim << ">(" << this->degree << ")"; + namebuf << "FE_WedgeDGP<" << Utilities::dim_string(dim, spacedim) << ">(" + << this->degree << ")"; return namebuf.str(); } diff --git a/tests/fe/get_fe_by_name_01.output b/tests/fe/get_fe_by_name_01.output index 16931bb955..1a76dacb33 100644 --- a/tests/fe/get_fe_by_name_01.output +++ b/tests/fe/get_fe_by_name_01.output @@ -199,16 +199,16 @@ DEAL::Generated : DEAL::FE_Bernstein<1>(1) DEAL::Read FE_Bernstein(1) DEAL::Generated : -DEAL::FE_Bernstein<1>(1) +DEAL::FE_Bernstein<1,2>(1) DEAL::Read FE_Bernstein(1) DEAL::Generated : DEAL::FE_Bernstein<2>(1) DEAL::Read FE_Bernstein(1) DEAL::Generated : -DEAL::FE_Bernstein<1>(1) +DEAL::FE_Bernstein<1,3>(1) DEAL::Read FE_Bernstein(1) DEAL::Generated : -DEAL::FE_Bernstein<2>(1) +DEAL::FE_Bernstein<2,3>(1) DEAL::Read FE_Bernstein(1) DEAL::Generated : DEAL::FE_Bernstein<3>(1) @@ -307,13 +307,13 @@ DEAL::Generated : DEAL::FE_Q_Bubbles<1>(QUnknownNodes(2)) DEAL::Read FE_Q_Bubbles(1) DEAL::Generated : -DEAL::FE_Q_Bubbles<1>(QUnknownNodes(2)) +DEAL::FE_Q_Bubbles<1,2>(QUnknownNodes(2)) DEAL::Read FE_Q_Bubbles(1) DEAL::Generated : DEAL::FE_Q_Bubbles<2>(1) DEAL::Read FE_Q_Bubbles(1) DEAL::Generated : -DEAL::FE_Q_Bubbles<1>(QUnknownNodes(2)) +DEAL::FE_Q_Bubbles<1,3>(QUnknownNodes(2)) DEAL::Read FE_Q_Bubbles(1) DEAL::Generated : DEAL::FE_Q_Bubbles<2,3>(1) @@ -379,16 +379,16 @@ DEAL::Generated : DEAL::FE_Bernstein<1>(2) DEAL::Read FE_Bernstein(2) DEAL::Generated : -DEAL::FE_Bernstein<1>(2) +DEAL::FE_Bernstein<1,2>(2) DEAL::Read FE_Bernstein(2) DEAL::Generated : DEAL::FE_Bernstein<2>(2) DEAL::Read FE_Bernstein(2) DEAL::Generated : -DEAL::FE_Bernstein<1>(2) +DEAL::FE_Bernstein<1,3>(2) DEAL::Read FE_Bernstein(2) DEAL::Generated : -DEAL::FE_Bernstein<2>(2) +DEAL::FE_Bernstein<2,3>(2) DEAL::Read FE_Bernstein(2) DEAL::Generated : DEAL::FE_Bernstein<3>(2) @@ -451,13 +451,13 @@ DEAL::Generated : DEAL::FE_Q_Bubbles<1>(QUnknownNodes(3)) DEAL::Read FE_Q_Bubbles(2) DEAL::Generated : -DEAL::FE_Q_Bubbles<1>(QUnknownNodes(3)) +DEAL::FE_Q_Bubbles<1,2>(QUnknownNodes(3)) DEAL::Read FE_Q_Bubbles(2) DEAL::Generated : DEAL::FE_Q_Bubbles<2>(2) DEAL::Read FE_Q_Bubbles(2) DEAL::Generated : -DEAL::FE_Q_Bubbles<1>(QUnknownNodes(3)) +DEAL::FE_Q_Bubbles<1,3>(QUnknownNodes(3)) DEAL::Read FE_Q_Bubbles(2) DEAL::Generated : DEAL::FE_Q_Bubbles<2,3>(2) @@ -523,16 +523,16 @@ DEAL::Generated : DEAL::FE_Bernstein<1>(2) DEAL::Read FE_Bernstein(2) DEAL::Generated : -DEAL::FE_Bernstein<1>(2) +DEAL::FE_Bernstein<1,2>(2) DEAL::Read FE_Bernstein(2) DEAL::Generated : DEAL::FE_Bernstein<2>(2) DEAL::Read FE_Bernstein(2) DEAL::Generated : -DEAL::FE_Bernstein<1>(2) +DEAL::FE_Bernstein<1,3>(2) DEAL::Read FE_Bernstein(2) DEAL::Generated : -DEAL::FE_Bernstein<2>(2) +DEAL::FE_Bernstein<2,3>(2) DEAL::Read FE_Bernstein(2) DEAL::Generated : DEAL::FE_Bernstein<3>(2) @@ -559,16 +559,16 @@ DEAL::Generated : DEAL::FE_SimplexP<1>(1) DEAL::Read FE_SimplexP(1) DEAL::Generated : -DEAL::FE_SimplexP<1>(1) +DEAL::FE_SimplexP<1,2>(1) DEAL::Read FE_SimplexP(1) DEAL::Generated : DEAL::FE_SimplexP<2>(1) DEAL::Read FE_SimplexP(1) DEAL::Generated : -DEAL::FE_SimplexP<1>(1) +DEAL::FE_SimplexP<1,3>(1) DEAL::Read FE_SimplexP(1) DEAL::Generated : -DEAL::FE_SimplexP<2>(1) +DEAL::FE_SimplexP<2,3>(1) DEAL::Read FE_SimplexP(1) DEAL::Generated : DEAL::FE_SimplexP<3>(1) @@ -577,16 +577,16 @@ DEAL::Generated : DEAL::FE_SimplexP<1>(2) DEAL::Read FE_SimplexP(2) DEAL::Generated : -DEAL::FE_SimplexP<1>(2) +DEAL::FE_SimplexP<1,2>(2) DEAL::Read FE_SimplexP(2) DEAL::Generated : DEAL::FE_SimplexP<2>(2) DEAL::Read FE_SimplexP(2) DEAL::Generated : -DEAL::FE_SimplexP<1>(2) +DEAL::FE_SimplexP<1,3>(2) DEAL::Read FE_SimplexP(2) DEAL::Generated : -DEAL::FE_SimplexP<2>(2) +DEAL::FE_SimplexP<2,3>(2) DEAL::Read FE_SimplexP(2) DEAL::Generated : DEAL::FE_SimplexP<3>(2) @@ -595,16 +595,16 @@ DEAL::Generated : DEAL::FE_SimplexDGP<1>(1) DEAL::Read FE_SimplexDGP(1) DEAL::Generated : -DEAL::FE_SimplexDGP<1>(1) +DEAL::FE_SimplexDGP<1,2>(1) DEAL::Read FE_SimplexDGP(1) DEAL::Generated : DEAL::FE_SimplexDGP<2>(1) DEAL::Read FE_SimplexDGP(1) DEAL::Generated : -DEAL::FE_SimplexDGP<1>(1) +DEAL::FE_SimplexDGP<1,3>(1) DEAL::Read FE_SimplexDGP(1) DEAL::Generated : -DEAL::FE_SimplexDGP<2>(1) +DEAL::FE_SimplexDGP<2,3>(1) DEAL::Read FE_SimplexDGP(1) DEAL::Generated : DEAL::FE_SimplexDGP<3>(1) @@ -613,16 +613,16 @@ DEAL::Generated : DEAL::FE_SimplexDGP<1>(2) DEAL::Read FE_SimplexDGP(2) DEAL::Generated : -DEAL::FE_SimplexDGP<1>(2) +DEAL::FE_SimplexDGP<1,2>(2) DEAL::Read FE_SimplexDGP(2) DEAL::Generated : DEAL::FE_SimplexDGP<2>(2) DEAL::Read FE_SimplexDGP(2) DEAL::Generated : -DEAL::FE_SimplexDGP<1>(2) +DEAL::FE_SimplexDGP<1,3>(2) DEAL::Read FE_SimplexDGP(2) DEAL::Generated : -DEAL::FE_SimplexDGP<2>(2) +DEAL::FE_SimplexDGP<2,3>(2) DEAL::Read FE_SimplexDGP(2) DEAL::Generated : DEAL::FE_SimplexDGP<3>(2)