Analytic evolve functions (ODE)
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 839
- Forks
- 220
- Avg merge
- 2d 4h
- Merged PRs (30d)
- 14
Description
From @betanalpha on May 21, 2015 12:55
In ODE models some components can be solved analytically such that some state components are given in closed form and some need to be solved numerically. To maintain code consistency in these models it would be nice to have a function that parallels integrate_ode but instead of calling an ODE solver to evolve the state just applies a user-defined function,
real[] evolve_state(function, y0, t0, ts, theta, x_r, x_i) {
real y[size(y0), size(ts)];
y[,0] = y0;
for (n in 1:size(ts))
y[,n] = function(y[,n - 1], ts[n], theta, x_r, x_i)
return y;
}
Copied from original issue: stan-dev/stan#1456
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the existing integrate_ode entry point and the proposed evolve_state signature in this issue. Confirm how the function should apply user-defined state updates across ts while carrying y0, theta, x_r, and x_i; done means the requested analytic evolution behavior is implemented and verified by the relevant project tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100