Skip to content
This repository has been archived by the owner on Sep 9, 2024. It is now read-only.

WIP: Test framework #3

Closed
wants to merge 3 commits into from
Closed

WIP: Test framework #3

wants to merge 3 commits into from

Conversation

tomasaschan
Copy link
Contributor

I've started working on a small test framework for the ODE solvers. It uses FactCheck for verification, but I've made some modifications there as well, as well as used some code that is likely to move soon (JuliaLang/julia#2422), so this really isn't ready for merging yet.

But I very much like to hear what you think about the test API and the general look of the code so far =)

@vtjnash
Copy link
Contributor

vtjnash commented May 7, 2013

I think this seems right.

One thought, from my experience writing the basic tests, I think you will want the tolerances to be based on some combination of the difficulty of the problem and the accuracy of the solver. For example, the expectations of an ode23 solver are going to be lower than an ode45.

@tomasaschan
Copy link
Contributor Author

True. Maybe we want yet another abstraction, which basically holds a problem, a solver and a pair of tolerance values. The test suite will the correspond to a list of (solver,problem,rtol,atol) tuples, which we iterate over and verify. This is probably needed anyway, since we need to keep track of different problem sets for different solvers, so we don't test non-stiff solvers on stiff problems etc.

On a related, but slightly tangential note, we also need to harmonize the API for the solvers. I haven't spent a lot of time looking at it, so it might not be that much to do, but I think the general form tout, yout = odeXX(f, tspan, y0) should go for all solvers for explicit problems, and that it should work with both scalar and vector y0. Possibly, yout should also mimic the dimensions of y0, so that a scalar y0 yields a vector (as opposed to matrix) yout. This is probably a separate issue, though...

@tomasaschan
Copy link
Contributor Author

I'm closing this for cleanup, since the main ideas from here are already in our test suite...

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants