lcsim/src/org/lcsim/util/step
diff -u -r1.2 -r1.3
--- TrkPhaseSpace.java 27 Jun 2005 21:32:14 -0000 1.2
+++ TrkPhaseSpace.java 31 Oct 2005 22:34:52 -0000 1.3
@@ -10,7 +10,7 @@
* Particle assumed is a Muon, but can be changed by setting rp[6] at input
* Units are Tesla, cm, GeV/c
* @author C. Milstene.
- * @version $Id: TrkPhaseSpace.java,v 1.2 2005/06/27 21:32:14 lima Exp $
+ * @version $Id: TrkPhaseSpace.java,v 1.3 2005/10/31 22:34:52 caroline Exp $
*/
public class TrkPhaseSpace
@@ -38,8 +38,11 @@
double inPx,double inPy,double inPz, double inM, double inQ)
{
rp[0]=inX; rp[1]=inY ; rp[2]=inZ;
- rp[3]=inPx; rp[4]=inPy; rp[5]=inPz;
+ rints[0]=inX; rints[1]=inY ; rints[2]=inZ;
+ rp[3]=inPx; rp[4]=inPy; rp[5]=inPz;
+ pints[3]=inPx; pints[4]=inPy; pints[5]=inPz;
rp[6]=inM ; rp[7]=inQ ;
+ partMQ[6]=inM ; partMQ[7]=inQ ;
}
/** Reset - clear by calling clearTrkPhaseSpace()
*/
@@ -269,20 +272,25 @@
df.setMaximumFractionDigits(5);
double ph0 = tpar.get_phi0();
double d0 = tpar.get_d0();
+ System.out.println(" TrkPhaseSpace: d0="+d0+" omega="+tpar.omega);
- double pt = BField*0.3*.01/Math.abs(tpar.omega);
+ double pt = BField*0.3*.001/Math.abs(tpar.omega);
+ System.out.println("BField="+BField);
double tchg = tpar.omega>0. ? +1. : -1.;
+ System.out.println("rpFromParm ph0="+ph0+" d0="+d0+" pt="+pt);
rp[3]=pt*Math.cos(ph0) ;
rp[4]=pt*Math.sin(ph0) ;
rp[5]=pt*tpar.get_tandip();
rp[6]=(inputM==-1.)? mDefault:inputM ; // Default Muon mass
rp[7]=tchg ;
- rp[0]=d0*Math.cos(ph0 + tchg * halfpi);
- rp[1]=d0*Math.sin(ph0 + tchg * halfpi);
- rp[2] = tpar.get_z0() ;
+ rp[0]=10*d0*Math.cos(ph0 + tchg * halfpi); // position from d0 in mm
+ rp[1]=10*d0*Math.sin(ph0 + tchg * halfpi); // position from d0 in mm
+ rp[2] =10* tpar.get_z0() ; // position from d0 in mm
- return upDateRp(rp[0],rp[1],rp[2],rp[3],rp[4],rp[5],rp[6],rp[7]);
+ setRp(rp[0],rp[1],rp[2],rp[3],rp[4],rp[5],rp[6],rp[7]);
+ System.out.println("PH-SP:px,py,pz"+rp[3]+" "+rp[4]+" "+rp[5]);
+ return rp;
}
public String toStringTrkPhaseSpace()