|
742 | 742 | interpolation_type::UnionAll, u::AbstractArray, x::AbstractArray, args::Tuple)
|
743 | 743 | build_interpolation(interpolation_type, u, x, args) = interpolation_type(u, x, args...)
|
744 | 744 |
|
| 745 | +""" |
| 746 | + ParametrizedInterpolation(interp_type, u, x, args...; name) |
| 747 | +
|
| 748 | +Represent function interpolation symbolically as a block component. By default interpolation types |
| 749 | +from [`DataInterpolations.jl`](https://github.com/SciML/DataInterpolations.jl) are supported. |
| 750 | +# Arguments: |
| 751 | + - `interp_type`: the type of the interpolation. For `DataInterpolations`, |
| 752 | +these would be any of [the available interpolations](https://github.com/SciML/DataInterpolations.jl?tab=readme-ov-file#available-interpolations), |
| 753 | +such as `LinearInterpolation`, `ConstantInterpolation` or `CubicSpline`. |
| 754 | + - `u`: the data used for interpolation. For `DataInterpolations` this will be an `AbstractVector` |
| 755 | + - `x`: the values that each data points correspond to, usually the times corresponding to each value in `u`. |
| 756 | + - `args`: any other arguments beeded to build the interpolation |
| 757 | +
|
| 758 | +# Parameters: |
| 759 | + - `data`: the symbolic representation of the data passed at construction time via `u`. |
| 760 | + - `ts`: the symbolic representation of times corresponding to the data passed at construction time via `x`. |
| 761 | +
|
| 762 | +# Connectors: |
| 763 | + - `output`: a [`RealOutput`](@ref) connector corresponding to the interpolated value |
| 764 | +""" |
745 | 765 | function ParametrizedInterpolation(interp_type::T, u, x, args...; name) where {T}
|
746 | 766 | @parameters data[1:length(x)] = u
|
747 | 767 | @parameters ts[1:length(x)] = x
|
|
0 commit comments