public static void main(String[] argv)
    {
        PopulationCode p1=new PopulationCode("testLayer",5*10*12,"testing",1);
        p1.addDimension("X",0,1e4,12,"X axis");
        p1.addDimension("Y",0,1e4,10,"Y axis");
        p1.addDimension("Z",0,1e4, 5,"Z axis");
        int[] vect=new int[3];
        for (int x=0;x<12;x++)
        {
            for (int y=0;y<10;y++)
            {
                for (int z=0;z<5;z++)
                {
                    vect[0]=x; vect[1]=y; vect[2]=z;
                    p1.setFiringRate(vect,x*y*z);
                    double verify=p1.getFiringRate(vect);
                    System.out.println((x*y*z)+"=="+verify);
                }
            }
        }

        double[] val={7500,2500,5000};
        double conf=1.0;

        for (int x=0;x<12;x++)
        {
            for (int y=0;y<10;y++)
            {
                for (int z=0;z<5;z++)
                {
                    vect[0]=x; vect[1]=y; vect[2]=z;
                    double v=p1.getFiringRate(vect);
                    System.out.println(v+" == "+x*y*z);
                }
            }
        }
        p1.encode(val,conf);
        for (int i=0;i<p1.actualsize;i++)
        {
            System.out.print(p1.firingRate[i]+"  ");
            if (i%12==0) System.out.println("       -> X comp end.");
            if (i%(12*10)==0) System.out.println("     -> Y comp end.");
        }
    } //main