|
static double | angular_average (std::vector< double > &vec) |
| Calculates the average angle in radians from a vector of angles. More...
|
|
static int | ap_mean (double start, double stop, double *coords, double *val1, double *val2, int n, int *nstart, double *result1, double *result2) |
| Calculates average phase from start to stop using given coordinates and values. More...
|
|
static double | average (std::vector< double > &vec) |
| Calculates the average of values in a vector. More...
|
|
static void | DetermineChannelFrequencyLimits (double sky_freq, double bandwidth, std::string net_sideband, double &lower_freq, double &upper_freq) |
| Calculates lower and upper frequency limits for a given channel based on sky frequency, bandwidth, and net sideband. More...
|
|
static double | dwin (double value, double lower, double upper) |
| Clamps a value between lower and upper bounds. More...
|
|
template<typename XValueType > |
static int | FindIntersection (XValueType a, XValueType b, XValueType c, XValueType d, XValueType result[2]) |
| Function FindIntersection looks for overlap between the intervals [a,b) and [c,d) although if a,b and c,d are the end-points of an intervals we do not explicitly assume they are ordered there. More...
|
|
static int | linterp (double coord1, double value1, double coord2, double value2, double coord, double *value) |
| Performs linear interpolation between two points and returns the interpolated value. More...
|
|
static int | minvert3 (double a[3][3], double ainv[3][3]) |
| Calculates the inverse of a 3x3 matrix and stores it in ainv. More...
|
|
static int | parabola (double y[3], double lower, double upper, double *x_max, double *amp_max, double q[3]) |
| Calculates parabola parameters and maximum x, amplitude values within a range. More...
|
|
Class MHO_MathUtilities.
implements a variety of simple math functions copied from original hops3 c code with minimal changes along with some other simple helper functions
- Author
- J. Barrett - barre.nosp@m.ttj@.nosp@m.mit.e.nosp@m.du
- Date
- Tue Dec 5 17:01:15 2023 -0500
template<typename XValueType >
static int hops::MHO_MathUtilities::FindIntersection |
( |
XValueType |
a, |
|
|
XValueType |
b, |
|
|
XValueType |
c, |
|
|
XValueType |
d, |
|
|
XValueType |
result[2] |
|
) |
| |
|
inlinestatic |
Function FindIntersection looks for overlap between the intervals [a,b) and [c,d) although if a,b and c,d are the end-points of an intervals we do not explicitly assume they are ordered there.
- Template Parameters
-
XValueType | Template parameter XValueType |
- Parameters
-
a | (XValueType) |
b | (XValueType) |
c | (XValueType) |
d | (XValueType) |
result[2] | Parameter description |
- Returns
- Return value (int)
- Note
- This is a static function.