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

Unrealistic thrust asked in the breguet cruise segment #401

Open
esnguyenvan opened this issue Nov 17, 2021 · 0 comments
Open

Unrealistic thrust asked in the breguet cruise segment #401

esnguyenvan opened this issue Nov 17, 2021 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@esnguyenvan
Copy link
Contributor

In class BreguetCruiseSegment() the variable reference_area is assigned a default value of 1.0 and should only be used is use_max_lift_drag_ratio is set to False:

class BreguetCruiseSegment(CruiseSegment, mission_file_keyword="breguet"):
    """
    Class for computing cruise flight segment at constant altitude using Breguet-Leduc formula.
    As formula relies on SFC, the :attr:`propulsion` model must be able to fill FlightPoint.sfc
    when FlightPoint.thrust is provided.
    """

    #: if True, max lift/drag ratio will be used instead of the one computed with polar using
    #: CL deduced from mass and altitude.
    #: In this case, reference_area parameter will be unused
    use_max_lift_drag_ratio: bool = False

    #: The reference area, in m**2. Used only if use_max_lift_drag_ratio is False.
    reference_area: float = 1.0

    #:
    climb_and_descent_distance: float = 0.0

    def __post_init__(self):
        super().__post_init__()
        self.target.ground_distance = self.target.ground_distance - self.climb_and_descent_distance

    def compute_from(self, start: FlightPoint) -> pd.DataFrame:
        self.complete_flight_point(start)

        cruise_mass_ratio = self._compute_cruise_mass_ratio(start, self.target.ground_distance)

However use_max_lift_drag_ratio is not checked before calling complete_flight_point() in function compute_from(), where the variable reference_area is used with its default value of 1.0 to compute the lift and drag which in turn asks for some rocket thrust of 1 million Newtons to the engine module.

I suggest additional checks or merging of function _compute_cruise_mass_ratio() into compute_from(), unless we'd like to launch FAST-OAD into space exploration :).

@esnguyenvan esnguyenvan added the bug Something isn't working label Nov 17, 2021
@christophe-david christophe-david self-assigned this Nov 18, 2021
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
None yet
Development

No branches or pull requests

2 participants