예제 #1
0
        /// <summary>
        ///     Creates a new object that is a copy of the current instance.
        /// </summary>
        /// <returns>
        ///     A new object that is a copy of this instance.
        /// </returns>
        public object Clone()
        {
            var clone = new EigenvalueDecomposition();

            clone.RealEigenvalues      = (double[])RealEigenvalues.Clone();
            clone.ImaginaryEigenvalues = (double[])ImaginaryEigenvalues.Clone();
            clone.H            = (double[, ])H.Clone();
            clone.n            = n;
            clone.ort          = ort;
            clone.symmetric    = symmetric;
            clone.Eigenvectors = (double[, ])Eigenvectors.Clone();
            return(clone);
        }
        /// <summary>
        ///     Creates a new object that is a copy of the current instance.
        /// </summary>
        /// <returns>
        ///     A new object that is a copy of this instance.
        /// </returns>
        public object Clone()
        {
            var clone = new JaggedEigenvalueDecomposition();

            clone.RealEigenvalues      = (double[])RealEigenvalues.Clone();
            clone.ImaginaryEigenvalues = (double[])ImaginaryEigenvalues.Clone();
            clone.H            = H.MemberwiseClone();
            clone.n            = n;
            clone.ort          = ort;
            clone.symmetric    = symmetric;
            clone.Eigenvectors = Eigenvectors.MemberwiseClone();
            return(clone);
        }