@@ -147,12 +147,18 @@ class Rocket:
147147 Rocket.static_margin : float
148148 Float value corresponding to rocket static margin when
149149 loaded with propellant in units of rocket diameter or calibers.
150- Rocket.power_off_drag : int, float, callable, string, array, Function
150+ Rocket.power_off_drag : Function
151+ Rocket's drag coefficient as a function of Mach number when the
152+ motor is off. Alias for ``power_off_drag_by_mach``.
153+ Rocket.power_on_drag : Function
154+ Rocket's drag coefficient as a function of Mach number when the
155+ motor is on. Alias for ``power_on_drag_by_mach``.
156+ Rocket.power_off_drag_input : int, float, callable, string, array, Function
151157 Original user input for rocket's drag coefficient when the motor is
152- off. This is preserved for reconstruction and Monte Carlo workflows.
153- Rocket.power_on_drag : int, float, callable, string, array, Function
158+ off. Preserved for reconstruction and Monte Carlo workflows.
159+ Rocket.power_on_drag_input : int, float, callable, string, array, Function
154160 Original user input for rocket's drag coefficient when the motor is
155- on. This is preserved for reconstruction and Monte Carlo workflows.
161+ on. Preserved for reconstruction and Monte Carlo workflows.
156162 Rocket.power_off_drag_7d : Function
157163 Rocket's drag coefficient with motor off as a 7D function of
158164 (alpha, beta, mach, reynolds, pitch_rate, yaw_rate, roll_rate).
@@ -375,9 +381,12 @@ def __init__( # pylint: disable=too-many-statements
375381 interpolation = "linear" ,
376382 extrapolation = "constant" ,
377383 )
378- # Saving user input for monte carlo
379- self .power_off_drag = power_off_drag
380- self .power_on_drag = power_on_drag
384+ # Saving raw user input for reconstruction and Monte Carlo
385+ self .power_off_drag_input = power_off_drag
386+ self .power_on_drag_input = power_on_drag
387+ # Public API attributes: keep as Function (Mach-only) for backward compatibility
388+ self .power_off_drag = self .power_off_drag_by_mach
389+ self .power_on_drag = self .power_on_drag_by_mach
381390
382391 # Create a, possibly, temporary empty motor
383392 # self.motors = Components() # currently unused, only 1 motor is supported
0 commit comments