BornAgain  1.19.79
Open-source research software to simulate and fit neutron and x-ray reflectometry and grazing-incidence small-angle scattering
ConstKBinAxis Class Reference

Description

Axis with fixed bin size in sin(angle) space.

Inheritance diagram for ConstKBinAxis:

Public Member Functions

 ConstKBinAxis (const std::string &name, size_t nbins, double start, double end)
 ConstKBinAxis constructor. More...
 
 ~ConstKBinAxis () override=default
 
Bin1D bin (size_t index) const override
 
std::vector< double > binBoundaries () const override
 
double binCenter (size_t index) const override
 
std::vector< double > binCenters () const override
 
void clip (double lower, double upper) override
 
ConstKBinAxisclone () const override
 
size_t findClosestIndex (double value) const override
 
double max () const override
 
double min () const override
 
double operator[] (size_t index) const override
 
size_t size () const override
 

Protected Member Functions

 ConstKBinAxis (const std::string &name, size_t nbins)
 
bool equals (const IAxis &other) const override
 
void print (std::ostream &ostr) const override
 
void setBinBoundaries (const std::vector< double > &bin_boundaries)
 

Protected Attributes

double m_end
 
size_t m_nbins
 
double m_start
 

Constructor & Destructor Documentation

◆ ConstKBinAxis() [1/2]

ConstKBinAxis::ConstKBinAxis ( const std::string &  name,
size_t  nbins,
double  start,
double  end 
)

ConstKBinAxis constructor.

Parameters
nameAxis name
nbinsnumber of bins
startlow edge of first bin
endupper edge of last bin

◆ ~ConstKBinAxis()

ConstKBinAxis::~ConstKBinAxis ( )
overridedefault

◆ ConstKBinAxis() [2/2]

ConstKBinAxis::ConstKBinAxis ( const std::string &  name,
size_t  nbins 
)
protected

Member Function Documentation

◆ bin()

Bin1D VariableBinAxis::bin ( size_t  index) const
overrideinherited

◆ binBoundaries()

std::vector<double> VariableBinAxis::binBoundaries ( ) const
overrideinherited

◆ binCenter()

double VariableBinAxis::binCenter ( size_t  index) const
overrideinherited

◆ binCenters()

std::vector<double> VariableBinAxis::binCenters ( ) const
overrideinherited

◆ clip()

void ConstKBinAxis::clip ( double  lower,
double  upper 
)
override

◆ clone()

ConstKBinAxis* ConstKBinAxis::clone ( ) const
override

◆ equals()

bool ConstKBinAxis::equals ( const IAxis &  other) const
overrideprotected

◆ findClosestIndex()

size_t VariableBinAxis::findClosestIndex ( double  value) const
overrideinherited

◆ max()

double VariableBinAxis::max ( ) const
overrideinherited

◆ min()

double VariableBinAxis::min ( ) const
overrideinherited

◆ operator[]()

double VariableBinAxis::operator[] ( size_t  index) const
overrideinherited

◆ print()

void ConstKBinAxis::print ( std::ostream &  ostr) const
overrideprotected

◆ setBinBoundaries()

void VariableBinAxis::setBinBoundaries ( const std::vector< double > &  bin_boundaries)
protectedinherited

◆ size()

size_t VariableBinAxis::size ( ) const
overrideinherited

Member Data Documentation

◆ m_end

double ConstKBinAxis::m_end
protected

◆ m_nbins

size_t VariableBinAxis::m_nbins
protectedinherited

◆ m_start

double ConstKBinAxis::m_start
protected