Ejemplo n.º 1
0
        public Vektor Multiplizieren(double a)
        {
            Vektor ergebnis = new Vektor(this);

            for (int i = 0; i < this.wert.Length; i++)
            {
                ergebnis[i] = this.wert[i] * a;
            }

            return(ergebnis);
        }
Ejemplo n.º 2
0
        public Vektor Subtrahieren(Vektor v)
        {
            if (v.wert.Length != this.wert.Length)
            {
                throw new RankException();
            }
            Vektor ergebnis = new Vektor(v);

            for (int i = 0; i < this.wert.Length; i++)
            {
                ergebnis[i] = this.wert[i] - v.wert[i];
            }

            return(ergebnis);
        }
Ejemplo n.º 3
0
        public double Multiplizieren(Vektor v)
        {
            if (v.wert.Length != this.wert.Length)
            {
                throw new RankException();
            }
            double ergebnis = 0;

            for (int i = 0; i < this.wert.Length; i++)
            {
                ergebnis += this.wert[i] * v.wert[i];
            }

            return(ergebnis);
        }
Ejemplo n.º 4
0
 public Vektor(Vektor v)
 {
     this.wert = v.wert;
 }