/// <summary> /// Вычитание комплексных чисел /// </summary> /// <param name="x2"></param> /// <returns></returns> public ComplexCl Minus(ComplexCl x2) { ComplexCl x3 = new ComplexCl(); x3.im = x2.im - this.im; x3.re = x2.re - this.re; return(x3); }
/// <summary> /// Произведение комплексных чисел /// </summary> /// <param name="x2"></param> /// <returns></returns> public ComplexCl Multi(ComplexCl x2) { ComplexCl x3 = new ComplexCl(); x3.im = x2.re * this.im + x2.im * this.re; x3.re = x2.re * this.re - x2.im * this.im; return(x3); }
/// <summary> /// Суммма комплексных чисел /// </summary> /// <param name="x2"></param> /// <returns></returns> public ComplexCl Plus(ComplexCl x2) { ComplexCl x3 = new ComplexCl(); x3.im = x2.im + this.im; x3.re = x2.re + this.re; return(x3); }