KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > JSci > physics > particles > AntiTau


1 package JSci.physics.particles;
2
3 import JSci.physics.quantum.QuantumParticle;
4
5 /**
6 * A class representing antitaus.
7 * @version 1.5
8 * @author Mark Hale
9 */

10 public final class AntiTau extends AntiLepton {
11         /**
12         * Constructs an antitau.
13         */

14         public AntiTau() {}
15         /**
16         * Returns the rest mass (MeV).
17         * @return 1777.03
18         */

19         public double restMass() {return 1777.03;}
20         /**
21         * Returns the electric charge.
22         * @return 1
23         */

24         public int charge() {return 1;}
25         /**
26         * Returns the electron lepton number.
27         * @return 0
28         */

29         public int eLeptonQN() {return 0;}
30         /**
31         * Returns the muon lepton number.
32         * @return 0
33         */

34         public int muLeptonQN() {return 0;}
35         /**
36         * Returns the tau lepton number.
37         * @return -1
38         */

39         public int tauLeptonQN() {return -1;}
40         /**
41         * Returns the antiparticle of this particle.
42         */

43         public QuantumParticle anti() {
44                 return new Tau();
45         }
46         /**
47         * Returns true if qp is the antiparticle.
48         */

49         public boolean isAnti(QuantumParticle qp) {
50                 return (qp!=null) && (qp instanceof Tau);
51         }
52         /**
53         * Returns a string representing this class.
54         */

55         public String JavaDoc toString() {
56                 return new String JavaDoc("Antitau");
57         }
58         /**
59         * Emits a photon.
60         */

61         public AntiTau emit(Photon y) {
62                 momentum=momentum.subtract(y.momentum);
63                 return this;
64         }
65         /**
66         * Absorbs a photon.
67         */

68         public AntiTau absorb(Photon y) {
69                 momentum=momentum.add(y.momentum);
70                 return this;
71         }
72         /**
73         * Emits a W+.
74         */

75         public AntiTauNeutrino emit(WPlus w) {
76                 AntiTauNeutrino n=new AntiTauNeutrino();
77                 n.momentum=momentum.subtract(w.momentum);
78                 return n;
79         }
80         /**
81         * Absorbs a W-.
82         */

83         public AntiTauNeutrino absorb(WMinus w) {
84                 AntiTauNeutrino n=new AntiTauNeutrino();
85                 n.momentum=momentum.add(w.momentum);
86                 return n;
87         }
88         /**
89         * Emits a Z0.
90         */

91         public AntiTau emit(ZZero z) {
92                 momentum=momentum.subtract(z.momentum);
93                 return this;
94         }
95         /**
96         * Absorbs a Z0.
97         */

98         public AntiTau absorb(ZZero z) {
99                 momentum=momentum.add(z.momentum);
100                 return this;
101         }
102 }
103
104
Popular Tags