Quasics2015Code/src/DriveTrain/DriveTrainSmoothing.cpp
/*Linear Interpolation Calculator
 *	Point below is (x0, y0), point above is (x1, y1)
 *	plots a point between them and evaluates that equation for x
 */
Linear Interpolation Calculator
Point below is (x0, y0), point above is (x1, y1)
plots a point between them and evaluates that equation for x
Linear Interpolation Calculator Point below is ( x0 y0 ) point above is ( x1 y1 ) plots a point between them and evaluates that equation for x
float LinearInterpolation(float x0, float y0, float x1, float y1, float x) {
	if (x1 == x0) {
		return y0;
	}
	return (y0 + (y1 - y0) * (x - x0) / (x1 - x0));
}
float LinearInterpolation ( float x0 , float y0 , float x1 , float y1 , float x ) { if ( x1 == x0 ) { return y0 ; } return ( y0 + ( y1 - y0 ) * ( x - x0 ) / ( x1 - x0 ) ) ; }
Linear Interpolation Calculator
      Point below is (x0, y0), point above is (x1, y1)
      plots a point between them and evaluates that equation for x
Linear Interpolation Calculator Point below is ( x0 y0 ) point above is ( x1 y1 ) plots a point between them and evaluates that equation for x
//To prevent a NAN, return y0 //Actual equation