public override object Evaluate()
        {
            Complex value  = LeftExpression.EvaluateAsComplex();
            int     digits = RightExpression.EvaluateAsInt32();

            return(Complex.Round(value, digits));
        }
        public override object Evaluate()
        {
            CMatrix m     = LeftExpression.EvaluateAsCMatrix();
            int     order = RightExpression.EvaluateAsInt32();

            return(MathStats.PopulationCentralMoment(m, order));
        }
        public override object Evaluate()
        {
            CPolynomial poly  = LeftExpression.EvaluateAsCPolynomial();
            int         order = RightExpression.EvaluateAsInt32();

            return(new CMatrix(poly.NthDerivative(order).ToArray()));
        }
Beispiel #4
0
        public override object Evaluate()
        {
            int rows = LeftExpression.EvaluateAsInt32();
            int cols = RightExpression.EvaluateAsInt32();

            PerformanceManager.Current.EnsureAcceptableArraySize(rows * cols);

            return(new CMatrix(rows, cols));
        }
        public override object Evaluate()
        {
            double rate  = LeftExpression.EvaluateAsReal();
            int    count = RightExpression.EvaluateAsInt32();

            PerformanceManager.Current.EnsureAcceptableArraySize(count);

            double[] v = new double[count];
            new ExponentialDistribution(rate).GetRandomVariables(_random, v);
            return(new CMatrix(v));
        }
Beispiel #6
0
 public override object Evaluate()
 {
     return(LeftExpression.EvaluateAsCMatrix().GetColumn(RightExpression.EvaluateAsInt32()));
 }
Beispiel #7
0
 public override object Evaluate()
 {
     return((Complex)Combinatorics.Permutations(LeftExpression.EvaluateAsInt32(), RightExpression.EvaluateAsInt32()));
 }