コード例 #1
0
        /// <summary>
        /// Умножение монома на моном
        /// </summary>
        /// <param name="a"></param>
        /// <param name="b"></param>
        /// <returns></returns>
        public static ComplexMonom operator *(ComplexMonom a, ComplexMonom b)
        {
            ComplexMonom c = new ComplexMonom();

            c.Coefficient = a.Coefficient * b.Coefficient;
            c.Degree      = a.Degree + b.Degree;
            return(c);
        }
コード例 #2
0
 /// <summary>
 /// Изменяет знак коэффициента
 /// </summary>
 /// <returns></returns>
 static public ComplexMonom Negate(ComplexMonom a)
 {
     return(new ComplexMonom(a.Degree, Complex.Negate(a.Coefficient)));
 }