SciML / StochasticDiffEq.jl

Solvers for stochastic differential equations which connect with the scientific machine learning (SciML) ecosystem
Other
245 stars 66 forks source link

SROCK2 fails for non-square noise #504

Open axsk opened 1 year ago

axsk commented 1 year ago

SROCK2 fails when being run with noisematrices of size (n,1)

function test(n=2, m=1, alg=SROCK2())
  f(x,p,t) = zeros(n)
  g(x,p,t) = ones(n,m)
  x0 = zeros(n)
  nrp = ones(n,m)
  solve(SDEProblem(f, g, x0, 1, noise_rate_prototype=nrp), alg=alg, dt=.1)
end

test(3,2, SROCK2())  # runs
test(2,1, EM())  # runs
test(2,1, SROCK2()  # fails