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
To Reproduce & Expected behavior & Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Add any other context about the problem here.
Describe the bug
Incorrect vector rotation in GenericSurface.compute_forces_and_moments().
Here, we want to represent the black
L,D,Qvectors 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:
Q,L,Dvectors matching+X,-Y,-Zin body frame (i.e. Vector([side, -lift, -drag]) )-alphaon X axis andbetaon Y axis.Q,L,Dvectors and presented in body frameAnother POV:
-alphaon X axis andbetaon Y axis.To Reproduce & Expected behavior & Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Add any other context about the problem here.