Skip to content

Instantly share code, notes, and snippets.

View visr's full-sized avatar

Martijn Visser visr

View GitHub Profile
@visr
visr / mtk_param_hist.jl
Last active May 27, 2022 12:31
Save and plot parameter history with ModelingToolkit.jl
# Example from https://mtk.sciml.ai/dev/tutorials/ode_modeling/
# with a parameter τ that is updated through a callback.
# The parameter history is tracked, which allows us to create interpolating
# functions that show the correct history for parameters and observed variables
# that depend on variables.
# This works around limitations discussed here:
# https://discourse.julialang.org/t/update-parameters-in-modelingtoolkit-using-callbacks/63770
# And was posted here: https://discourse.julialang.org/t/save-and-plot-parameter-history-with-modelingtoolkit-jl/81778
# License is MIT
# Versions are ModelingToolkit v8.12 and CairoMakie v0.8
@visr
visr / keybase.md
Created April 9, 2020 21:19
Keybase proof

Keybase proof

I hereby claim:

  • I am visr on github.
  • I am visr (https://keybase.io/visr) on keybase.
  • I have a public key ASDJMOV3tZRSLIfXOBpljhWP7kTyyMmP_7al-nIyfD2kxAo

To claim this, I am signing this object: