Пример #1
0
 public HybridTau(Taus taus1, Taus taus2, Taus taus3, Lcg lcg)
 {
     this.Taus1 = taus1;
     this.Taus2 = taus2;
     this.Taus3 = taus3;
     this.Lcg   = lcg;
 }
Пример #2
0
 public HybridTau(Taus taus1, Taus taus2, Taus taus3, Lcg lcg)
 {
     this.Taus1 = taus1;
     this.Taus2 = taus2;
     this.Taus3 = taus3;
     this.Lcg = lcg;
 }
Пример #3
0
        static Generators()
        {
            // The magic constants for initXorValues are picked by my fingers and keyboard.
            Taus tau1 = new Taus(13, 19, 12, 4294967294u, 256, 0xA2F47E12u, 0);  // p1=2^31-1
            Taus tau2 = new Taus(2, 25, 4, 4294967288u, 512, 0xD3316298u, 29);   // p2=2^30-1
            Taus tau3 = new Taus(3, 11, 17, 4294967280u, 1024, 0x1D454AF1u, 30);   // p3=2^28-1
            Lcg lcg1 = new Lcg(1664525, 1013904223u, 0, 0xE0F39837u, 31);        // p4=2^32
            HybridTau = new HybridTau(tau1, tau2, tau3, lcg1);
            AllGenerators.Add(new GeneratorEntry("HybridTau", HybridTau));

            Tau1 = tau1;
            AllGenerators.Add(new GeneratorEntry("Tau1", Tau1));
            Tau2 = tau2;
            AllGenerators.Add(new GeneratorEntry("Tau2", Tau2));
            Tau3 = tau3;
            AllGenerators.Add(new GeneratorEntry("Tau3", Tau3));
            Lcg1 = lcg1;
            AllGenerators.Add(new GeneratorEntry("Lcg1", Lcg1));

            AllGenerators.Add(new GeneratorEntry("Zero", Zero));
            AllGenerators.Add(new GeneratorEntry("One", One));
            AllGenerators.Add(new GeneratorEntry("Max", Max));
        }
Пример #4
0
        static Generators()
        {
            // The magic constants for initXorValues are picked by my fingers and keyboard.
            Taus tau1 = new Taus(13, 19, 12, 4294967294u, 256, 0xA2F47E12u, 0);  // p1=2^31-1
            Taus tau2 = new Taus(2, 25, 4, 4294967288u, 512, 0xD3316298u, 29);   // p2=2^30-1
            Taus tau3 = new Taus(3, 11, 17, 4294967280u, 1024, 0x1D454AF1u, 30); // p3=2^28-1
            Lcg  lcg1 = new Lcg(1664525, 1013904223u, 0, 0xE0F39837u, 31);       // p4=2^32

            HybridTau = new HybridTau(tau1, tau2, tau3, lcg1);
            AllGenerators.Add(new GeneratorEntry("HybridTau", HybridTau));

            Tau1 = tau1;
            AllGenerators.Add(new GeneratorEntry("Tau1", Tau1));
            Tau2 = tau2;
            AllGenerators.Add(new GeneratorEntry("Tau2", Tau2));
            Tau3 = tau3;
            AllGenerators.Add(new GeneratorEntry("Tau3", Tau3));
            Lcg1 = lcg1;
            AllGenerators.Add(new GeneratorEntry("Lcg1", Lcg1));

            AllGenerators.Add(new GeneratorEntry("Zero", Zero));
            AllGenerators.Add(new GeneratorEntry("One", One));
            AllGenerators.Add(new GeneratorEntry("Max", Max));
        }
Пример #5
0
 public DotNetImpl(Taus generator)
 {
     this.Generator = generator;
 }
Пример #6
0
 public OpenClImpl(Taus generator, string prefix)
 {
     this.Generator = generator;
     this.Prefix = prefix;
 }
Пример #7
0
 public OpenClImpl(Taus generator, string prefix)
 {
     this.Generator = generator;
     this.Prefix    = prefix;
 }
Пример #8
0
 public DotNetImpl(Taus generator)
 {
     this.Generator = generator;
 }