LHAPDF is hosted by Hepforge, IPPP Durham
LHAPDF  6.2.1
LHAPDF::KnotArray1F Class Reference

Internal storage class for PDF data point grids. More...

#include <KnotArray.h>

Public Member Functions

Construction etc.
 KnotArray1F ()
 Default constructor just for std::map insertability.
 
 KnotArray1F (const std::vector< double > &xknots, const std::vector< double > &q2knots, const std::vector< double > &xfs)
 Constructor from x and Q2 knot values, and an xf value grid as strided list.
 
 KnotArray1F (const std::vector< double > &xknots, const std::vector< double > &q2knots)
 Constructor of a zero-valued array from x and Q2 knot values.
 
x stuff
void setxs (const std::vector< double > &xs)
 
const size_t xsize () const
 Number of x knots.
 
const std::vector< double > & xs () const
 x knot accessor
 
const std::vector< double > & logxs () const
 log(x) knot accessor
 
size_t ixbelow (double x) const
 Get the index of the closest x knot row <= x. More...
 
Q2 stuff
void setq2s (const std::vector< double > &q2s)
 
const size_t q2size () const
 Number of Q2 knots.
 
const std::vector< double > & q2s () const
 Q2 knot accessor.
 
const std::vector< double > & logq2s () const
 log(Q2) knot accessor
 
size_t iq2below (double q2) const
 
PDF values at (x, Q2) points
const size_t size () const
 Number of x knots.
 
const std::vector< double > & xfs () const
 xf value accessor (const)
 
std::vector< double > & xfs ()
 xf value accessor (non-const)
 
void setxfs (const std::vector< double > &xfs)
 xf value setter
 
const double & xf (size_t ix, size_t iq2) const
 Get the xf value at a particular indexed x,Q2 knot.
 

Private Member Functions

void _synclogs ()
 Synchronise log(x) and log(Q2) arrays from the x and Q2 ones.
 

Private Attributes

std::vector< double > _xs
 List of x knots.
 
std::vector< double > _q2s
 List of Q2 knots.
 
std::vector< double > _logxs
 List of log(x) knots.
 
std::vector< double > _logq2s
 List of log(Q2) knots.
 
std::vector< double > _xfs
 List of xf values across the 2D knot array, stored as a strided [ix][iQ2] 1D array.
 

Detailed Description

Internal storage class for PDF data point grids.

We use "array" to refer to the "raw" knot grid, while "grid" means a grid-based PDF. The "1F" means that this is a single-flavour array

Member Function Documentation

◆ iq2below()

size_t LHAPDF::KnotArray1F::iq2below ( double  q2) const
inline

Get the index of the closest Q2 knot row <= q2

If the value is >= q2_max, return i_max-1 (for polynomial spine construction)

Find the closest knot below the requested value

◆ ixbelow()

size_t LHAPDF::KnotArray1F::ixbelow ( double  x) const
inline

Get the index of the closest x knot row <= x.

If the value is >= x_max, return i_max-1 (for polynomial spine construction)

◆ setq2s()

void LHAPDF::KnotArray1F::setq2s ( const std::vector< double > &  q2s)
inline

Q2 knot setter

Note
Also zeros the xfs array, which is invalidated by resetting the Q2 knots

◆ setxs()

void LHAPDF::KnotArray1F::setxs ( const std::vector< double > &  xs)
inline

x knot setter

Note
Also zeros the xfs array, which is invalidated by resetting the x knots

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