dimx=3;
dimp=2;
dimw=3;
dimy=2;

fxu={-1/2*Sin[x[3]](p[1]+p[2])+w[1],1/2*Cos[x[3]](p[1]+p[2])+w[2],(p[1]-p[2])/(2lm)+w[3]};
fy={x[1],x[2]};
qv=Array[q,dimy];
sfv=Array[sf,dimx];
wfv=Array[wf,dimx];
Q=DiagonalMatrix[qv];
Sf=DiagonalMatrix[sfv];
Wf=DiagonalMatrix[wfv];
L={y[1]-x[1],y[2]-x[2]}.Q.{y[1]-x[1],y[2]-x[2]}/2+wv.Wf.wv/2;
xv=Array[x,dimx];
hxv=Array[hx, dimx];
phi=(hxv-xv).Sf.(hxv-xv)/2;
pt={r0 Sin[omg0 t],r0 Sin[(omg0 t)+1]};

MyVarNames={"lm","r0","omg0"};
MyVarValues={0.0605,0.2,1.26};
MyArrNames={"q","sf","wf"};
MyArrDims={dimy,dimx,dimx};
MyArrValues={{1,1},{1,1,1},{1,1,1}};

tsim0=0;
tsim=10;
tf=1;
ht=0.01;
alpha=0.5;
zeta=10;
x0={-0.3,-0.2,0};
dv=50;
dstep=10;
st1={0.01,0.01,0.01}
av1={0.0,0.0,0.0}
st2={0.05,0.05}
av2={0.0,0.0}
fnout="esrv11";
fnhd="data\\strv11";
optu=1;
smpu=4;