コード例 #1
0
		public void GetSum()
		{
			ComplexFloatVector a = new ComplexFloatVector(new float[4] { 0, 1, 2, 3 });
			ComplexFloatVector b = new ComplexFloatVector(new float[4] { 4, 5, 6, 7 });

			Assert.AreEqual(a.GetSum(), (ComplexFloat)6);
			Assert.AreEqual(6, a.GetSumMagnitudes());

			Assert.AreEqual(b.GetSum(), (ComplexFloat)22);
			Assert.AreEqual(22, b.GetSumMagnitudes());
		}