/* -*- Mode: Text -*-* */ /********************************************************************\ * File: 2dkineveh.hs * * Date: 07/12/1997 * * Author: Cem Unsal * * Robotics Institute, Carnegie-Mellon University * * unsal@ri.cmu.edu * * * * Description: * * Two dimentional kinematic vehicle model * * * * A simple bicycle model with a wheel base of W meters * * * * Model parameters can be set in this file, or the type 'creating' * * the vehicle model. * * * * External C functions: - * * * * This file is distributed under the conditions described in the * * file 'CONDITIONS' which should accompany this file. * \********************************************************************/ #ifndef SAHS_VEHICLE_KINEMATICS_HS #define SAHS_VEHICLE_KINEMATICS_HS type Vehicle_Kinematics { input number steering; // Steering angle at the front wheel // (in vehicle coord. frame) number acc; // Long. acceleration for the front wheel // (in the direction of the rolling motion) output continuous number thetaDot; // Angular speed of rotation continuous number xDot, yDot := 0; // Long. and lateral speeds // (in vehicle coord. frame) continuous number speed; // Wheel speed state number W := 3.5; // Wheel base flow default { speed' = acc; // This is here so that we may // add more detail later xDot = speed * cos(steering); // Basic bicycle model thetaDot = speed / W * sin(steering); }; } #endif // SAHS_VEHICLE_KINEMATICS_HS