35 std::vector<std::string>
const& variables,
36 std::vector<std::string>
const& expression_strings,
38 std::unique_ptr<MathLib::PiecewiseLinearInterpolation>>
const&
57 std::span<double> result)
const;
71 std::vector<std::string>
const& variables,
72 bool spatial_position_is_required,
73 std::vector<std::string>
const& used_curve_names,
76 std::unique_ptr<MathLib::PiecewiseLinearInterpolation>>
const&
78 std::vector<std::string>
const& expression_strings);
std::vector< double > evaluate(SpatialPosition const &pos, double t) const
exprtk::symbol_table< double > SymbolTable
exprtk::expression< double > Expression
FunctionEvaluation(int num_threads, std::vector< std::string > const &variables, std::vector< std::string > const &expression_strings, std::map< std::string, std::unique_ptr< MathLib::PiecewiseLinearInterpolation > > const &curves)
int getNumberOfComponents() const
Number of components (number of compiled value expressions).
bool isTimeDependent() const
std::vector< PerThreadData > per_thread_data_
Per-thread evaluation context; indexed by omp_get_thread_num().
std::map< std::string, CurveWrapper > curve_wrappers
Curve wrappers owned by this thread; must outlive symbol_table.
PerThreadData(std::vector< std::string > const &variables, bool spatial_position_is_required, std::vector< std::string > const &used_curve_names, std::map< std::string, std::unique_ptr< MathLib::PiecewiseLinearInterpolation > > const &curves, std::vector< std::string > const &expression_strings)
SymbolTableCache symbol_table_cache
Cached pointers to t, x, y, z inside symbol_table.
PerThreadData(PerThreadData const &)=delete
std::vector< Expression > value_expressions
Compiled value expressions. Must be destroyed before symbol_table.
PerThreadData & operator=(PerThreadData const &)=delete
PerThreadData & operator=(PerThreadData &&other) noexcept=delete