rotresp.m 421 Bytes
Newer Older
Simone Liuzzo's avatar
Simone Liuzzo committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
function [rh,rv,dpp]=rotresp(mach,dCT,rotidx,bpmidx)

rot=1.e-3;
norm=1/rot;
orbit=findsyncorbit(mach,dCT,bpmidx);
dpp=orbit(5);
refh=orbit(1,:)*norm;
refv=orbit(3,:)*norm;
rh=zeros(length(bpmidx),length(rotidx));
rv=zeros(length(bpmidx),length(rotidx));
for i=1:length(rotidx)
    orbit=findsyncorbit(atsettilt(mach,rotidx(i),rot),dCT,bpmidx);
    rh(:,i)=orbit(1,:)*norm - refh;
    rv(:,i)=orbit(3,:)*norm - refv;
end