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

BUG: fix extrapolation of multivariable functions. #462

Closed
wants to merge 2 commits into from

Conversation

phmbressan
Copy link
Collaborator

Pull request type

  • Code changes (bugfix, features)
  • Code maintenance (refactoring, formatting, tests)
  • ReadMe, Docs and GitHub updates
  • Other (please describe):

Checklist

  • Tests for the changes have been added (if needed)
  • Docs have been reviewed and added / updated
  • Lint (black rocketpy/ tests/) has passed locally
  • All tests (pytest --runslow) have passed locally

Current behavior

The construction of a multivariable Function from a dataset (e.g. [(0,0,0), (0,1,1), ...]) triggered an extrapolation error since it was being kept None when calling get_value_opt.

New behavior

The error was fixed by setting the extrapolation type on set_source similarly to what occurs when the dataset is one dimensional. Tests for the changes have been added.

Breaking change

  • Yes
  • No

@phmbressan phmbressan added the Bug Something isn't working label Nov 15, 2023
@phmbressan phmbressan self-assigned this Nov 15, 2023
@Gui-FernandesBR
Copy link
Member

Gui-FernandesBR commented Nov 15, 2023

Seems duplicated with #451 . @phmbressan please see it first before the revision

@phmbressan phmbressan closed this Nov 15, 2023
@phmbressan
Copy link
Collaborator Author

Seems duplicated with #451 . @phmbressan please see it first before the revision

You are absolutely correct. I will merge the tests from this PR to #451.

@Gui-FernandesBR Gui-FernandesBR added this to the Release v1.X.0 milestone Nov 20, 2023
@Gui-FernandesBR Gui-FernandesBR deleted the bug/multivariable-function branch November 20, 2023 02:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
Status: Closed
Development

Successfully merging this pull request may close these issues.

2 participants