pterasoftware.unsteady_ring_vortex_lattice_method¶
Contains the UnsteadyRingVortexLatticeMethodSolver class.
Classes¶
A class used to solve UnsteadyProblems with the unsteady ring vortex lattice method. |
Module Contents¶
- class pterasoftware.unsteady_ring_vortex_lattice_method.UnsteadyRingVortexLatticeMethodSolver(unsteady_problem: pterasoftware._core.CoreUnsteadyProblem)[source]¶
A class used to solve UnsteadyProblems with the unsteady ring vortex lattice method.
Contains the following methods:
run: Runs the solver on the UnsteadyProblem.
initialize_step_geometry: Initializes geometry for a specific step without solving.
calculate_solution_velocity: Finds the fluid velocity (in the first Airplane’s geometry axes, observed from the Earth frame) at one or more points (in the first Airplane’s geometry axes, relative to the first Airplane’s CG) due to the freestream velocity and the induced velocity from every ring vortex.
- Parameters:
unsteady_problem – The UnsteadyProblem (or subclass of CoreUnsteadyProblem) to be solved.
- Returns:
None
- property steady_problems: tuple[pterasoftware.problems.SteadyProblem, Ellipsis]¶
The SteadyProblems for this solver’s UnsteadyProblem.
This read-only view always reflects the live state of the underlying UnsteadyProblem. For a standard UnsteadyProblem the tuple is fixed over the solver’s lifetime; for a coupled problem it grows as each step is initialized during the run, so successive reads can return different-length tuples.
- Returns:
A tuple of the SteadyProblems, one per initialized time step.
- run(prescribed_wake: bool | numpy.bool_ = True, calculate_streamlines: bool | numpy.bool_ = True, show_progress: bool | numpy.bool_ = True) None[source]¶
Runs the solver on the UnsteadyProblem.
- Parameters:
prescribed_wake – Set this to True to solve using a prescribed wake model. Set to False to use a free-wake, which may be more accurate but will make the fun method significantly slower. Can be a bool or a numpy bool and will be converted internally to a bool. The default is True.
calculate_streamlines – Determines whether to calculate the streamlines emanating from the back of the wing after running the solver. Can be a bool or a numpy bool and will be converted internally to a bool. The default is True.
show_progress – Set this to True to show the TQDM progress bar. For showing the progress bar and displaying log statements, set up logging using the setup_logging function. It can be a bool or a numpy bool and will be converted internally to a bool. The default is True.
- Returns:
None
- initialize_step_geometry(step: int) None[source]¶
Initializes geometry for a specific step without solving.
Sets up bound ring vortices and wake ring vortices for the specified time step, but does not solve the aerodynamic system. Use this for geometry only analysis like delta_time optimization.
This method must be called sequentially for each step starting from 0, as wake vortices at step N depend on the geometry from step N - 1.
- Parameters:
step – The time step to initialize geometry for. It is zero indexed. It must be a non negative int and be less than the total number of steps.
- Returns:
None
- calculate_solution_velocity(stackP_GP1_CgP1: numpy.ndarray | collections.abc.Sequence[collections.abc.Sequence[float | int]], bound_singularity_counts: numpy.ndarray | None = None, wake_singularity_counts: numpy.ndarray | None = None) numpy.ndarray[source]¶
Finds the fluid velocity (in the first Airplane’s geometry axes, observed from the Earth frame) at one or more points (in the first Airplane’s geometry axes, relative to the first Airplane’s CG) due to the freestream velocity and the induced velocity from every ring vortex.
When an image surface is defined on the OperatingPoint, the returned velocity also includes the induced velocity from image bound and wake ring vortices reflected across that surface.
Notes:
This method assumes that the correct strengths for the ring vortices have already been calculated and set.
This method also does not include the velocity due to the Movement’s motion at any of the points provided, as it has no way of knowing if any of the points lie on panels.
- Parameters:
stackP_GP1_CgP1 – An array-like object of numbers (int or float) with shape (N,3) representing the positions of the evaluation points (in the first Airplane’s geometry axes, relative to the first Airplane’s CG). Can be a tuple, list, or ndarray. Values are converted to floats internally. The units are in meters.
bound_singularity_counts – An optional (4,) ndarray of int64 for accumulating singularity event counts from bound ring vortices. If None, counts are discarded.
wake_singularity_counts – An optional (4,) ndarray of int64 for accumulating singularity event counts from wake ring vortices. If None, counts are discarded.
- Returns:
A (N,3) ndarray of floats representing the velocity (in the first Airplane’s geometry axes, observed from the Earth frame) at each evaluation point due to the summed effects of the freestream velocity and the induced velocity from every ring vortex. The units are in meters per second.