Home > atphysics > Radiation > radiationoff.m

radiationoff

PURPOSE ^

RADIATIONOFF turns classical radiation OFF

SYNOPSIS ^

This is a script file.

DESCRIPTION ^

RADIATIONOFF turns classical radiation  OFF
  Switch all magnets currently set to use pass-methods
  'BndMPoleSymplectic4RadPass' and  'StrMPoleSymplectic4RadPass'
  to their equivalents without radiation
  'BndMPoleSymplectic4Pass' and  'StrMPoleSymplectic4Pass'
    
  NOTES:
    1. Deprecated function, use atradoff instead

   See also RADIATIONON, CAVITYON, CAVITYOFF, ATRADON, ATRADOFF

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 %RADIATIONOFF turns classical radiation  OFF
0002 %  Switch all magnets currently set to use pass-methods
0003 %  'BndMPoleSymplectic4RadPass' and  'StrMPoleSymplectic4RadPass'
0004 %  to their equivalents without radiation
0005 %  'BndMPoleSymplectic4Pass' and  'StrMPoleSymplectic4Pass'
0006 %
0007 %  NOTES:
0008 %    1. Deprecated function, use atradoff instead
0009 %
0010 %   See also RADIATIONON, CAVITYON, CAVITYOFF, ATRADON, ATRADOFF
0011 
0012 
0013 if ~evalin('base','exist(''THERING'')') || ~evalin('base','~isempty(whos(''global'',''THERING''))')
0014    error('Global variable THERING could not be found');
0015 end
0016 localindex = findcells(THERING,'PassMethod','StrMPoleSymplectic4RadPass');
0017 THERING = setcellstruct(THERING,'PassMethod',localindex, 'StrMPoleSymplectic4Pass');
0018 totalswitched = length(localindex);
0019 
0020 localindex = findcells(THERING,'PassMethod','BndMPoleSymplectic4RadPass');
0021 THERING = setcellstruct(THERING,'PassMethod',localindex, 'BndMPoleSymplectic4Pass');
0022 totalswitched = totalswitched + length(localindex);
0023 
0024 localindex = findcells(THERING,'PassMethod','BndMPoleSymplectic4E2RadPass');
0025 THERING = setcellstruct(THERING,'PassMethod',localindex, 'BndMPoleSymplectic4E2Pass');
0026 totalswitched = totalswitched + length(localindex);
0027 
0028 disp(['PassMethod was changed to NOT include radiation in ',num2str(totalswitched),  ' elements'])     
0029 clear localindex totalswitched

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