refactor exact ode detection; update tests