Beispiel #1
0
 public static string InitState(this OpenClRng rng, string stateVar, string seedVar, bool beStupid)
 {
     if (beStupid)
     {
         return(rng.StupidInitState(stateVar, seedVar));
     }
     else
     {
         return(rng.InitState(stateVar, seedVar));
     }
 }
Beispiel #2
0
            public string StupidInitState(string stateVar, string seedVar)
            {
                //return
                //    Tau1.StupidInitState(stateVar + ".z1", seedVar) + Environment.NewLine
                //    + Tau2.StupidInitState(stateVar + ".z2", seedVar) + Environment.NewLine
                //    + Tau3.StupidInitState(stateVar + ".z3", seedVar) + Environment.NewLine
                //    + Lcg.StupidInitState(stateVar + ".z4", seedVar);

                return(Lcg.StupidInitState(stateVar + ".z4", seedVar) + Environment.NewLine

                       + Lcg.StepState(stateVar + ".z4") + Environment.NewLine
                       + Lcg.StepState(stateVar + ".z4") + Environment.NewLine
                       + Lcg.StepState(stateVar + ".z4") + Environment.NewLine

                       + Tau1.StupidInitState(stateVar + ".z1", Lcg.GetUintVal(stateVar + ".z4")) + Environment.NewLine
                       + Lcg.StepState(stateVar + ".z4") + Environment.NewLine
                       + Tau2.StupidInitState(stateVar + ".z2", Lcg.GetUintVal(stateVar + ".z4")) + Environment.NewLine
                       + Lcg.StepState(stateVar + ".z4") + Environment.NewLine
                       + Tau3.StupidInitState(stateVar + ".z3", Lcg.GetUintVal(stateVar + ".z4")) + Environment.NewLine
                       + Lcg.StepState(stateVar + ".z4") + Environment.NewLine
                       );
            }