1 #ifndef POINCARE_COSINE_H 2 #define POINCARE_COSINE_H 16 Type
type()
const override;
25 int writeTextInBuffer(
char * buffer,
int bufferSize,
int numberOfSignificantDigits = PrintFloat::k_numberOfStoredSignificantDigits)
const override {
28 const char * name()
const {
return "cos"; }
30 Expression * shallowReduce(Context& context, AngleUnit angleUnit)
override;
32 Expression * privateApproximate(SinglePrecision p, Context& context, AngleUnit angleUnit)
const override {
33 return ApproximationEngine::map<float>(
this, context, angleUnit,computeOnComplex<float>);
35 Expression * privateApproximate(DoublePrecision p, Context& context, AngleUnit angleUnit)
const override {
36 return ApproximationEngine::map<double>(
this, context, angleUnit, computeOnComplex<double>);
Expression * clone() const override
constexpr Poincare::Expression::AngleUnit Radian
static ExpressionLayout * createPrefixLayout(const Expression *expression, PrintFloat::Mode floatDisplayMode, Expression::ComplexFormat complexFormat, const char *operatorName)
Type type() const override
static Complex< T > computeOnComplex(const Complex< T > c, AngleUnit angleUnit=AngleUnit::Radian)
static int writePrefixExpressionTextInBuffer(const Expression *expression, char *buffer, int bufferSize, int numberOfDigits, const char *operatorName)
float characteristicXRange(Context &context, AngleUnit angleUnit=AngleUnit::Default) const override