fisx: fisx::Beam Class Reference

fisx

Public Member Functions | Friends | List of all members
fisx::Beam Class Reference

Class describing an X-ray beam. More...

`#include <fisx_beam.h>`

## Public Member Functions
void | setBeam (const std::vector< double > &energy, const std::vector< double > &weight=std::vector< double >(), const std::vector< int > &characteristic=std::vector< int >(), const std::vector< double > &divergency=std::vector< double >())
void | setBeam (const int &nValues, const double *energy, const double *weight=NULL, const int *characteristic=NULL, const double *divergency=NULL)
void | setBeam (const int &nValues, const double *energy, const double *weight=NULL, const double *characteristic=NULL, const double *divergency=NULL)
void | setBeam (const double &energy, const double divergency=0.0)
const std::vector< Ray > & | getBeam ()
std::vector< std::vector< double > > | getBeamAsDoubleVectors () const

## Friends
std::ostream & | operator<< (std::ostream &o, Beam const &beam)

## Detailed Description

Class describing an X-ray beam.

At this point a beam is described by a set of energies and weights. The characteristic flag just indicates if it is an energy to be considered for calculation of scattering peaks.

## Member Function Documentation

## § getBeam()

const std::vector< Ray > & fisx::Beam::getBeam | ( |  | ) |

Returns a constant reference to the internal beam.

## § getBeamAsDoubleVectors()

std::vector< std::vector< double > > fisx::Beam::getBeamAsDoubleVectors | ( |  | ) | const

Currently it returns a vector of "elements" in which each element is a vector of doubles with length equal to the number of energies. The first four elements are warranteed to exist and they are: [energy0, energy1, energy2, ...] [weight0, weight1, weight2, ...] [characteristic0, characteristic1, charactersitic2, ...] [divergency0, divergency1, divergency2, ...]

## § setBeam() [1/2]

void fisx::Beam::setBeam | ( | const std::vector< double > & | energy,
|  | const std::vector< double > & | weight = `std::vector<double>()`,
|  | const std::vector< int > & | characteristic = `std::vector<int>()`,
|  | const std::vector< double > & | divergency = `std::vector<double>()`
| ) |  |

Minimalist constructor.

Beam description given as vectors. The beam is always internally ordered.

## § setBeam() [2/2]

void fisx::Beam::setBeam | ( | const int & | nValues,
|  | const double * | energy,
|  | const double * | weight = `NULL`,
|  | const int * | characteristic = `NULL`,
|  | const double * | divergency = `NULL`
| ) |  |

Easy to wrap interface functions Except for the energy, you can use NULL pointers to use default values.

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

- fisx_beam.h
- fisx_beam.cpp