Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.8.2 #38

Merged
merged 2 commits into from
Sep 25, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,15 @@

## 2023

#### v0.8.2

New Features:
- Added a helper flag to control if `CySolver.reset_state` is called at the end of initialization.

#### v0.8.1

New Features:
- Added more interp functions that take pointers as arguments
- Added more interp functions that take pointers as arguments.

Changes:
- Converted interp functions to use each other where possible, rather than having separate definitions.
Expand All @@ -15,7 +20,7 @@ Performance:
- Moved some backend functionality for CyRK.interp to pure c file for performance gains.

Bug Fixes:
- Fixed issue with "cy/common.pyx" not having the correct cython flags during compliation.
- Fixed issue with "cy/common.pyx" not having the correct cython flags during compilation.

### v0.8.0

Expand Down
7 changes: 6 additions & 1 deletion CyRK/cy/cysolver.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,7 @@ cdef class CySolver:
Py_ssize_t num_extra = 0,
bool_cpp_t interpolate_extra = False,
Py_ssize_t expected_size = 0,
bool_cpp_t call_first_reset = True,
bool_cpp_t auto_solve = True):
"""
Initialize new CySolver instance.
Expand Down Expand Up @@ -310,6 +311,9 @@ cdef class CySolver:
Used to build temporary storage arrays for the solution results.
If set to 0 (the default), then the solver will attempt to guess on a suitable expected size based on the
relative tolerances and size of the integration domain.
call_first_reset : bool, default=True
If set to True, then the solver will call its `reset_state` method at the end of initialization. This flag
is overridden by the `auto_solve` flag.
auto_solve : bool_cpp_t, default=True
If set to True, then the solver's `solve` method will be called at the end of initialization.
Otherwise, the user will have to call `solver_instance = CySolver(...); solver_instance.solve()`
Expand Down Expand Up @@ -583,7 +587,8 @@ cdef class CySolver:

# Parameters are initialized but may not be set to correct values.
# Call reset state to ensure everything is ready.
self.reset_state()
if call_first_reset or auto_solve:
self.reset_state()

# Run solver if requested
if auto_solve:
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name='CyRK'
version = '0.8.1'
version = '0.8.2'
description='Runge-Kutta ODE Integrator Implemented in Cython and Numba.'
authors= [
{name = 'Joe P. Renaud', email = 'joe.p.renaud@gmail.com'}
Expand Down
Loading