Interpolation ​
Usage ​
Interpolation(interpolator=dataset_interpolation(interpolation_type, dataset))
Parameters: ​
| Name | Description | Units | Default value |
|---|---|---|---|
dataset | – | ||
interpolation_type | – | ||
interpolator | – | dataset_interpolation(interpolation_type, dataset) |
Connectors ​
u- This connector represents a real signal as an input to a component (RealInput)y- This connector represents a real signal as an output from a component (RealOutput)
Behavior ​
@example
using BlockComponents #hide
using BlockComponents: square #hide
using ModelingToolkit #hide
using DyadData #hide
using DataInterpolations #hide
dataset::DyadDataset = DyadDataset(hcat(0:0.1:1, square(0:0.1:1)), dependent_vars=["data"], independent_var="ts")
@named sys = Interpolation(interpolation_type=LinearInterpolation, dataset=dataset) #hide
full_equations(sys) #hideSource ​
dyad
component Interpolation
u = RealInput()
y = RealOutput()
structural parameter dataset::DyadDataset
structural parameter interpolation_type::Real
parameter interpolator::RealInterpolator = dataset_interpolation(interpolation_type, dataset)
relations
y = interpolator(u)
endFlattened Source
component Interpolation
u = RealInput()
y = RealOutput()
structural parameter dataset::DyadDataset
structural parameter interpolation_type::Real
parameter interpolator::RealInterpolator = dataset_interpolation(interpolation_type, dataset)
relations
y = interpolator(u)
metadata {}
end
Test Cases ​
Related ​
Examples
Experiments
Analyses
Tests