示例#1
0
文件: Car.cs 项目: grzesiekmq/rgn
        /// <summary>
        /// right angle of ackermann steering in degrees
        /// </summary>
        /// <param name="rearTrack"></param>
        /// <param name="wheelBase"></param>
        /// <param name="turnRadius"></param>
        /// <returns>angle</returns>
        public static double AckermannRight(float rearTrack, float wheelBase, float turnRadius)
        {
            var right = Math.Atan(wheelBase / (turnRadius - rearTrack / 2));

            return(Maths.RadToDeg(right));
        }
示例#2
0
文件: Car.cs 项目: grzesiekmq/rgn
        /// <summary>
        /// left angle of ackermann steering in degrees
        /// </summary>
        /// params in metres
        /// <param name="rearTrack"></param>
        /// <param name="wheelBase"></param>
        /// <param name="turnRadius"></param>
        ///
        /// <returns>angle</returns>
        public static double AckermannLeft(float rearTrack, float wheelBase, float turnRadius)
        {
            var left = Math.Atan(wheelBase / (turnRadius + rearTrack / 2));

            return(Maths.RadToDeg(left));
        }