private void FillLandscape(LandscapeFilling lf) { Action <int> fill = null; switch (lf) { case LandscapeFilling.QuadraticFunction: fill = FillLandscapeQuadratic; break; case LandscapeFilling.ValueOfBinary: fill = FillLandscapeValues; break; case LandscapeFilling.Random: fill = FillLandscapeRandom; break; } if (fill == null) { return; } for (int i = 0; i < S; i++) { fill(i); } }
protected RandomBase(int L, int S, LandscapeFilling lf) : this() { this.L = L; this.S = S; FillLandscape(lf); }
public MonteCarlo(int L, int S, int N, LandscapeFilling l) : base(L, S, l) { landscapeFilling = l; this.N = N; }