psi0_squared=cnorm2(psi0).multiply(10)// x10 to make it more visible on the plot
mutablepsi=psi0// This sets the initial condition for the simulation of psi
// Note, for more info on "mutable" see https://observablehq.com/@mbostock/mutable-values
{
if(simulate===true){// Only simulate when simulation checkbox has been checked
mutablepsi=psi_dt(psi,expV,expK,expABC)// This runs the simulation indefinitely
}
return"Indefinite simulation loop"
}
psi_squared=cnorm2(psi).multiply(10)// x10 to make it more visible on the plot
graph.update([x,psi_squared,V])
Purpose-built for displays of data
Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.