newr - newr.m Analyze tracking algorithm by Park et al AIAA...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
% newr.m % Analyze tracking algorithm by Park et al % AIAA GNC 2004 % % Assumes that ac3.m has been run to generate syscl % Jonathan How % MIT 16.333 Fall 2004 % % close all dt=1; % time step for the simulation U0=235.9; path=[]; jcase=1; % 2 path cases considered if jcase==1 t=[0:5*dt:2500]'; omp=.0025; path=24000*[sin(omp*t) (1-cos(omp*t))]; xe=0;ye=1500; X=[.1 0 0 0*pi/180 0*pi/180 0 0 0]'; else t=[0:dt:1350]'; path(:,1)=U0*t; omp=.005; path(:,2)=500*(-cos(2*pi*omp*t)+1).*exp(.002*t); xe=0;ye=-1000; X=[.1 0 0 -15*pi/180 -15*pi/180 0 0 0]'; end % Discretize the dynamics with time step dt % system has the inner yaw and roll loops closed [A,B,C,D]=ssdata(syscl); syscld=c2d(ss(A,B,C,D),dt); [Ad,Bd,Cd,Dd]=ssdata(syscld); Bd=Bd(:,1);Dd=Dd(:,1); % only need first input % bank angle limit philim=30; % %inputs are phi_d and 0 %state x=[v p r phi Psi xx xx xx] L1=2000; % look ahead distance store=[]; % find the point on the path L1 ahead ii=find((xe-path(:,1)).^2+(ye-path(:,2)).^2 < L1^2); iii=max(ii);
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 11/07/2011 for the course AERO 16.333 taught by Professor Alexandremegretski during the Fall '04 term at MIT.

Page1 / 2

newr - newr.m Analyze tracking algorithm by Park et al AIAA...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online