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: Parachute Pressures not being Set before All Info. #534

Merged
merged 3 commits into from
Jan 21, 2024
Merged
Show file tree
Hide file tree
Changes from 2 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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ straightforward as possible.

### Fixed

- BUG: Parachute Pressures not being Set before All Info. [#534](https://github.com/RocketPy-Team/RocketPy/pull/534)
- BUG: Invalid Arguments on Two Dimensional Discretize. [#521](https://github.com/RocketPy-Team/RocketPy/pull/521)

## [v1.1.4] - 2023-12-07
Expand Down
1 change: 0 additions & 1 deletion rocketpy/plots/flight_plots.py
Original file line number Diff line number Diff line change
Expand Up @@ -817,7 +817,6 @@ def pressure_signals(self):
if len(self.flight.parachute_events) > 0:
for parachute in self.flight.rocket.parachutes:
print("\nParachute: ", parachute.name)
self.flight._calculate_pressure_signal()
parachute.noise_signal_function()
parachute.noisy_pressure_signal_function()
parachute.clean_pressure_signal_function()
Expand Down
5 changes: 3 additions & 2 deletions rocketpy/simulation/flight.py
Original file line number Diff line number Diff line change
Expand Up @@ -1065,6 +1065,7 @@
)

self.t_final = self.t
self._calculate_pressure_signal()
if verbose:
print("Simulation Completed at Time: {:3.4f} s".format(self.t))

Expand Down Expand Up @@ -3089,8 +3090,8 @@
else:
for parachute in self.rocket.parachutes:
for t in time_points:
p_cl = parachute.clean_pressure_signal(t)
p_ns = parachute.noisy_pressure_signal(t)
p_cl = parachute.clean_pressure_signal_function(t)
p_ns = parachute.noisy_pressure_signal_function(t)

Check warning on line 3094 in rocketpy/simulation/flight.py

View check run for this annotation

Codecov / codecov/patch

rocketpy/simulation/flight.py#L3093-L3094

Added lines #L3093 - L3094 were not covered by tests
file.write(f"{t:f}, {p_cl:.5f}, {p_ns:.5f}\n")
# We need to save only 1 parachute data
break
Expand Down
Loading