![]() |
Rosetta
3.8
|
Namespaces | |
| periodic_range | |
| spline | |
Classes | |
| class | Histogram |
| A histogram with fixed-width bins. More... | |
| struct | HistogramAP |
| struct | HistogramCAP |
| struct | HistogramCOP |
| struct | HistogramOP |
| class | InterpolatedPotential |
Functions | |
| template<Size N> | |
| void | polycubic_interpolation (numeric::interpolation::InterpolatedPotential< N > const &interpolated_potential, utility::fixedsizearray1< Real, N > const &values, Real &score, utility::fixedsizearray1< Real, N > &dscoreddof) |
| template<typename X , typename F > | |
| F | interpolated (X const &x, X const &x1, X const &x2, F const &f1, F const &f2) |
| Linearly interpolated value: f( x ) More... | |
| template<typename X , typename F > | |
| F | interpolated (X const &a, F const &f1, F const &f2) |
| Linearly interpolated value: f( x ) More... | |
| template<typename X , typename F > | |
| F | interpolated_delta (X const &a, F const &f1, F const &f2) |
| Linearly interpolated delta value: f( x ) - f1. More... | |
| template<typename X , typename Y , typename F > | |
| F | bilinearly_interpolated (X const &x, X const &x1, X const &x2, Y const &y, Y const &y1, Y const &y2, F const &f11, F const &f12, F const &f21, F const &f22) |
| Bilinearly interpolated value: f( x, y ) More... | |
| template<typename X , typename Y , typename F > | |
| F | bilinearly_interpolated (X const &ax, Y const &ay, F const &f11, F const &f12, F const &f21, F const &f22) |
| Bilinearly interpolated value. More... | |
| template<typename X , typename Y , typename F > | |
| F | bilinearly_interpolated (X const &ax, Y const &ay, X const &bx, Y const &by, F const &f11, F const &f12, F const &f21, F const &f22) |
| Bilinearly interpolated value. More... | |
| template<typename T , numeric::Size N> | |
| Real | multilinear_interpolation (MathNTensor< T, N > const &tensor, utility::fixedsizearray1< Real, N > const &minval, utility::fixedsizearray1< Real, N > const &binwidth, utility::fixedsizearray1< Real, N > const &xs, utility::fixedsizearray1< Real, N > &deriv, bool const compute_deriv=true) |
| Perform multilinear interpolation over an N-dimensional tensor, with derivatives. More... | |
| template<typename T , numeric::Size N> | |
| numeric::Real | multilinear_interpolation (numeric::MathNTensor< T, N > const &tensor, utility::fixedsizearray1< numeric::Real, N > const &minval, utility::fixedsizearray1< numeric::Real, N > const &binwidth, utility::fixedsizearray1< numeric::Real, N > const &xs) |
| Perform multilinear interpolation over an N-dimensional tensor. More... | |
| template<Size N> | |
| void | polycubic_interpolation (utility::fixedsizearray1< utility::fixedsizearray1< Real,(1<< N) >,(1<< N) > n_derivs, utility::fixedsizearray1< Real, N > dbbp, utility::fixedsizearray1< Real, N > binwbb, Real &val, utility::fixedsizearray1< Real, N > &dvaldbb) |
| Perform cubic interpolation over each of N axes, using the 2^N derivatives at 2^N gridpoints. More... | |
| spline::SplineGenerator | spline_from_file (std::string const &filename, platform::Real const &bin_size) |
| given a file, return a 2D spline More... | |
|
inline |
Bilinearly interpolated value: f( x, y )
References ObjexxFCL::format::X().
|
inline |
Bilinearly interpolated value.
References ObjexxFCL::format::X().
|
inline |
Bilinearly interpolated value.
References numeric::eq_tol(), and ObjexxFCL::format::X().
|
inline |
Linearly interpolated value: f( x )
References ObjexxFCL::format::X().
Referenced by numeric::interpolation::Histogram< typename, typename >::interpolate_linear(), numeric::interpolation::periodic_range::half::interpolated(), and numeric::interpolation::periodic_range::full::interpolated().
|
inline |
Linearly interpolated value: f( x )
|
inline |
Linearly interpolated delta value: f( x ) - f1.
| Real numeric::interpolation::multilinear_interpolation | ( | MathNTensor< T, N > const & | tensor, |
| utility::fixedsizearray1< Real, N > const & | minval, | ||
| utility::fixedsizearray1< Real, N > const & | binwidth, | ||
| utility::fixedsizearray1< Real, N > const & | xs, | ||
| utility::fixedsizearray1< Real, N > & | deriv, | ||
| bool const | compute_deriv = true |
||
| ) |
Perform multilinear interpolation over an N-dimensional tensor, with derivatives.
Straightforward generalization of bilinear interpolation. Currently extrapolates linearly when asked for point outside tensor range TODO: allow periodic; allow different extrapolation behavior (e.g., constant).
| [in] | tensor | is the data array, using MathNTensor |
| [in] | minval | is the tensor's minimum value in each direction. |
| [in] | binwidth | is the bin width in each direction |
| [out] | deriv | is the interpolated derivative |
| [in] | compute_deriv | – set to false to reduce computation |
References basic::options::OptionKeys::score::fiber_diffraction::a, numeric::interpolation::periodic_range::half::bin(), max(), min(), numeric::MathNTensor< T, N >::n_bins(), and basic::options::OptionKeys::rna::farna::offset.
Referenced by multilinear_interpolation().
| numeric::Real numeric::interpolation::multilinear_interpolation | ( | numeric::MathNTensor< T, N > const & | tensor, |
| utility::fixedsizearray1< numeric::Real, N > const & | minval, | ||
| utility::fixedsizearray1< numeric::Real, N > const & | binwidth, | ||
| utility::fixedsizearray1< numeric::Real, N > const & | xs | ||
| ) |
Perform multilinear interpolation over an N-dimensional tensor.
Straightforward generalization of bilinear interpolation. Currently extrapolates linearly when asked for point outside tensor range TODO: allow periodic; allow different extrapolation behavior (e.g., constant).
| [in] | tensor | is the data array, using MathNTensor |
| [in] | minval | is the tensor's minimum value in each direction. |
| [in] | binwidth | is the bin width in each direction |
References multilinear_interpolation().
| void numeric::interpolation::polycubic_interpolation | ( | numeric::interpolation::InterpolatedPotential< N > const & | interpolated_potential, |
| utility::fixedsizearray1< Real, N > const & | values, | ||
| Real & | score, | ||
| utility::fixedsizearray1< Real, N > & | dscoreddof | ||
| ) |
References numeric::interpolation::InterpolatedPotential< N >::axis_range(), numeric::interpolation::InterpolatedPotential< N >::bin_width(), numeric::interpolation::InterpolatedPotential< N >::get_indices(), numeric::interpolation::InterpolatedPotential< N >::grid_size(), test.T200_Scoring::ii, and erraser_single_res_analysis::score.
| void numeric::interpolation::polycubic_interpolation | ( | utility::fixedsizearray1< utility::fixedsizearray1< Real,(1<< N) >,(1<< N) > | n_derivs, |
| utility::fixedsizearray1< Real, N > | dbbp, | ||
| utility::fixedsizearray1< Real, N > | binwbb, | ||
| Real & | val, | ||
| utility::fixedsizearray1< Real, N > & | dvaldbb | ||
| ) |
Perform cubic interpolation over each of N axes, using the 2^N derivatives at 2^N gridpoints.
The way encoding gridpoints and derivatives into a linear structure like this is actually pretty simple. Imagine the "right or left" part of a cube, or the "derivative taken or not" on a particular variable, as zero or one. Then "just the actual function value" maps to 000, the z derivative (for example) maps to 001, d2/dydz maps to 011, etc.
| [in] | n_derivs | is a 2^N x 2^N matrix: 2^N derivatives at 2^N gridpoints |
| [in] | dbbp | is how far along the bin our target point is, in each direction |
| [in] | binwbb | is the bin width in each direction |
| [out] | val | is the interpolated value |
| [out] | dvaldbb | are the interpolated derivatives |
References test.T200_Scoring::ii.
| spline::SplineGenerator numeric::interpolation::spline_from_file | ( | std::string const & | filename, |
| platform::Real const & | bin_size | ||
| ) |
given a file, return a 2D spline
read in a file, read out a spline. The file should be tab separated, and have two lines The first field of one line should be "x_axis", the next fields should be the x values of the points for the spline The first field of the other line should be "y_axis", the next fields should be the y values for the points on the spline For an example, see "scoring/constraints/epr_distance_potential.histogram"
References numeric::interpolation::spline::SplineGenerator::add_boundary_function(), numeric::interpolation::spline::SplineGenerator::add_known_value(), utility::io::izstream::close(), clean_pdb_keep_ligand::count, basic::options::OptionKeys::cp::cutoff, utility::from_string(), ObjexxFCL::getline(), ObjexxFCL::index(), line, utility::io::izstream::open(), utility::string_split(), tag, ObjexxFCL::trim(), and utility_exit_with_message.
1.8.7