Mantid
Loading...
Searching...
No Matches
Public Member Functions | List of all members
Mantid::Algorithms::LinearWeighting Class Reference

#include <WeightingStrategy.h>

Inheritance diagram for Mantid::Algorithms::LinearWeighting:
Mantid::Algorithms::WeightingStrategy

Public Member Functions

 LinearWeighting (const double cutOff)
 Constructor. More...
 
double weightAt (const double &adjX, const double &ix, const double &adjY, const double &iy) override
 Calculate the weight at distance from epicenter using linear scaling. More...
 
double weightAt (const Mantid::Kernel::V3D &) override
 Calculate the weight at distance from epicenter. More...
 
- Public Member Functions inherited from Mantid::Algorithms::WeightingStrategy
virtual double weightAt (const double &adjX, const double &ix, const double &adjY, const double &iy)=0
 Calculate the weight at distance from epicenter. More...
 
virtual double weightAt (const Mantid::Kernel::V3D &distance)=0
 Calculate the weight at distance from epicenter. More...
 
 WeightingStrategy ()
 Constructor. More...
 
 WeightingStrategy (const double cutOff)
 Constructor. More...
 
virtual ~WeightingStrategy ()=default
 Destructor. More...
 

Additional Inherited Members

- Protected Attributes inherited from Mantid::Algorithms::WeightingStrategy
double m_cutOff
 Cutoff member. More...
 

Detailed Description

Definition at line 65 of file WeightingStrategy.h.

Constructor & Destructor Documentation

◆ LinearWeighting()

Mantid::Algorithms::LinearWeighting::LinearWeighting ( const double  cutOff)

Constructor.

Parameters
cutOff: cutoff radius

Definition at line 55 of file WeightingStrategy.cpp.

Member Function Documentation

◆ weightAt() [1/2]

double Mantid::Algorithms::LinearWeighting::weightAt ( const double &  adjX,
const double &  ix,
const double &  adjY,
const double &  iy 
)
overridevirtual

Calculate the weight at distance from epicenter using linear scaling.

Parameters
adjX: The number of Y (vertical) adjacent pixels to average together
ix: current index x
adjY: The number of X (vertical) adjacent pixels to average together
iy: current index y
Returns
weight calculated

Implements Mantid::Algorithms::WeightingStrategy.

Definition at line 73 of file WeightingStrategy.cpp.

◆ weightAt() [2/2]

double Mantid::Algorithms::LinearWeighting::weightAt ( const Mantid::Kernel::V3D distance)
overridevirtual

Calculate the weight at distance from epicenter.

Uses linear scaling based on distance from epicenter.

Parameters
distance: absolute distance from epicenter
Returns
weighting

Implements Mantid::Algorithms::WeightingStrategy.

Definition at line 63 of file WeightingStrategy.cpp.

References Mantid::Algorithms::WeightingStrategy::m_cutOff, and Mantid::Kernel::V3D::norm().


The documentation for this class was generated from the following files: