25 {{
"Radius",
"nm",
"horizontal radius", 0, +
INF, 0},
26 {
"Height",
"nm",
"height before removal of cap", 0, +
INF, 0},
27 {
"HeightFlattening",
"",
"ratio of vertical to horizontal radius", 0, +
INF, 0},
28 {
"DeltaHeight",
"nm",
"height of removed cap", 0, +
INF, 0}}},
32 , m_height_flattening(m_P[2])
35 check_initialization();
40 double height_flattening,
double dh)
49 std::ostringstream ostr;
50 ostr <<
"::FormFactorTruncatedSpheroid() -> Error in class initialization with parameters ";
54 ostr <<
"Check for 'height <= 2.*radius*height_flattening' failed.";
55 throw std::runtime_error(ostr.str());
66 double Rz = std::sqrt(R * R - Z * Z / (fp * fp));
70 return Rz * Rz * J1_qrRz_div_qrRz *
exp_I(
m_q.
z() * Z);
80 if (std::abs(
m_q.
mag()) <= std::numeric_limits<double>::epsilon())
81 return M_PI / 3. / fp * (H * H * (3. * R - H / fp) -
m_dh *
m_dh * (3. * R -
m_dh / fp));
94 effects.dz_top +
m_dh);
Defines Bessel functions in namespace Math.
std::complex< double > complex_t
complex_t exp_I(complex_t z)
Returns exp(I*z), where I is the imaginary unit.
Defines M_PI and some more mathematical constants.
Defines classes RealIntegrator, ComplexIntegrator.
Defines class TruncatedEllipsoid.
double mag() const
Returns magnitude of the vector.
T z() const
Returns z-component in cartesian coordinate system.
T y() const
Returns y-component in cartesian coordinate system.
T x() const
Returns x-component in cartesian coordinate system.
To integrate a complex function of a real variable.
complex_t integrate(const std::function< complex_t(double)> &f, double lmin, double lmax)
Abstract base class for Born form factors.
std::unique_ptr< IShape3D > m_shape3D
IShape3D object, used to retrieve vertices (which may be approximate in the case of round shapes).
static SlicingEffects computeSlicingEffects(ZLimits limits, const kvector_t &position, double height)
Helper method for slicing.
Abstract base class for rotations.
Class that contains upper and lower limits of the z-coordinate for the slicing of form factors.
double J1c(double x)
Bessel function J1(x)/x.