16 #error no need to expose this header to Swig
20 #ifndef BORNAGAIN_SAMPLE_FRESNEL_SCALARFRESNELMAP_H
21 #define BORNAGAIN_SAMPLE_FRESNEL_SCALARFRESNELMAP_H
26 #include <unordered_map>
45 std::unique_ptr<const ILayerRTCoefficients>
52 size_t operator()(
const std::pair<double, double>& doubles)
const noexcept;
56 size_t layer_index)
const override;
Defines interface IFresnelMap.
Defines class ScalarRTCoefficients.
Holds the necessary information to calculate the radiation wavefunction in every layer for different ...
Interface to access reflection/transmission coefficients.
std::vector< std::unique_ptr< const ILayerRTCoefficients > > coeffs_t
Provides a hash function for a pair of doubles.
size_t operator()(const std::pair< double, double > &doubles) const noexcept
Returns hash value of a pair of doubles, computed by exclusive-or of the component hash values.
Implementation of IFresnelMap for scalar valued reflection/transmission coefficients.
std::unique_ptr< const ILayerRTCoefficients > getOutCoefficients(const SimulationElement &sim_element, size_t layer_index) const override
Retrieves the amplitude coefficients for a (time-reversed) outgoing wavevector.
ScalarFresnelMap(std::unique_ptr< ISpecularStrategy > strategy)
const ISpecularStrategy::coeffs_t & getCoefficientsFromCache(kvector_t kvec) const
std::unique_ptr< const ILayerRTCoefficients > getCoefficients(const kvector_t &kvec, size_t layer_index) const override
~ScalarFresnelMap() override
ScalarFresnelMap(const ScalarFresnelMap &other)=delete
ScalarFresnelMap & operator=(const ScalarFresnelMap &other)=delete
std::unordered_map< std::pair< double, double >, ISpecularStrategy::coeffs_t, Hash2Doubles > m_cache
Data stucture containing both input and output of a single detector cell.
Data structure containing the data of a single slice, for calculating the Fresnel coefficients.