21 {{0, 1, 5, 4},
false},
22 {{1, 2, 6, 5},
false},
23 {{2, 3, 7, 6},
false},
24 {{3, 0, 4, 7},
false},
25 {{4, 5, 9, 8},
false},
26 {{5, 6, 10, 9},
false},
27 {{6, 7, 11, 10},
false},
28 {{7, 4, 8, 11},
false},
29 {{8, 9, 10, 11},
true}},
36 , m_height_ratio(m_P[2])
41 if (!std::isfinite(cot_alpha) || cot_alpha < 0)
42 throw std::runtime_error(
"pyramid angle alpha out of bounds");
45 if (std::max(1., x) * r > 1) {
46 std::ostringstream ostr;
47 ostr <<
"Bipyramid4() -> Error in class initialization with parameters";
51 ostr <<
" alpha[rad]:" <<
m_alpha <<
"\n\n";
52 ostr <<
"Check for '2.*height <= length*tan(alpha)*min(1.,1.0/height_ratio)' failed.";
53 throw std::runtime_error(ostr.str());
58 double c =
m_length / 2 * (1 - r * x);
61 m_height * ((x * x - 1) / 2 - 2 * r * (x * x * x - 1) / 3 + r * r * (x * x * x * x - 1) / 4)
62 / ((x + 1) - r * (x * x + 1) + r * r * (x * x * x + 1) / 3);
Defines class Bipyramid4.
Defines M_PI and some more mathematical constants.
A truncated bifrustum with quadratic base.
Bipyramid4(double length, double height, double height_ratio, double alpha)
static const ff::PolyhedralTopology topology
const double & m_height_ratio
void checkNodeArgs() const
Raises exception if a parameter value is invalid.
double cot(double x)
cotangent function: