Skip to content

Conversation

@ChrisRackauckas
Copy link
Member

We actually know the entire time series for the solution, so we should state that we know that via dense=true.

using OrdinaryDiffEqDefault, ModelingToolkit
using ModelingToolkit: t_nounits as t, D_nounits as D

@variables x(t) y(t)
eqs = [y ~ x, y ~ sin(t)]
@mtkbuild sys = ODESystem(eqs, t)

tspan = (0.0, 10.0)
prob = ODEProblem(sys, [], tspan)
sol = solve(prob)
using Plots
plot(sol, idxs = [x])
savefig("plot.png")

Before and after

We actually know the entire time series for the solution, so we should state that we know that via `dense=true`.

```julia
using OrdinaryDiffEqDefault, ModelingToolkit
using ModelingToolkit: t_nounits as t, D_nounits as D

@variables x(t) y(t)
eqs = [y ~ x, y ~ sin(t)]
@mtkbuild sys = ODESystem(eqs, t)

tspan = (0.0, 10.0)
prob = ODEProblem(sys, [], tspan)
sol = solve(prob)
using Plots
plot(sol, idxs = [x])
savefig("plot.png")
```

Before and after
@ChrisRackauckas
Copy link
Member Author

Before:
image

After:
plot

@ChrisRackauckas ChrisRackauckas merged commit e300adf into master May 14, 2025
42 of 48 checks passed
@ChrisRackauckas ChrisRackauckas deleted the nulldense branch May 14, 2025 16:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants