106 virtual void f(
double t,
const adoreMatrix<double, 0, 1>& x_in, adoreMatrix<double, 0, 1>& dx_out)
109 const double PSI = x_in(2);
110 const double vx = x_in(3);
111 const double vyr = x_in(4)-
lambda_*x_in(5);
114 const double vy = x_in(4);
115 const double omega = x_in(5);
118 const double dax = x_in(8);
119 const double ddelta = x_in(9);
137 if ((vx>0.0 && ax>0.0)
138 || ( vx<0.0 && ax<0.0))
160 double Fyf_Fzf, Fyr_Fzr;
166 double ay = Fyf_Fzf + Fyr_Fzr;
167 double domega = (1.0 /
Iz_m_) * (
a_*Fyf_Fzf -
b_*Fyr_Fzr);
169 dx_out(0) =
cos(PSI)*vx -
sin(PSI)*vy;
170 dx_out(1) =
sin(PSI)*vx +
cos(PSI)*vy;
173 dx_out(4) = ay - vx*omega + domega*(
lambda_-
b_);
183 double kappa = tan(delta) /
L_;
184 dx_out(0) =
cos(PSI)*vx -
sin(PSI)*vy;
185 dx_out(1) =
sin(PSI)*vx +
cos(PSI)*vy;
186 dx_out(2) = vx*kappa;
188 dx_out(4) = -5.0 * (vy - vx*kappa*
lambda_);
189 dx_out(5) = -5.0 * (omega - vx*kappa);
Definition: vlb_openloop.h:32
double cr_
Definition: vlb_openloop.h:43
double mu_
Definition: vlb_openloop.h:41
double a_
Definition: vlb_openloop.h:36
double delta_min_
Definition: vlb_openloop.h:46
double delta_max_
Definition: vlb_openloop.h:45
virtual void f(double t, const adoreMatrix< double, 0, 1 > &x_in, adoreMatrix< double, 0, 1 > &dx_out)
Definition: vlb_openloop.h:106
double g_
Definition: vlb_openloop.h:40
void setReference(double value)
Definition: vlb_openloop.h:83
double lambda_
Definition: vlb_openloop.h:35
void setGearState(VehicleExtendedState::GearState value)
Definition: vlb_openloop.h:91
VehicleExtendedState::GearState gearState_
Definition: vlb_openloop.h:47
VLB_OpenLoop(adore::params::APVehicle *p)
Definition: vlb_openloop.h:54
void updateParameters(adore::params::APVehicle *p)
Definition: vlb_openloop.h:64
double Iz_m_
Definition: vlb_openloop.h:44
double L_
Definition: vlb_openloop.h:38
double h_
Definition: vlb_openloop.h:39
double cf_
Definition: vlb_openloop.h:42
double b_
Definition: vlb_openloop.h:37
GearState
Definition: vehicleextendedstate.h:29
@ Drive
Definition: vehicleextendedstate.h:30
@ Park
Definition: vehicleextendedstate.h:30
@ Neutral
Definition: vehicleextendedstate.h:30
@ Reverse
Definition: vehicleextendedstate.h:30
Definition: aodemodel.h:30
abstract class for vehicle configuration related paremeters
Definition: ap_vehicle.h:29
virtual double get_h() const =0
cog height above ground
virtual double get_steeringAngleMin() const =0
virtual double get_mu() const =0
friction coefficient
virtual double get_cr() const =0
rear normalized tire stiffness for bicycle model
virtual double get_Iz_m() const =0
rotational inertia around up axis devided by mass
virtual double get_b() const =0
rear axle to cog
virtual double get_steeringAngleMax() const =0
virtual double get_a() const =0
cog to front axle
virtual double get_cf() const =0
front normalized tire stiffness for bicycle model
virtual double get_g() const =0
gravitational constant
interval< T > cos(interval< T > x)
Definition: intervalarithmetic.h:225
T bound(T lb, T value, T ub)
Definition: adoremath.h:569
interval< T > sin(interval< T > x)
Definition: intervalarithmetic.h:204
Definition: areaofeffectconverter.h:20