Home > pubtools > atmomap.m

atmomap

PURPOSE ^

ATMOMAP find momentum aperture at start of ring

SYNOPSIS ^

function [deltap,deltam,Rfin, loss,X0l] = atmomap(ring, Nturn)

DESCRIPTION ^

ATMOMAP            find momentum aperture at start of ring

[deltap,deltam] = atmomap(THERING, Nturn)

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function [deltap,deltam,Rfin, loss,X0l] = atmomap(ring, Nturn)
0002 %ATMOMAP            find momentum aperture at start of ring
0003 %
0004 %[deltap,deltam] = atmomap(THERING, Nturn)
0005 
0006 %dpp0 = [-0.04:0.001:0.04];
0007 %dpp0 = [-0.04:0.005:0.04];
0008 %dpp0 = [-0.04:0.002:-0.02, 0, 0.02:0.002:0.04];
0009 %dpp0 = [-0.05:0.001:-0.02, 0, 0.02:0.001:0.05];
0010 dpp0 = [-0.05:0.05:-0.01, 0, 0.01:0.05:0.05];
0011 %dpp0=0
0012 X0l = zeros(6, length(dpp0));
0013 X0l(5,:) = dpp0;
0014 %tic
0015 %X0l=[0 0 0 0 -0.03 0]';
0016 [Rfin, loss] =ringpass(ring,X0l,Nturn);
0017 %Rfin
0018 %toc
0019 [tmp, indxzero] = find(dpp0==0);
0020 taglossp = min([length(dpp0) indxzero-1+find(loss(indxzero:end))]);
0021 taglossm = max([1 find(loss(1:indxzero))]);
0022 
0023 deltap = dpp0(taglossp);
0024 deltam = dpp0(taglossm);

Generated on Thu 24-Aug-2017 18:47:33 by m2html © 2005