Ejemplo n.º 1
0
        public override Function GetDerivative(string name)
        {
            var left   = new MulFunction(new ConstValueFunction(-1.0f), new Sin(_internal.Clone()));
            var right  = _internal.GetDerivative(name);
            var result = new MulFunction(left, right);

            return(result);
        }
Ejemplo n.º 2
0
        public override Function GetDerivative(string name)
        {
            var f1 = new SubFunction(new MulFunction(_left.GetDerivative(name), _right.Clone()),
                                     new MulFunction(_left.Clone(), _right.GetDerivative(name)));
            var f2 = new MulFunction(_right.Clone(), _right.Clone());

            return(new DivideFunction(f1, f2));
        }