// Decompiled by Jad v1.5.8e. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.geocities.com/kpdus/jad.html
// Decompiler options: packimports(3) 
// Source File Name:   kinejava.java

package kinematics;

import java.applet.Applet;
import java.applet.AppletContext;
import java.awt.*;
import java.awt.event.*;
import java.io.PrintStream;

// Referenced classes of package kinematics:
//            Fourvector, Momentum, varbar, reactiondef

public class kinejava extends Applet
    implements ActionListener, ItemListener, AdjustmentListener, WindowListener
{

    int error(String s)
    {
        bg = Color.red;
        if(isapplet)
            getAppletContext().showStatus((new StringBuilder()).append("****** Error: ").append(s).append(" ******").toString());
        else
            System.err.println((new StringBuilder()).append("****** Error: ").append(s).append(" ******").toString());
        repaint();
        return 1;
    }

    String deg(double d)
    {
        return (new StringBuilder()).append("").append((double)Math.round((d / 3.1415926535897931D) * 1800D) / 10D).append("\260").toString();
    }

    int kinematics()
    {
        Fourvector fourvector = new Fourvector(1.0D, 0.0D, 0.0D, 0.001D);
        target = photon = e_in = e_out = p1 = p2 = p3 = p4 = fourvector;
        p2 = new Fourvector(1.0D, 0.0D, 0.0D, 0.001D);
        double d = beam - (W * W - q2 - mtarget * mtarget) / 2D / mtarget;
        if(beam <= 0.0D || d <= 0.0D)
            return error("Electron energy negative!");
        if(q2 >= 0.0D)
            return error("No valid q2 for electroproduction");
        double d1 = -q2 / 4D / beam / d;
        if(d1 < 0.0D || d1 > 1.0D)
            return error("q2 to large for this E0!");
        double d2 = 2D * Math.asin(Math.sqrt(d1));
        target = new Fourvector(mtarget, 0.0D, 0.0D, 0.0D);
        e_in = new Fourvector(beam, 0.0D, 0.0D, beam);
        e_out = new Fourvector(d, 0.0D, d * Math.sin(d2), d * Math.cos(d2));
        photon = e_in.sub(e_out);
        Fourvector fourvector1 = target.add(photon);
        double d3 = 1.0D / (1.0D - ((2D * (Math.pow(photon.E, 2D) - q2)) / q2) * Math.pow(Math.tan(d2 / 2D), 2D));
        double d4 = fourvector1.masssquare();
        if(d4 <= (m1 + m2) * (m1 + m2))
            return error("CMS Energy W below threshold!");
        double d6 = Math.sqrt(((d4 - (m1 + m2) * (m1 + m2)) * (d4 - (m1 - m2) * (m1 - m2))) / 4D / d4);
        double d8 = Math.sqrt(Math.pow(mtarget, 4D) + 2D * mtarget * mtarget * (-q2 - W * W) + Math.pow(-q2 + W * W, 2D)) / (2D * W);
        Fourvector fourvector2 = (new Fourvector(Math.sqrt(m1 * m1 + d6 * d6), (new Momentum(Math.sin(ph_cms) * Math.sin(th_cms), Math.cos(ph_cms) * Math.sin(th_cms), Math.cos(th_cms))).mult(d6))).rotatetheta(fourvector1.angle(e_in));
        p1 = fourvector2.Lorentz(fourvector1);
        p2 = fourvector1.sub(p1);
        if(m3 > 0.0D || m4 > 0.0D)
        {
            double d5 = m2 * m2;
            if(d5 <= 0.0D)
                return error("Mass X below 0");
            if(m2 < m3 + m4)
                return error("Mass X below sum of masses of decay particles.");
            double d9 = ((d5 - (m3 + m4) * (m3 + m4)) * (d5 - (m3 - m4) * (m3 - m4))) / 4D / d5;
            if(d9 <= 0.0D)
                return error("Mass X below m3+m4");
            double d7 = Math.sqrt(d9);
            Fourvector fourvector3 = (new Fourvector(Math.sqrt(m4 * m4 + d7 * d7), new Momentum(0.0D, d7 * Math.sin(thetad), d7 * Math.cos(thetad)))).rotatetheta(p2.angle(e_in));
            if(p2.p.abs() <= 0.0D)
                return error("Decaying particle at rest.");
            if(p2.E <= 0.0D)
                return error("Energy of decaying particle is 0.");
            p4 = fourvector3.Lorentz(p2);
            p3 = p2.sub(p4);
        }
        bg = Color.white;
        String s = "";
        if(m3 > 0.0D || m4 > 0.0D)
            s = (new StringBuilder()).append("\n").append(label3).append(":").append("\n       p = ").append((double)Math.round(p3.p.abs() * 10000D) / 10D).append(" MeV/c").append("\n       \u03B8 = ").append(deg(p3.angle())).append("\n").append(label4).append(":").append("\n       p = ").append((double)Math.round(p4.p.abs() * 10000D) / 10D).append(" MeV/c").append("\n       \u03B8 = ").append(deg(p4.angle())).toString();
        double d10 = Math.atan2(p2.p.p[0], p2.p.p[1]);
        Fourvector fourvector4 = new Fourvector(0.0D, 0.0D, 0.0D, 0.0D);
        fourvector4.p.p[0] = Math.cos(d10) * e_out.p.p[0] + Math.sin(d10) * e_out.p.p[1];
        fourvector4.p.p[1] = -Math.sin(d10) * e_out.p.p[0] + Math.cos(d10) * e_out.p.p[1];
        fourvector4.p.p[2] = e_out.p.p[2];
        double d11 = fourvector4.p.oopTh();
        double d12 = fourvector4.p.oopPh();
        double d13 = p2.p.oopTh();
        double d14 = p2.p.oopPh();
        String s1 = "";
        String s2 = "";
        if(p2.p.p[0] != 0.0D)
            s1 = (new StringBuilder()).append("\n       (").append(deg(d11)).append(", ").append(deg(d12)).append(")").toString();
        if(d14 != 0.0D)
            s2 = (new StringBuilder()).append("\n       (").append(deg(d13)).append(", ").append(deg(d14)).append(")").toString();
        outlist.setText((new StringBuilder()).append("e':\n       E' = ").append((double)Math.round(e_out.p.abs() * 10000D) / 10D).append(" MeV").append("\n       \u03B8' = ").append(deg(e_out.angle())).append(s1).append("\n\u03B3:").append("\n       q = ").append((double)Math.round(photon.p.abs() * 10000D) / 10D).append(" MeV/c").append("\n       q_cm = ").append((double)Math.round(d8 * 10000D) / 10D).append(" MeV/c").append("\n       \u03C9 = ").append((double)Math.round(photon.E * 10000D) / 10D).append(" MeV").append("\n       \u03B8 = ").append(deg(photon.angle())).append("\n       \u03B5 = ").append((double)Math.round(d3 * 10000D) / 10000D).append("\n").append(label1).append(":").append("\n       p = ").append(Math.round(p1.p.abs() * 10000D) / 10L).append(" MeV/c").append("\n       p_cm = ").append(Math.round(fourvector2.p.abs() * 10000D) / 10L).append(" MeV/c").append("\n       \u03B8 = ").append(deg(p1.angle())).append("\n").append(label2).append(":").append("\n       p = ").append(Math.round(p2.p.abs() * 10000D) / 10L).append(" MeV/c").append("\n       \u03B8 = ").append(deg(p2.angle())).append(s2).append(s).append("\n").toString());
        repaint();
        return 0;
    }

    public kinejava()
    {
        print = new Button("print");
        bg = Color.white;
        oopFrame = new Frame("Out of Plane angle");
        isapplet = false;
        beam = 0.85499999999999998D;
        W = 1.2D;
        mtarget = 0.93827231D;
        q2 = -0.10000000000000001D;
        th_cms = 1.5707963267948966D;
        ph_cms = 0.0D;
        massd = 0.0D;
        thetad = 1.5707963267948966D;
        m1 = 0.13497429999999999D;
        label1 = "\u03C00";
        m2 = 0.93827231D;
        label2 = "p";
        m3 = 0.0D;
        label3 = "";
        m4 = 0.0D;
        label4 = "";
        setLayout(new BorderLayout());
        setFont(new Font("Times New Roman", 0, 14));
        Panel panel = new Panel(new BorderLayout());
        Panel panel1 = new Panel(new FlowLayout());
        chreaction = new Choice();
        for(int i = 0; i < Reactions.length; i++)
            chreaction.addItem(Reactions[i]);

        panel1.add(chreaction);
        panel.add(panel1, "Center");
        Checkbox checkbox = new Checkbox("OOP");
        panel.add(checkbox, "East");
        panel.add(print, "West");
        print.addActionListener(this);
        checkbox.addItemListener(this);
        chreaction.addItemListener(this);
        vb_beam = new varbar("E =", (int)((beam / 1.5D) * 100D), 100, "MeV");
        vb_q2 = new varbar("q\262 =", (int)((q2 / -1D) * 1000D), 500, "GeV\262");
        vb_W = new varbar("W =", (int)(((W - m1 - m2) / 3D) * 3000D), 3000, "MeV");
        vb_theta = new varbar("\u03B8_CMS =", 90, 360, "\260");
        vb_phi = new varbar("\u03D5_CMS =", 180, 360, "\260");
        vb_submass = new varbar("mass_X", (int)((massd / 1.5D) * 1000D), 1000, "MeV");
        vb_thetadecay = new varbar("\u03B8_Decay", 90, 360, "\260");
        vb_beam.tf.addActionListener(this);
        vb_q2.tf.addActionListener(this);
        vb_W.tf.addActionListener(this);
        vb_theta.tf.addActionListener(this);
        vb_phi.tf.addActionListener(this);
        vb_submass.tf.addActionListener(this);
        vb_thetadecay.tf.addActionListener(this);
        vb_beam.sb.addAdjustmentListener(this);
        vb_q2.sb.addAdjustmentListener(this);
        vb_W.sb.addAdjustmentListener(this);
        vb_theta.sb.addAdjustmentListener(this);
        vb_phi.sb.addAdjustmentListener(this);
        vb_submass.sb.addAdjustmentListener(this);
        vb_thetadecay.sb.addAdjustmentListener(this);
        Panel panel2 = new Panel();
        panel2.setLayout(new GridLayout(0, 1));
        panel2.setSize(600, 83);
        panel2.add(panel);
        panel2.add(vb_beam);
        panel2.add(vb_q2);
        panel2.add(vb_W);
        panel2.add(vb_theta);
        oopFrame.add(vb_phi);
        oopFrame.pack();
        outlist = new TextArea(25, 23);
        outlist.setEditable(false);
        outlist.setFont(new Font("Times New Roman", 0, 14));
        add("East", outlist);
        add("North", panel2);
        rdef = new reactiondef(this);
        set_slidervalues();
        kinematics();
    }

    void selectreaction(int i)
    {
        switch(i)
        {
        case 0: // '\0'
            mtarget = 0.93827231D;
            m1 = 0.13497429999999999D;
            label1 = "\u03C00";
            m2 = 0.93827231D;
            label2 = "p";
            break;

        case 1: // '\001'
            mtarget = 0.93827231D;
            m1 = 0.13956789999999999D;
            label1 = "\u03C0+";
            m2 = 0.93956563000000004D;
            label2 = "n";
            break;

        case 2: // '\002'
            mtarget = 1.87561339D;
            m1 = 0.13497429999999999D;
            label1 = "\u03C00";
            m2 = 1.87561339D;
            label2 = "d";
            break;

        case 3: // '\003'
            mtarget = 0.93827231D;
            m1 = 0.54744999999999999D;
            label1 = "\u03B7";
            m2 = 0.93827231D;
            label2 = "p";
            break;

        case 4: // '\004'
            mtarget = 1.87561339D;
            m1 = 0.93827231D;
            label1 = "p";
            m2 = 0.93956563000000004D;
            label2 = "n";
            break;

        case 5: // '\005'
            mtarget = 0.93827231D;
            m1 = 0.0D;
            label1 = "\u03B3";
            m2 = 0.93827231D;
            label2 = "p";
            break;

        case 6: // '\006'
            mtarget = 0.93827231D;
            m1 = 1.1156839999999999D;
            label1 = "Lambda";
            m2 = 0.49367699999999998D;
            label2 = "K+";
            break;

        case 7: // '\007'
            mtarget = 0.93827231D;
            m1 = 1.19255D;
            label1 = "Sigma0";
            m2 = 0.49367699999999998D;
            label2 = "K+";
            break;

        case 8: // '\b'
            mtarget = 11.174866D;
            m1 = mtarget + 0.17699999999999999D;
            label1 = "12Y";
            m2 = 0.49367699999999998D;
            label2 = "K+";
            break;

        case 9: // '\t'
            mtarget = 14.895084000000001D;
            m1 = mtarget + 0.17699999999999999D;
            label1 = "16Y";
            m2 = 0.49367699999999998D;
            label2 = "K+";
            break;
        }
        W = m1 + m2 + 0.00050000000000000001D;
        kinematics();
    }

    void selectreaction(int i, int j, int k, int l)
    {
        switch(i)
        {
        case 0: // '\0'
            mtarget = 0.93827231D;
            break;

        case 1: // '\001'
            mtarget = 1.87561339D;
            break;

        case 2: // '\002'
            mtarget = 2.808392D;
            break;

        case 3: // '\003'
            mtarget = 3.7273800000000001D;
            break;

        case 4: // '\004'
            mtarget = 11.174866D;
            break;

        case 5: // '\005'
            mtarget = 14.895084000000001D;
            break;
        }
        switch(j)
        {
        case 0: // '\0'
            m1 = 0.0D;
            label1 = "\u03B3";
            break;

        case 1: // '\001'
            m1 = 0.13956995D;
            label1 = "\u03C0+";
            break;

        case 2: // '\002'
            m1 = 0.1349764D;
            label1 = "\u03C00";
            break;

        case 3: // '\003'
            m1 = 0.13956995D;
            label1 = "\u03C0-";
            break;

        case 4: // '\004'
            m1 = 0.93827231D;
            label1 = "p";
            break;

        case 5: // '\005'
            m1 = 0.93956563000000004D;
            label1 = "n";
            break;

        case 6: // '\006'
            m1 = 1.87561339D;
            label1 = "d";
            break;

        case 7: // '\007'
            m1 = 2.808392D;
            label1 = "3He";
            break;

        case 8: // '\b'
            m1 = 3.7273800000000001D;
            label1 = "4He";
            break;

        case 9: // '\t'
            m1 = 9.3255060000000007D;
            label1 = "10Be";
            break;

        case 10: // '\n'
            m1 = 10.252551D;
            label1 = "11B";
            break;

        case 11: // '\013'
            m1 = 10.254022000000001D;
            label1 = "11C";
            break;

        case 12: // '\f'
            m1 = 11.174866D;
            label1 = "12C";
            break;

        case 13: // '\r'
            m1 = 13.040874000000001D;
            label1 = "14C";
            break;

        case 14: // '\016'
            m1 = 13.971182000000001D;
            label1 = "15O";
            break;

        case 15: // '\017'
            m1 = 14.895084000000001D;
            label1 = "16O";
            break;
        }
        label2 = "X";
        switch(k)
        {
        case 0: // '\0'
            m3 = 0.0D;
            label3 = "\u03B3";
            break;

        case 1: // '\001'
            m3 = 0.13956995D;
            label3 = "\u03C0+";
            break;

        case 2: // '\002'
            m3 = 0.1349764D;
            label3 = "\u03C00";
            break;

        case 3: // '\003'
            m3 = 0.13956995D;
            label3 = "\u03C0-";
            break;

        case 4: // '\004'
            m3 = 0.93827231D;
            label3 = "p";
            break;

        case 5: // '\005'
            m3 = 0.93956563000000004D;
            label3 = "n";
            break;

        case 6: // '\006'
            m3 = 1.87561339D;
            label3 = "d";
            break;

        case 7: // '\007'
            m3 = 0.00051099890000000001D;
            label3 = "e+";
            break;

        case 8: // '\b'
            m3 = 0.10565835699999999D;
            label3 = "\u03BC+";
            break;
        }
        switch(l)
        {
        case 0: // '\0'
            m4 = 0.0D;
            label4 = "\u03B3";
            break;

        case 1: // '\001'
            m4 = 0.13956995D;
            label4 = "\u03C0+";
            break;

        case 2: // '\002'
            m4 = 0.1349764D;
            label4 = "\u03C00";
            break;

        case 3: // '\003'
            m4 = 0.13956995D;
            label4 = "\u03C0-";
            break;

        case 4: // '\004'
            m4 = 0.93827231D;
            label4 = "p";
            break;

        case 5: // '\005'
            m4 = 0.93956563000000004D;
            label4 = "n";
            break;

        case 6: // '\006'
            m4 = 1.87561339D;
            label4 = "d";
            break;

        case 7: // '\007'
            m4 = 0.00051099890000000001D;
            label4 = "e-";
            break;

        case 8: // '\b'
            m4 = 0.10565835699999999D;
            label4 = "\u03BC-";
            break;
        }
    }

    public void adjustmentValueChanged(AdjustmentEvent adjustmentevent)
    {
        if(adjustmentevent.getSource() == vb_submass.sb)
            m2 = massd = m3 + m4 + ((double)vb_submass.sb.getValue() / 1000D) * 1.5D;
        if(adjustmentevent.getSource() == vb_thetadecay.sb)
            thetad = ((double)vb_thetadecay.sb.getValue() / 180D - 1.0D) * 3.1415926535897931D;
        if(adjustmentevent.getSource() == vb_beam.sb)
            beam = ((double)vb_beam.sb.getValue() / 100D) * 1.5D;
        if(adjustmentevent.getSource() == vb_q2.sb)
            q2 = ((double)vb_q2.sb.getValue() / 500D) * -1D;
        if(adjustmentevent.getSource() == vb_W.sb)
            W = 0.0001D + m1 + m2 + ((double)vb_W.sb.getValue() / 3000D) * 3D;
        if(adjustmentevent.getSource() == vb_theta.sb)
            th_cms = ((double)vb_theta.sb.getValue() / 180D - 1.0D) * 3.1415926535897931D;
        if(adjustmentevent.getSource() == vb_phi.sb)
            ph_cms = ((double)vb_phi.sb.getValue() / 180D - 1.0D) * 3.1415926535897931D;
        set_slidervalues();
        kinematics();
    }

    public void itemStateChanged(ItemEvent itemevent)
    {
        if(itemevent.getItem().equals("OOP"))
        {
            ItemEvent _tmp = itemevent;
            oopFrame.setVisible(itemevent.getStateChange() == 1);
            return;
        }
        if(itemevent.getSource() == chreaction)
        {
            if(chreaction.getSelectedIndex() != 10)
            {
                m3 = m4 = 0.0D;
                rdef.setVisible(false);
            } else
            {
                rdef.setVisible(true);
            }
            selectreaction(chreaction.getSelectedIndex());
        } else
        {
            selectreaction(chtarget.getSelectedIndex(), chmass1.getSelectedIndex(), chmass2.getSelectedIndex(), chmass3.getSelectedIndex());
            label2 = "X";
        }
        kinematics();
    }

    public void actionPerformed(ActionEvent actionevent)
    {
        if(actionevent.getActionCommand().equals("oop"))
            System.out.println("oop");
        if(actionevent.getActionCommand().equals("print"))
        {
            PrintJob printjob = getToolkit().getPrintJob(new Frame(), "", null);
            Graphics g = printjob.getGraphics();
            g.translate(50, -200);
            paint(g);
            g.translate(-150, 0);
            String s = outlist.getText();
            int i = 0;
            int j = s.indexOf('\n');
            int k = -90;
            for(; j > 0; j = s.indexOf('\n', i))
            {
                g.drawString(s.substring(i, j), 320, k);
                k += 15;
                i = j + 1;
            }

            printjob.end();
        }
        get_slidervalues(actionevent);
        set_slidervalues();
        kinematics();
    }

    public void init()
    {
        isapplet = true;
    }

    public void start()
    {
        if(m3 > 0.0D || m4 > 0.0D)
            rdef.setVisible(true);
    }

    public void stop()
    {
        rdef.setVisible(false);
        oopFrame.setVisible(false);
    }

    public void paint(Graphics g)
    {
        Color color = new Color(0, 128, 128);
        Color color1 = new Color(128, 0, 128);
        Color color2 = new Color(128, 128, 0);
        if(beam < 0.0D)
            return;
        Fourvector fourvector = new Fourvector(1.0D, 1.0D, 0.0D, 0.0D);
        g.translate(150, 400);
        g.setColor(bg);
        g.fillRect(-140, -140, 280, 280);
        g.setColor(Color.red);
        g.drawRect(-140, -140, 280, 280);
        g.setColor(Color.blue);
        e_out.draw(g, fourvector, 80D / beam, "e'");
        g.setColor(Color.blue);
        g.drawLine(0, 0, 0, 80);
        g.setColor(color);
        photon.draw(g, fourvector, 80D / beam, "\u03B3");
        g.setColor(color2);
        p1.draw(g, photon, 80D / beam, label1);
        g.setColor(Color.magenta);
        p2.draw(g, photon, 80D / beam, label2);
        if(m3 > 0.0D || m4 > 0.0D)
        {
            g.setColor(color1);
            p3.draw(g, p2.add(photon), 80D / beam, label3);
            g.setColor(Color.gray);
            p4.draw(g, p2.add(photon), 80D / beam, label4);
        }
    }

    void set_slidervalues()
    {
        vb_beam.tf.setText((new StringBuilder()).append("").append((double)Math.round(beam * 10000D) / 10D).toString());
        vb_q2.tf.setText((new StringBuilder()).append("").append(q2).toString());
        vb_W.tf.setText((new StringBuilder()).append("").append((double)Math.round(W * 10000D) / 10D).toString());
        vb_theta.tf.setText((new StringBuilder()).append("").append((double)Math.round((th_cms / 3.1415926535897931D) * 1800D) / 10D).toString());
        vb_phi.tf.setText((new StringBuilder()).append("").append((double)Math.round((ph_cms / 3.1415926535897931D) * 1800D) / 10D).toString());
        vb_submass.tf.setText((new StringBuilder()).append("").append((double)Math.round(m2 * 10000D) / 10D).toString());
        vb_thetadecay.tf.setText((new StringBuilder()).append("").append((double)Math.round((thetad / 3.1415926535897931D) * 1800D) / 10D).toString());
    }

    void get_slidervalues(ActionEvent actionevent)
    {
        if(actionevent.getSource() == vb_beam.tf)
            beam = vb_beam.getdouble() / 1000D;
        if(actionevent.getSource() == vb_q2.tf)
            q2 = vb_q2.getdouble();
        if(actionevent.getSource() == vb_W.tf)
            W = vb_W.getdouble() / 1000D;
        if(actionevent.getSource() == vb_theta.tf)
            th_cms = (vb_theta.getdouble() / 180D) * 3.1415926535897931D;
        if(actionevent.getSource() == vb_phi.tf)
            ph_cms = (vb_phi.getdouble() / 180D) * 3.1415926535897931D;
        if(actionevent.getSource() == vb_submass.tf)
            m2 = vb_submass.getdouble() / 1000D;
        if(actionevent.getSource() == vb_thetadecay.tf)
            thetad = (vb_thetadecay.getdouble() / 180D) * 3.1415926535897931D;
    }

    public static void main(String args[])
    {
        Frame frame = new Frame("Kinematics");
        kinejava kinejava1 = new kinejava();
        frame.add(kinejava1);
        frame.pack();
        frame.setVisible(true);
        frame.addWindowListener(kinejava1);
    }

    public void windowOpened(WindowEvent windowevent)
    {
    }

    public void windowClosing(WindowEvent windowevent)
    {
        System.exit(0);
    }

    public void windowClosed(WindowEvent windowevent)
    {
    }

    public void windowIconified(WindowEvent windowevent)
    {
    }

    public void windowDeiconified(WindowEvent windowevent)
    {
    }

    public void windowActivated(WindowEvent windowevent)
    {
    }

    public void windowDeactivated(WindowEvent windowevent)
    {
    }

    varbar vb_q2;
    varbar vb_beam;
    varbar vb_W;
    varbar vb_theta;
    varbar vb_submass;
    varbar vb_thetadecay;
    varbar vb_phi;
    TextArea outlist;
    Button print;
    Choice chreaction;
    Choice chtarget;
    Choice chmass1;
    Choice chmass2;
    Choice chmass3;
    Color bg;
    reactiondef rdef;
    Frame oopFrame;
    boolean isapplet;
    Fourvector e_in;
    Fourvector e_out;
    Fourvector photon;
    Fourvector target;
    Fourvector p1;
    Fourvector p2;
    Fourvector p3;
    Fourvector p4;
    double beam;
    double W;
    double mtarget;
    double q2;
    double th_cms;
    double ph_cms;
    double massd;
    double thetad;
    double m1;
    String label1;
    double m2;
    String label2;
    double m3;
    String label3;
    double m4;
    String label4;
    static final String Reactions[] = {
        "p(e,e'p)\u03C00", "p(e,e'\u03C0+)n", "d(e,e'd)\u03C00", "p(e,e'p)\u03B7", "d(e,e'p)n", "p(e,e'p)\u03B3", "p(e,e'K+)Lambda", "p(e,e'K+)Sigma0", "12C(e,e'K+)12Y", "16O(e,e'K+)16Y", 
        "(e,e'Resonance) ..."
    };

}
