! Routine stability.clic ! ! Modif for arbitrary antenna numbers MB 6-Feb-1996 ! automatic "set antenna ..." and modified parabolic fit steps MB 25-Mar-1996 ! parabolic fit replaced by analytical solution + comments RN 10-Apr-1996 ! !say " Version 11-Apr-1996." !say " " !say " The stability requirement in the STATUS is not stringent: heighten " !say " or relax the receiver's stability depending on current atmospheric " !say " conditions, array configuration and frequencies." !say " " !say " The radio path is expected to vary by not more than 0.7 mm/K under " !say " average observing conditions: less than 7 mm pwv and above 30 deg. " !say " 0.7 mm/K is equivalent to a phase deviation of 100 deg/K @ 115 GHz " !say " and of 200 deg/K @ 230 GHz. The precision with which the receivers " !say " will measure temperatures will dependent on their stability. " !say " " !say " A stability of 2E-4 is roughly equivalent to an rms of 60 mK which " !say " in turn implies (possible) phase corrections up to 6 deg @ 115 GHz " !say " and up to 12 deg @ 230 GHz." !say " " set lev 3 ! if found.eq.0 then say "Sorry - current index is empty. Try again with some data, please." return endif variables config on get first ! set ant 1 if nant.eq.2 then set ant 1 2 endif if nant.eq.3 then set ant 1 2 3 endif if nant.eq.4 then set ant 1 2 3 4 endif if nant.eq.5 then set ant 1 2 3 4 5 endif ! set y tot plot ! sic precision double define double x1 y1 xy x2 x3 x4 x2y a b c d e xm define double stab[3,nant] define integer n let n n_data[1] define double z[n] x0[n] y0[n] ! ! for j 1 to nant cd box0'J' ! let x0 x_data[j] let y0 y_data[j] compute xm mean x0 compute y1 mean y0 let x0 (x0-xm) ! let z x0^2 compute x2 mean z ! let z x0^3 compute x3 mean z ! let z x0^4 compute x4 mean z ! let z x0*y0 compute xy mean z ! let z x0^2*y0 compute x2y mean z ! let a xy|x2 let b x2*y1|x2 ! let z y0-(a*x0+b) compute e rms z let stab[2,j] 1e-5*nint(1e5*e|b) compute e rms y0 let stab[1,j] 1e-5*nint(1e5*e|b) ! pen 3 let y0 a*x0+b let x0 x0+xm conn x0 y0 let x0 x0-xm let y0 y_data[j] pen 0 ! let d (x2*x4-x3^2)-x2*x2^2 let a (y1*(x2*x4-x3^2)+x2*(xy*x3-x2y*x2))|d let b (xy*x4-x2y*x3+y1*x2*x3-x2*x2*xy)|d let c (x2*x2y-x3*xy-y1*x2^2)|d let z y0-(a+b*x0+c*x0*x0) let y0 a+b*x0+c*x0*x0 pen 1 let x0 x0+xm connect x0 y0 pen 0 compute e rms z let stab[3,j] 1e-5*nint(1e5*e|a) cd next ! let stab stab*1e4 SAY " " SAY " Resultat de mesure de stabilite des recepteurs" SAY " [1 - 2] EXCELLENT " SAY " [2 - 3] Acceptable " SAY " [3 - 4] Marginal " SAY " > 4 Mauvais --> reprendre reglage recepteur " SAY " ( Mixer Bias et/ou diminuer Mixer Back Short) " SAY " " SAY " (Physical antenna numbers)" SAY " " SAY " Stabilite Totale Lineaire Parabole" FOR J 1 TO nant ! SAY "Antenna "'J'" Stabilite "'STAB[1,J]' 'STAB[2,J]' 'STAB[3,J]' SAY " Antenna " phys_ant[j] STAB[1,J] STAB[2,J] STAB[3,J] " (1E-4)"/FORMAT A I2 F10.1 F10.1 F10.1 A NEXT FOR J 1 TO nant IF STAB[3,J].GT.4 THEN SAY " Reprendre reglage recepteur #2 sur antenne "'phys_ant[j]' SAY " (Mixer Bias et/ou diminuer Mixer Back Short) " ELSE IF STAB[3,J].GT.3 THEN SAY " Stabilite marginale pour antenne "'phys_ant[j]' ENDIF NEXT ! variables config off set lev 1