Impala
Impalaistheopensource,nativeanalyticdatabaseforApacheHadoop.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
math-functions.cc File Reference
#include "exprs/math-functions.h"
#include <iomanip>
#include <sstream>
#include <math.h>
#include "exprs/anyval-util.h"
#include "exprs/expr.h"
#include "exprs/operators.h"
#include "util/string-parser.h"
#include "common/names.h"
Include dependency graph for math-functions.cc:

Go to the source code of this file.

Namespaces

 impala
 This file contains type definitions that are used throughout the code base.
 

Macros

#define ONE_ARG_MATH_FN(NAME, RET_TYPE, INPUT_TYPE, FN)
 

Functions

 impala::ONE_ARG_MATH_FN (Abs, BigIntVal, BigIntVal, llabs)
 
 impala::ONE_ARG_MATH_FN (Abs, DoubleVal, DoubleVal, fabs)
 
 impala::ONE_ARG_MATH_FN (Abs, FloatVal, FloatVal, fabs)
 
 impala::ONE_ARG_MATH_FN (Abs, IntVal, IntVal, abs)
 
 impala::ONE_ARG_MATH_FN (Abs, SmallIntVal, SmallIntVal, abs)
 
 impala::ONE_ARG_MATH_FN (Abs, TinyIntVal, TinyIntVal, abs)
 
 impala::ONE_ARG_MATH_FN (Sin, DoubleVal, DoubleVal, sin)
 
 impala::ONE_ARG_MATH_FN (Asin, DoubleVal, DoubleVal, asin)
 
 impala::ONE_ARG_MATH_FN (Cos, DoubleVal, DoubleVal, cos)
 
 impala::ONE_ARG_MATH_FN (Acos, DoubleVal, DoubleVal, acos)
 
 impala::ONE_ARG_MATH_FN (Tan, DoubleVal, DoubleVal, tan)
 
 impala::ONE_ARG_MATH_FN (Atan, DoubleVal, DoubleVal, atan)
 
 impala::ONE_ARG_MATH_FN (Sqrt, DoubleVal, DoubleVal, sqrt)
 
 impala::ONE_ARG_MATH_FN (Ceil, BigIntVal, DoubleVal, ceil)
 
 impala::ONE_ARG_MATH_FN (Floor, BigIntVal, DoubleVal, floor)
 
 impala::ONE_ARG_MATH_FN (Ln, DoubleVal, DoubleVal, log)
 
 impala::ONE_ARG_MATH_FN (Log10, DoubleVal, DoubleVal, log10)
 
 impala::ONE_ARG_MATH_FN (Exp, DoubleVal, DoubleVal, exp)
 

Macro Definition Documentation

#define ONE_ARG_MATH_FN (   NAME,
  RET_TYPE,
  INPUT_TYPE,
  FN 
)
Value:
RET_TYPE MathFunctions::NAME(FunctionContext* ctx, const INPUT_TYPE& v) { \
if (v.is_null) return RET_TYPE::null(); \
return RET_TYPE(FN(v.val)); \
}

Definition at line 47 of file math-functions.cc.