Return to g_normalize.f CVS log | Up to [HallC] / Analyzer / UTILSUBS |
File: [HallC] / Analyzer / UTILSUBS / g_normalize.f
(download)
Revision: 1.1, Wed Feb 9 14:16:38 1994 UTC (30 years, 7 months ago) by cdaq Branch: MAIN CVS Tags: spring03, sep0596, sep-26-2002, sep-25-2002, sep-24-2002, sep-09-2002, sane, pionct, online07, online04, online03, oct1199, oct1194, nov2894, nov2696, mduality, may2495, may1894, mar1495, mar-24-2003, jun1794, jun1594, jun1394, jun0794, jul2895, jul0794, jan2795, jan2496, jan1896, jan1796, gep_online, gep3, fpi2, emc, e01004, dec0694, bigcal, baryon, aug1794, aug0394, aug-12-2003, apr3096, apr1594, apr0695, apr-02-2003, Initial-CVS-Release, HEAD, Extra_Shower_Tubes_on_HMS_not_SOS Initial revision |
SUBROUTINE G_normalize(x,y,z) *---------------------------------------------------------------------- *- *- Purpose and Methods : normalizes a vector *- *- Inputs : x - X coord. (conventional right handed system) *- y - Y *- z - Z *- Outputs : x - X coord. (conventional right handed system) *- y - Y *- z - Z *- *- Created 24-MAR-1992 Kevin B. Beard *- Modified for hall C 9/1/93: KBB * $Log: g_normalize.f,v $ * Revision 1.1 1994/02/09 14:16:38 cdaq * Initial revision * *- *---------------------------------------------------------------------- IMPLICIT NONE real x,y,z,r logical normalizable real nothing parameter (nothing= 1.E-25) real r2 *---------------------------------------------------------------------- * r2= x**2 + y**2 + z**2 normalizable= r2.GT.nothing IF(normalizable) THEN r= SQRT(r2) x= x/r y= y/r z= z/r ELSE x= 0. y= 0. z= 0. ENDIF RETURN end
Analyzer/Replay: Mark Jones, Documents: Stephen Wood |
Powered by ViewCVS 0.9.2-cvsgraph-1.4.0 |