anaflow.tools.laplace.get_lap_inv
- get_lap_inv(func, method='stehfest', method_dict=None, arg_dict=None, **kwargs)[source]
Callable Laplace inversion.
Get the Laplace inversion of a given function as a callable function.
- Parameters
func (
callable
) – function in laplace-space that shall be inverted. The first argument needs to be the laplace-variable:func(s, **kwargs)
func should be capable of taking numpy arrays as input for s and the first shape component of the output of func should match the shape of s.
method (
str
) – Method that should be used to calculate the inverse. One can choose between"stehfest"
: for the stehfest algorithm
Default:
"stehfest"
method_dict (
dict
orNone
, optional) – Keyword arguments for the used method.arg_dict (
dict
orNone
, optional) – Keyword-arguments given as a dictionary that are forwarded to the function given infunc
. Will be merged with**kwargs
This is designed for overlapping keywords. Default:None
**kwargs – Keyword-arguments that are forwarded to the function given in
func
. Will be merged witharg_dict
.
- Returns
The Laplace inverse of the given function.
- Return type
- Raises
ValueError – If func is not callable.
ValueError – If method is unknown.