Template Class InterpolatedMaterialMap¶
Defined in File InterpolatedMaterialMap.hpp
Nested Relationships¶
Nested Types¶
Inheritance Relationships¶
Base Type¶
public Acts::IVolumeMaterial
(Class IVolumeMaterial)
Class Documentation¶
-
template<typename
Mapper_t
>
classActs
::
InterpolatedMaterialMap
: public Acts::IVolumeMaterial¶ Interpolate material classification values from material values on a given grid.
This class implements a material service which is initialized by a material map defined by:
a list of material values on a regular grid in some n-Dimensional space,
a transformation of global 3D coordinates onto this n-Dimensional space.
a transformation of local n-Dimensional material coordinates into global (cartesian) 3D coordinates
The material value for a given global position is then determined by:
mapping the position onto the grid,
looking up the material classification values on the closest grid points,
doing a linear interpolation of these values.
- Warning
Each classification number of the material is interpolated independently and thus does not consider any correlations that exists between these values. This might work out since the used material is already a mean of the materials in a certain bin and can therewith be treated as a collection of numbers.
- Template Parameters
G
: Type of the grid
Public Functions
-
InterpolatedMaterialMap
(Mapper_t &&mapper)¶ Create interpolated map.
- Parameters
[in] mapper
: Material map
-
InterpolatedMaterialMap
(Mapper_t &&mapper, BinUtility bu)¶ Create interpolated map.
- Parameters
[in] mapper
: Material map[in] BinUtility
:
-
const BinUtility &
binUtility
() const¶ Return the BinUtility.
-
const Mapper_t &
getMapper
() const¶ Convenience method to access underlying material mapper.
- Return
The material mapper
-
Material
getMaterial
(const Vector3 &position) const¶ Retrieve the interpolated material.
- Return
material at given position
- Parameters
[in] position
: Global 3D position
-
Material
getMaterial
(const Vector3 &position, Cache &cache) const¶ Retrieve material.
- Return
material at given position
- Parameters
[in] position
: Global 3D position[inout] cache
: Cache object. Contains material cell used for interpolation
-
Material
getMaterialGradient
(const Vector3 &position, ActsMatrix<5, 5>&) const¶ Retrieve material value & its “gradient”.
- Return
Material
- Note
Currently the derivative is not calculated
- Parameters
[in] position
: Global 3D position[out] derivative
: “Gradient” of material as (5x5) matrix
-
Material
getMaterialGradient
(const Vector3 &position, ActsMatrix<5, 5>&, Cache&) const¶ Retrieve material value & its “gradient”.
- Return
Material
- Note
Currently the derivative is not calculated
- Note
Cache is not used currently
- Parameters
[in] position
: Global 3D position[out] derivative
: “Gradient” of material as (5x5) matrix[inout] cache
: Cache object. Contains cell used for
-
bool
isInside
(const Vector3 &position) const¶ Check whether given 3D position is inside look-up domain.
- Return
true
if position is inside the defined map, otherwisefalse
- Parameters
[in] position
: Global 3D position
-
const Material
material
(const Vector3 &position) const¶ Retrieve the binned material.
- Return
Material at given position
- Parameters
[in] position
: Global 3D position
-
std::ostream &
toStream
(std::ostream &sl) const¶ Output Method for std::ostream.
- Parameters
sl
: The outoput stream
-
struct
Cache
¶ Temporary storage of a certain cell to improve material access.