FuncSketch
Loading...
Searching...
No Matches
general_math_function.h File Reference

Definition of GeneralMathFunction class. More...

#include <concepts>
#include <string>
#include <string_view>
#include <tuple>
#include <utility>
#include <variant>
#include <vector>
#include <fmt/base.h>
#include <fmt/format.h>
#include "func_sketch/common_types.h"
#include "func_sketch/exceptions.h"
#include "func_sketch/math/acceptable_types.h"
#include "func_sketch/math/number_type_name.h"
Include dependency graph for general_math_function.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  func_sketch::math::GeneralMathFunction< FunctionType, AcceptableTypesPerArgument >
 Class of general implementation of mathematical functions. More...
struct  func_sketch::math::details::IsAcceptableTypesTuple< Type >
 Check whether a type is a tuple of func_sketch::math::AcceptableTypes. More...
struct  func_sketch::math::details::IsAcceptableTypesTuple< std::tuple< Types... > >
 Check whether a type is a tuple of func_sketch::math::AcceptableTypes. More...

Concepts

concept  func_sketch::math::details::AcceptableTypesTupleType
 Concept to check whether a type is a tuple of func_sketch::math::AcceptableTypes.

Functions

template<details::AcceptableTypesTupleType AcceptableTypesTuple, typename FunctionType, std::size_t... Indices>
auto func_sketch::math::details::make_general_math_function_impl (std::string name, FunctionType &&function, std::index_sequence< Indices... >)
 Make a general mathematical function.
template<details::AcceptableTypesTupleType AcceptableTypesTuple, typename FunctionType>
auto func_sketch::math::make_general_math_function (std::string name, FunctionType &&function)
 Make a general mathematical function.

Detailed Description

Definition of GeneralMathFunction class.

Definition in file general_math_function.h.

Function Documentation

◆ make_general_math_function_impl()

template<details::AcceptableTypesTupleType AcceptableTypesTuple, typename FunctionType, std::size_t... Indices>
auto func_sketch::math::details::make_general_math_function_impl ( std::string name,
FunctionType && function,
std::index_sequence< Indices... >  )
nodiscard

Make a general mathematical function.

Template Parameters
AcceptableTypesTupleTuple of func_sketch::math::AcceptableTypes types for each argument.
FunctionTypeType of the function object to compute numbers.
IndicesIndices of arguments.
Parameters
[in]nameName of the function.
[in]functionFunction object to compute numbers.
Returns
Created general mathematical function.

Definition at line 239 of file general_math_function.h.

◆ make_general_math_function()

template<details::AcceptableTypesTupleType AcceptableTypesTuple, typename FunctionType>
auto func_sketch::math::make_general_math_function ( std::string name,
FunctionType && function )
nodiscard

Make a general mathematical function.

Template Parameters
AcceptableTypesTupleTuple of func_sketch::math::AcceptableTypes types for each argument.
FunctionTypeType of the function object to compute numbers.
Parameters
[in]nameName of the function.
[in]functionFunction object to compute numbers.
Returns
Created general mathematical function.

Definition at line 260 of file general_math_function.h.