Skip to content

Commit

Permalink
FIX: there were errors with the last merge commit . Fix it.
Browse files Browse the repository at this point in the history
  • Loading branch information
Gui-FernandesBR committed Feb 12, 2024
1 parent 233af3b commit cd7d715
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 21 deletions.
3 changes: 3 additions & 0 deletions rocketpy/mathutils/function.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,9 @@ def __init__(
"""
if inputs is None:
inputs = ["Scalar"]
if outputs is None:
outputs = ["Scalar"]

inputs, outputs, interpolation, extrapolation = self._check_user_input(
source, inputs, outputs, interpolation, extrapolation
)
Expand Down
20 changes: 0 additions & 20 deletions rocketpy/simulation/flight.py
Original file line number Diff line number Diff line change
Expand Up @@ -2070,11 +2070,6 @@ def w3(self):
"""Rocket angular velocity ω3 as a Function of time."""
return self.solution_array[:, [0, 13]]

@funcify_method("Time (s)", "Altitude (m)", "spline", "zero")
def altitude(self):
"""Rocket altitude above ground level (AGL) as a Function of time."""
return self.z - self.env.elevation

# Process second type of outputs - accelerations components
@funcify_method("Time (s)", "Ax (m/s²)", "spline", "zero")
def ax(self):
Expand Down Expand Up @@ -2921,21 +2916,6 @@ def get_controller_observed_variables(self):
else observed_variables
)

@cached_property
def get_controller_observed_variables(self):
"""Retrieve the observed variables related to air brakes from the
controllers. If there is only one set of observed variables, it is
returned as a list. If there are multiple sets, the list containing
all sets is returned."""
observed_variables = [
controller.observed_variables for controller in self._controllers
]
return (
observed_variables[0]
if len(observed_variables) == 1
else observed_variables
)

@cached_property
def __calculate_rail_button_forces(self):
"""Calculate the forces applied to the rail buttons while rocket is
Expand Down
1 change: 1 addition & 0 deletions rocketpy/tools.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import importlib
import importlib.metadata
import math
import re
from bisect import bisect_left

Expand Down
2 changes: 1 addition & 1 deletion tests/unit/test_solidmotor.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ def test_evaluate_inertia_33_asserts_extreme_values(cesaroni_m1670):
grain_mass = grain_vol * GRAIN_DENSITY

grain_I_33_initial = (
grain_mass * (1 / 2.0) * (grain_initial_inner_radius**2 + grain_outer_radius**2)
grain_mass * (1 / 2.0) * (GRAIN_INITIAL_INNER_RADIUS**2 + GRAIN_OUTER_RADIUS**2)
)

# not passing because I_33 is not discrete anymore
Expand Down

0 comments on commit cd7d715

Please sign in to comment.