From 3ca934403397308b7a5ec993b53fdbdbbc42b40c Mon Sep 17 00:00:00 2001 From: oameye Date: Thu, 29 Aug 2024 10:00:30 +0200 Subject: [PATCH 1/2] add additative noise trait --- src/alg_traits.jl | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/alg_traits.jl b/src/alg_traits.jl index 075beccba..7922a2ec8 100644 --- a/src/alg_traits.jl +++ b/src/alg_traits.jl @@ -243,3 +243,13 @@ as the maximum order of the algorithm. function alg_order(alg::AbstractODEAlgorithm) error("Order is not defined for this algorithm") end + +""" + allows_non_wiener_noise(alg::AbstractSDEAlgorithm) + +Trait declaration for whether an algorithm allows for non-additive wiener noise. +In general, this is false for any high order (that uses levy areas) or adaptive method. + +Defaults to false. +""" +allows_non_wiener_noise(alg::AbstractSDEAlgorithm) = false From 14b761e2976cb6dbbbc4d666e1e797712290c322 Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Sun, 1 Sep 2024 22:34:22 -0400 Subject: [PATCH 2/2] Update alg_traits.jl --- src/alg_traits.jl | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/alg_traits.jl b/src/alg_traits.jl index 7922a2ec8..13eefffd3 100644 --- a/src/alg_traits.jl +++ b/src/alg_traits.jl @@ -247,9 +247,19 @@ end """ allows_non_wiener_noise(alg::AbstractSDEAlgorithm) -Trait declaration for whether an algorithm allows for non-additive wiener noise. +Trait declaration for whether an algorithm allows for non-wiener noise. In general, this is false for any high order (that uses levy areas) or adaptive method. Defaults to false. """ allows_non_wiener_noise(alg::AbstractSDEAlgorithm) = false + +""" + requires_additive_noise(alg::AbstractSDEAlgorithm) + +Trait declaration for whether an algorithm requires additive noise, i.e. the noise +function is not a function of `u`. + +Defaults to false +""" +requires_additive_noise(alg::AbstractSDEAlgorithm) = false