Skip to content

Conversation

@soypat
Copy link
Contributor

@soypat soypat commented Jun 3, 2023

Please take a look. Fixes issue raised in mail group: https://groups.google.com/g/gonum-dev/c/_B0R3518KNI

also adds initial conditions as part of result vector returned by SolveIVP as that seems reasonably intuitive.

@kortschak
Copy link
Member

What is the fix?

if nx == 0 {
return nil, errors.New("state vector length can not be equal to zero. Has ivp been set?")
}
solver.Init(p)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kortschak Forgot to initialize the integrator. This was the pressing problem that caused the crash since it meant some fields were nil upon attempting to integrate.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, that was my suspcion. Can you make a note of that in the commit message?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

alright!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants