Autonomy Software C++ 24.5.1
Welcome to the Autonomy Software repository of the Mars Rover Design Team (MRDT) at Missouri University of Science and Technology (Missouri S&T)! API reference contains the source code and other resources for the development of the autonomy software for our Mars rover. The Autonomy Software project aims to compete in the University Rover Challenge (URC) by demonstrating advanced autonomous capabilities and robust navigation algorithms.
Loading...
Searching...
No Matches
duckdb::InterpolateOperator Struct Reference

Public Member Functions

template<>
double Operation (const double &lo, const double d, const double &hi)
template<>
dtime_t Operation (const dtime_t &lo, const double d, const dtime_t &hi)
template<>
timestamp_t Operation (const timestamp_t &lo, const double d, const timestamp_t &hi)
template<>
hugeint_t Operation (const hugeint_t &lo, const double d, const hugeint_t &hi)
template<>
uhugeint_t Operation (const uhugeint_t &lo, const double d, const uhugeint_t &hi)
template<>
interval_t Operation (const interval_t &lo, const double d, const interval_t &hi)
template<>
double Operation (const double &lo, const double d, const double &hi)
template<>
dtime_t Operation (const dtime_t &lo, const double d, const dtime_t &hi)
template<>
timestamp_t Operation (const timestamp_t &lo, const double d, const timestamp_t &hi)
template<>
hugeint_t Operation (const hugeint_t &lo, const double d, const hugeint_t &hi)
template<>
uhugeint_t Operation (const uhugeint_t &lo, const double d, const uhugeint_t &hi)
template<>
interval_t Operation (const interval_t &lo, const double d, const interval_t &hi)

Static Public Member Functions

template<typename TARGET_TYPE>
static TARGET_TYPE Operation (const TARGET_TYPE &lo, const double d, const TARGET_TYPE &hi)

Member Function Documentation

◆ Operation() [1/7]

template<typename TARGET_TYPE>
TARGET_TYPE duckdb::InterpolateOperator::Operation ( const TARGET_TYPE & lo,
const double d,
const TARGET_TYPE & hi )
inlinestatic
228058 {
228059 const auto delta = static_cast<double>(hi - lo);
228060 return LossyNumericCast<TARGET_TYPE>(lo + static_cast<TARGET_TYPE>(delta * d));
228061 }

◆ Operation() [2/7]

template<>
double duckdb::InterpolateOperator::Operation ( const double & lo,
const double d,
const double & hi )
229359 {
229360 return lo * (1.0 - d) + hi * d;
229361}

◆ Operation() [3/7]

template<>
dtime_t duckdb::InterpolateOperator::Operation ( const dtime_t & lo,
const double d,
const dtime_t & hi )
229364 {
229365 return dtime_t(std::llround(static_cast<double>(lo.micros) * (1.0 - d) + static_cast<double>(hi.micros) * d));
229366}

◆ Operation() [4/7]

template<>
timestamp_t duckdb::InterpolateOperator::Operation ( const timestamp_t & lo,
const double d,
const timestamp_t & hi )
229369 {
229370 return timestamp_t(std::llround(static_cast<double>(lo.value) * (1.0 - d) + static_cast<double>(hi.value) * d));
229371}

◆ Operation() [5/7]

template<>
hugeint_t duckdb::InterpolateOperator::Operation ( const hugeint_t & lo,
const double d,
const hugeint_t & hi )
229374 {
229375 return Hugeint::Convert(Operation(Hugeint::Cast<double>(lo), d, Hugeint::Cast<double>(hi)));
229376}

◆ Operation() [6/7]

template<>
uhugeint_t duckdb::InterpolateOperator::Operation ( const uhugeint_t & lo,
const double d,
const uhugeint_t & hi )
229379 {
229380 return Uhugeint::Convert(Operation(Uhugeint::Cast<double>(lo), d, Uhugeint::Cast<double>(hi)));
229381}

◆ Operation() [7/7]

template<>
interval_t duckdb::InterpolateOperator::Operation ( const interval_t & lo,
const double d,
const interval_t & hi )
229397 {
229398 const interval_t delta = hi - lo;
229399 return lo + MultiplyByDouble(delta, d);
229400}

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