Go to the source code of this file.
|
| TEST (FunctionalExpansionsTest, legendreConstructor) |
|
| TEST (FunctionalExpansionsTest, legendreSeriesOrthonormalEvaluation) |
|
| TEST (FunctionalExpansionsTest, legendreSeriesSqrtMuEvaluation) |
|
| TEST (FunctionalExpansionsTest, legendreSeriesStandardEvaluation) |
|
| TEST (FunctionalExpansionsTest, CartesianConstructor) |
|
| TEST (FunctionalExpansionsTest, Cartesian3D) |
|
| TEST (FunctionalExpansionsTest, functionalBasisInterfaceCartesian) |
|
◆ TEST() [1/7]
TEST |
( |
FunctionalExpansionsTest |
, |
|
|
Cartesian3D |
|
|
) |
| |
Definition at line 147 of file Cartesian.C.
152 const std::vector<std::size_t> orders = {14, 21, 22};
160 const std::vector<Point> locations = {
161 Point(-0.14854612627465, 0.60364074055275, 0.76978431165674),
162 Point(0.93801805187856, 0.74175118177279, 0.74211345600994),
163 Point(0.35423736896098, -0.83921049062126, -0.02231845586669)};
164 const std::vector<Real> standard_truth = {1.32257143058688, 3.68047786932034, 0.17515811557416};
165 const std::vector<Real> orthogonal_truth = {
166 -2.33043696271172, 74.48747654183713, -14.48091828923379};
168 for (std::size_t i = 0; i < locations.size(); ++i)
170 legendre3D.setLocation(locations[i]);
171 EXPECT_NEAR(legendre3D.getExpansionSeriesSum(), standard_truth[i],
tol);
172 EXPECT_NEAR(legendre3D.getGenerationSeriesSum(), orthogonal_truth[i],
tol);
◆ TEST() [2/7]
TEST |
( |
FunctionalExpansionsTest |
, |
|
|
CartesianConstructor |
|
|
) |
| |
Definition at line 120 of file Cartesian.C.
122 std::vector<MooseEnum> domains;
123 std::vector<std::size_t> orders;
124 std::vector<MooseEnum> series;
132 EXPECT_EQ(legendreOne.getNumberOfTerms(), orders[0] + 1);
138 EXPECT_EQ(legendreTwo.getNumberOfTerms(), (orders[0] + 1) * (orders[1] + 1));
141 orders = {{14, 21, 22}};
144 EXPECT_EQ(legendreThree.getNumberOfTerms(), (orders[0] + 1) * (orders[1] + 1) * (orders[2] + 1));
◆ TEST() [3/7]
TEST |
( |
FunctionalExpansionsTest |
, |
|
|
functionalBasisInterfaceCartesian |
|
|
) |
| |
Definition at line 176 of file Cartesian.C.
181 const std::vector<std::size_t> orders = {4, 5, 3};
189 const Point location(-0.38541903411291, 0.61369802505416, -0.04539307255549);
190 const Real truth = 0.26458908225718;
194 EXPECT_NEAR(interface.getExpansionSeriesSum(), truth,
tol);
◆ TEST() [4/7]
TEST |
( |
FunctionalExpansionsTest |
, |
|
|
legendreConstructor |
|
|
) |
| |
Definition at line 16 of file Cartesian.C.
18 const unsigned int order = 5;
24 EXPECT_EQ(legendre.getOrder(0), order);
◆ TEST() [5/7]
TEST |
( |
FunctionalExpansionsTest |
, |
|
|
legendreSeriesOrthonormalEvaluation |
|
|
) |
| |
Definition at line 27 of file Cartesian.C.
29 const unsigned int order = 15;
30 Real location = -0.90922108754014;
31 const std::array<Real, order> truth = {{0.50000000000000,
53 auto & answer = legendre.getAllGeneration();
54 for (std::size_t i = 0; i < order; ++i)
55 EXPECT_NEAR(answer[i], truth[i],
tol);
◆ TEST() [6/7]
TEST |
( |
FunctionalExpansionsTest |
, |
|
|
legendreSeriesSqrtMuEvaluation |
|
|
) |
| |
Definition at line 58 of file Cartesian.C.
60 const unsigned int order = 15;
61 Real location = -0.90922108754014;
62 const std::array<Real, order> truth = {{0.50000000000000,
84 auto & answer = legendre.getAllGeneration();
85 for (std::size_t i = 0; i < order; ++i)
86 EXPECT_NEAR(answer[i], truth[i] / std::sqrt(i + 0.5),
tol);
◆ TEST() [7/7]
TEST |
( |
FunctionalExpansionsTest |
, |
|
|
legendreSeriesStandardEvaluation |
|
|
) |
| |
Definition at line 89 of file Cartesian.C.
91 const unsigned int order = 15;
92 Real location = -0.90922108754014;
93 const std::array<Real, order> truth = {{0.50000000000000,
115 auto & answer = legendre.getAllGeneration();
116 for (std::size_t i = 0; i < order; ++i)
117 EXPECT_NEAR(answer[i], truth[i] / (i + 0.5),
tol);