Skip to content

Add multiplicative noise? #336

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
sdwfrost opened this issue Jun 27, 2020 · 5 comments
Closed

Add multiplicative noise? #336

sdwfrost opened this issue Jun 27, 2020 · 5 comments

Comments

@sdwfrost
Copy link

In some cases e.g. where states are enforced to be positive, it makes sense for the noise to be multiplicative rather than additive. One option is to model log-transformed states, but it would be less unwieldy to be able to add e.g. gamma distributed noise as in https://www.sciencedirect.com/science/article/pii/S0304414911001761.

@ChrisRackauckas
Copy link
Member

Multiplicative noise is a form of diagonal noise, so it's not specifically specialized on in the solvers since things like SOSRI are a form of specialization on them. That said, this is a longer running thread. https://arxiv.org/abs/1804.04344 in section 4 shows how methods for additive noise can in theory be used, and that would be a nice optimization, but it's really really difficult to do this in a general sense inside of the solver. So instead we're looking at SciML/ModelingToolkit.jl#140 . So I'm closing this as an issue that probably should be solved by ModelingToolkit, though there's a chance I revive the numerical transformation approach in the future.

@sdwfrost
Copy link
Author

Thanks for the pointer to your paper; I'll take a look at the transform approach. Do you think that in the meantime an Euler scheme with multiplicative noise is OK, along the lines of this?

@ChrisRackauckas
Copy link
Member

Yes, and the diagonal noise interface is very natural for multiplicative noise, i.e.:

https://docs.sciml.ai/latest/tutorials/sde_example/#Example-2:-Systems-of-SDEs-with-Diagonal-Noise-1

Here's changing that from additive to multiplicative noise:

function lorenz(du,u,p,t)
  du[1] = 10.0(u[2]-u[1])
  du[2] = u[1]*(28.0-u[3]) - u[2]
  du[3] = u[1]*u[2] - (8/3)*u[3]
end

function σ_lorenz(du,u,p,t)
  du[1] = 3.0u[1]
  du[2] = 3.0u[2]
  du[3] = 3.0u[3]
end

prob_sde_lorenz = SDEProblem(lorenz,σ_lorenz,[1.0,0.0,0.0],(0.0,10.0))
sol = solve(prob_sde_lorenz)
plot(sol,vars=(1,2,3))

FWIW, most of these routines were originally made for the case of multiplicative noise!

@sdwfrost
Copy link
Author

Doesn't your example still have noise that is added to the ODE system? What I mean is a system where du = du*dW where dW is Gamma white noise (see rgammawn in https://www.rdocumentation.org/packages/pomp/versions/1.19/topics/eulermultinom)

@ChrisRackauckas
Copy link
Member

ChrisRackauckas commented Jun 29, 2020

the system is x' = 10(y-x) + 3x dW, y' = x(28-z) - y + 3y dW, z' = xy - 8/3 z + 3z dW, is that the kind of thing you're looking for? That's what I'd normally think of as multiplicative noise.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants