Created
December 24, 2021 10:43
-
-
Save Akashleena/7f534c212477d6e44ac279a7d6615e0a to your computer and use it in GitHub Desktop.
phithetahistory
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class HomicidalChauffeurPursuit : MonoBehaviour | |
{ | |
public List<float> angles = new List<float>(); | |
public float angle; | |
public float angleDiff; | |
public static object phiThetaHistory(object X) | |
{ | |
// var angles = np.arctan2(X[":",4] - X[":",1], X[":",3] - X[":",0]); | |
angles = Mathf.Atan((X[":",4] - X[":",1])/(X[":",3]-X[":",0])) | |
//var angle = np.unwrap(angles)[-1]; | |
// print("unwrapped:", angle, " wrapped: ", angles[-1]) | |
angle = 2*Math.PI*(a/(2*Math.PI))+(a % (2 * Math.PI)) | |
angleDiff = Math.PI/2 - angle - X[-1,2]; | |
return (angleDiff/(verticalInput / minTurnRadius)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment