Exemplo n.º 1
0
 public SystemParameters(SystemParameters p)
 {
     this.Eta                  = p.Eta;
     this.Alpha                = p.Alpha;
     this.Gamma                = p.Gamma;
     this.Beta                 = p.Beta;
     this.EtaNeg               = p.EtaNeg;
     this.dt                   = p.dt;
     this.Connectivity         = p.Connectivity;
     this.N                    = p.N;
     this.K                    = p.K;
     this.nClustes             = p.nClustes;
     this.NetType              = p.NetType;
     this.bc                   = new CoordPoint(p.bc.x, p.bc.x);
     this.DirectedNetwork      = p.DirectedNetwork;
     this.Weights              = p.Weights;
     this.SpecialPars          = DataTools.listCopy(p.SpecialPars);
     this.DynamicModelTwoState = p.DynamicModelTwoState;
 }
Exemplo n.º 2
0
 public SystemParameters(double Alpha, double Eta, double Gamma, double Beta, double EtaNeg, double dt, double Connectivity,
                         int N, double K, int nClustes, string NetType, CoordPoint bc,
                         bool DirectedNetwork, bool Weights, List <string[]> SpecialPars,
                         bool DynamicModelTwoState)
 {
     this.Eta                  = Eta;
     this.Alpha                = Alpha;
     this.Gamma                = Gamma;
     this.Beta                 = Beta;
     this.EtaNeg               = EtaNeg;
     this.dt                   = dt;
     this.Connectivity         = Connectivity;
     this.N                    = N;
     this.K                    = K;
     this.nClustes             = nClustes;
     this.NetType              = NetType;
     this.bc                   = new CoordPoint(bc.x, bc.x);
     this.DirectedNetwork      = DirectedNetwork;
     this.Weights              = Weights;
     this.SpecialPars          = DataTools.listCopy(SpecialPars);
     this.DynamicModelTwoState = DynamicModelTwoState;
 }
Exemplo n.º 3
0
        private CoordPoint[] genCoords(CoordPoint bc, bool circle)
        // NewMethod - generates coordinate points for the vertecies.
        // circle: true - get circularly distributed points. false - uniform distribution.
        {
            double x, y;
            double radStep = 2 * Math.PI / sysSize;
            var    temp    = new CoordPoint[sysSize];

            for (int i = 0; i < sysSize; i++)
            {
                if (!circle)
                {
                    x = rdn.NextDouble();
                    y = rdn.NextDouble();
                }
                else
                {
                    x = bc.x * Math.Cos(radStep * i);
                    y = bc.y * Math.Sin(radStep * i);
                }
                temp[i] = new CoordPoint(x, y);
            }
            return(temp);
        }