From b81b883654d738beeb2a0bc59d21c66c0c94fc0e Mon Sep 17 00:00:00 2001 From: "G. D. McBain" Date: Thu, 25 Jan 2024 15:22:55 +1100 Subject: [PATCH 1/3] name TimeVaryingFunction; fixes #253 --- docs/src/tutorials/input_component.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/src/tutorials/input_component.md b/docs/src/tutorials/input_component.md index 7347c1213..a66a1b942 100644 --- a/docs/src/tutorials/input_component.md +++ b/docs/src/tutorials/input_component.md @@ -22,7 +22,7 @@ using OrdinaryDiffEq D = Differential(t) function System(f; name) - src = TimeVaryingFunction(f) + @named src = TimeVaryingFunction(f) vars = @variables f(t)=0 x(t)=0 dx(t)=0 ddx(t)=0 pars = @parameters m=10 k=1000 d=1 From d981e93cd1a065e5de9d25e7128faff789d8be5a Mon Sep 17 00:00:00 2001 From: "G. D. McBain" Date: Thu, 25 Jan 2024 15:36:31 +1100 Subject: [PATCH 2/3] DOC: grammar typo --- docs/src/tutorials/input_component.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/src/tutorials/input_component.md b/docs/src/tutorials/input_component.md index a66a1b942..404bb2c20 100644 --- a/docs/src/tutorials/input_component.md +++ b/docs/src/tutorials/input_component.md @@ -105,7 +105,7 @@ Additional code could be added to resolve this issue, for example by using a `Re ## `SampledData` Component -To resolve the issues presented above, the `ModelingToolkitStandardLibrary.Blocks.SampledData` component can be used which allows for a resusable `ODESystem` and self contained data which ensures a solution which remains valid for it's lifetime. Now it's possible to also parallelize the call to `solve()`. +To resolve the issues presented above, the `ModelingToolkitStandardLibrary.Blocks.SampledData` component can be used which allows for a resusable `ODESystem` and self contained data which ensures a solution which remains valid for its lifetime. Now it's possible to also parallelize the call to `solve()`. ```julia function System(; name) From 4da51533f4e875275414dd45a4e785a1fb60fd7c Mon Sep 17 00:00:00 2001 From: "G. D. McBain" Date: Thu, 25 Jan 2024 15:54:01 +1100 Subject: [PATCH 3/3] name SampledData too #253 --- docs/src/tutorials/input_component.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/src/tutorials/input_component.md b/docs/src/tutorials/input_component.md index 404bb2c20..219ce7857 100644 --- a/docs/src/tutorials/input_component.md +++ b/docs/src/tutorials/input_component.md @@ -109,7 +109,7 @@ To resolve the issues presented above, the `ModelingToolkitStandardLibrary.Block ```julia function System(; name) - src = SampledData(Float64) + @named src = SampledData(Float64) vars = @variables f(t)=0 x(t)=0 dx(t)=0 ddx(t)=0 pars = @parameters m=10 k=1000 d=1