ivpsolve
Routines for estimating solutions of initial value problems.
IVPSolution
¤
The probabilistic numerical solution of an initial value problem (IVP).
This class stores the computed solution, its uncertainty estimates, and details of the probabilistic model used in probabilistic numerical integration.
Source code in probdiffeq/ivpsolve.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 |
|
marginals: Any
instance-attribute
¤
Marginal distributions for each time point in the posterior distribution.
num_steps: Array
instance-attribute
¤
The number of solver steps taken at each time point.
output_scale: Array
instance-attribute
¤
The calibrated output scale of the probabilistic model.
posterior: Any
instance-attribute
¤
A the full posterior distribution of the probabilistic numerical solution.
Typically, a backward factorisation of the posterior.
ssm: Any
instance-attribute
¤
State-space model implementation used by the solver.
t: Array
instance-attribute
¤
Time points at which the IVP solution has been computed.
u: Array
instance-attribute
¤
The mean of the IVP solution at each computed time point.
u_std: Array
instance-attribute
¤
The standard deviation of the IVP solution, indicating uncertainty.
dt0(vf_autonomous, initial_values, /, scale=0.01, nugget=1e-05)
¤
Propose an initial time-step.
Source code in probdiffeq/ivpsolve.py
319 320 321 322 323 324 325 326 327 328 329 330 |
|
dt0_adaptive(vf, initial_values, /, t0, *, error_contraction_rate, rtol, atol)
¤
Propose an initial time-step as a function of the tolerances.
Source code in probdiffeq/ivpsolve.py
333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 |
|
solve_adaptive_save_at(ssm_init, /, *, save_at, adaptive_solver, dt0, ssm, warn=True) -> IVPSolution
¤
Solve an initial value problem and return the solution at a pre-determined grid.
This algorithm implements the method by Krämer (2024). Please consider citing it if you use it for your research. A PDF is available here and Krämer's (2024) experiments are available here.
BibTex for Krämer (2024)
@InProceedings{kramer2024adaptive,
title = {Adaptive Probabilistic ODE Solvers Without Adaptive Memory
Requirements},
author = {Kr\"{a}mer, Nicholas},
booktitle = {Proceedings of the First International Conference on
Probabilistic Numerics},
pages = {12--24},
year = {2025},
editor = {Kanagawa, Motonobu and Cockayne, Jon and Gessner, Alexandra
and Hennig, Philipp},
volume = {271},
series = {Proceedings of Machine Learning Research},
publisher = {PMLR},
url = {https://proceedings.mlr.press/v271/kramer25a.html}
}
Source code in probdiffeq/ivpsolve.py
103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 |
|
solve_adaptive_save_every_step(ssm_init, /, *, t0, t1, adaptive_solver, dt0, ssm) -> IVPSolution
¤
Solve an initial value problem and save every step.
This function uses a native-Python while loop.
Warning
Not JITable, not reverse-mode-differentiable.
Source code in probdiffeq/ivpsolve.py
199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 |
|
solve_adaptive_terminal_values(ssm_init, /, *, t0, t1, adaptive_solver, dt0, ssm) -> IVPSolution
¤
Simulate the terminal values of an initial value problem.
Source code in probdiffeq/ivpsolve.py
87 88 89 90 91 92 93 94 95 96 97 98 99 100 |
|
solve_fixed_grid(ssm_init, /, *, grid, solver, ssm) -> IVPSolution
¤
Solve an initial value problem on a fixed, pre-determined grid.
Source code in probdiffeq/ivpsolve.py
266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 |
|