HermesCommon  3.0
Hermes::Hermes3DFunction< Scalar > Class Template Reference

`#include <hermes_function.h>`

Inheritance diagram for Hermes::Hermes3DFunction< Scalar >:

## Public Member Functions

Hermes3DFunction ()
Constructor.

Hermes3DFunction (Scalar value)
Constructor for the constant case.

virtual Scalar value (Scalar x, Scalar y, Scalar z) const
Two-dimensional function value.

virtual Hermes::Ord value (Hermes::Ord x, Hermes::Ord y, Hermes::Ord z) const
Two-dimensional function integration order.

virtual Scalar derivative_x (Scalar x, Scalar y, Scalar z) const
Two-dimensional function derivative value.

virtual Scalar derivative_y (Scalar x, Scalar y, Scalar z) const

virtual Scalar derivative_z (Scalar x, Scalar y, Scalar z) const

virtual Hermes::Ord derivative_x (Hermes::Ord x, Hermes::Ord y, Hermes::Ord z) const
Two-dimensional function derivative integration order.

virtual Hermes::Ord derivative_y (Hermes::Ord x, Hermes::Ord y, Hermes::Ord z) const

virtual Hermes::Ord derivative_z (Hermes::Ord x, Hermes::Ord y, Hermes::Ord z) const

bool is_constant () const

template<>
double value (double x, double y, double z) const

template<>
std::complex< double > value (std::complex< double > x, std::complex< double > y, std::complex< double > z) const

template<>
double derivative_x (double x, double y, double z) const

template<>
std::complex< double > derivative_x (std::complex< double > x, std::complex< double > y, std::complex< double > z) const

template<>
double derivative_y (double x, double y, double z) const

template<>
std::complex< double > derivative_y (std::complex< double > x, std::complex< double > y, std::complex< double > z) const

template<>
double derivative_z (double x, double y, double z) const

template<>
std::complex< double > derivative_z (std::complex< double > x, std::complex< double > y, std::complex< double > z) const

Public Member Functions inherited from Hermes::Mixins::Loggable
Loggable (bool verbose_output=false, callbackFn verbose_callback=NULL, bool add_newline=true)

void set_file_output_only (bool onOff)

void set_timestamps (bool onOff)
Sets the addition of a time stamp on each line in the log file. By default it is on.

void set_erase_on_beginning (bool onOff)
Sets the logFile being always erased before logging.

void set_logFile_name (const char *filename)

void set_logFile_name (std::string filename)

void info (const char *msg,...) const

void info_if (bool cond, const char *msg,...) const

void warn (const char *msg,...) const

void warn_if (bool cond, const char *msg,...) const

void error (const char *msg,...) const

void error_if (bool cond, const char *msg,...) const

virtual void set_verbose_output (bool to_set)

bool get_verbose_output () const
Returns the current value of verbose_output;.

virtual void set_verbose_callback (callbackFn callback)

callbackFn get_verbose_callback () const
Returns the current value of verbose_callback;.

## Protected Attributes

bool is_const
The function is constant.

Scalar const_value
If the function is constant, this is the value.

Static Public Member Functions inherited from Hermes::Mixins::Loggable
static void set_static_logFile_name (const char *filename)

static void set_static_logFile_name (std::string filename)

Public Attributes inherited from Hermes::Mixins::Loggable
char * logFileName
Logfile name.

Static Public Attributes inherited from Hermes::Mixins::Loggable
static char * staticLogFileName = nullptr

Protected Member Functions inherited from Hermes::Mixins::Loggable
void hermes_fwrite (const void *ptr, size_t size, size_t nitems, FILE *stream) const

void hermes_fread (void *ptr, size_t size, size_t nitems, FILE *stream) const

## Detailed Description

### template<typename Scalar> class Hermes::Hermes3DFunction< Scalar >

Generic class for functions of three variables. Typical usage: user creates a descendant: class MyReal3DSum : public Hermes3DFunction<double> {  /// Constructor.  MyReal3DSum() : Hermes3DFunction<double>() {}  virtual double value(double x, double y, double z) const { return x + y + z; }  .... }

Definition at line 130 of file hermes_function.h.

## Member Function Documentation

template<typename Scalar >
 bool Hermes::Hermes3DFunction< Scalar >::is_constant ( ) const

The function is constant. Returns the value of is_const.

Definition at line 33 of file hermes_function.cpp.

The documentation for this class was generated from the following files: