Skip to content

BUG: Incorrect vector rotation in GenericSurface.compute_forces_and_moments #932

@zuorenchen

Description

@zuorenchen

Describe the bug

Incorrect vector rotation in GenericSurface.compute_forces_and_moments().
Here, we want to represent the black L, D, Q vectors in the blue body frame.

The M_BA matrix should be direction cosine matrix (DCM), however it is given in vector rotation matrices. Vector rotation matrices rotate the vector without changing/rotating reference frame.

Current implementation rotates the force vectors to match body axis, but results are however presented in aero frame.

If it is intended to use rotation matrix instead of DCM, the rotation should be:

  • Start with the Q, L, D vectors matching +X, -Y, -Z in body frame (i.e. Vector([side, -lift, -drag]) )
  • Rotate the vector by -alpha on X axis and beta on Y axis.
  • The results will match the black Q, L, D vectors and presented in body frame

Another POV:

  • Only focus on blue Zb axis and body frame.
  • Rotate the Zb axis by -alpha on X axis and beta on Y axis.
  • the result will match the black V vector
Image Image

To Reproduce & Expected behavior & Screenshots

Image

If applicable, add screenshots to help explain your problem.

Additional context

Add any other context about the problem here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions