KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > math > complex > Main


1 /*
2  * Main.java
3  *
4  * Created on April 14, 2005, 3:17 PM
5  *
6  * To change this template, choose Tools | Options and locate the template under
7  * the Source Creation and Management node. Right-click the template and choose
8  * Open. You can then make changes to the template in the Source Editor.
9  */

10
11 package math.complex;
12 import math.RealComplexINumber;
13
14 /**
15  *
16  * @author jungi
17  */

18 public class Main {
19     
20     /** Creates a new instance of Main */
21     public Main() {
22     }
23     
24     /**
25      * @param args the command line arguments
26      */

27     public static void main(String JavaDoc[] args) {
28         RealComplexINumber cn1 = new RealComplexINumber(1, 1);
29         System.out.println(cn1.toString());
30
31         // TODO code application logic here
32
/*
33         System.out.println();
34         System.out.println("plus:");
35         System.out.println(new ComplexNumber(1, 1).plus(new ComplexNumber(1,1)));
36         System.out.println(new ComplexNumber(-1, -1).plus(new ComplexNumber(1,1)));
37         System.out.println(new ComplexNumber(-3, -9).plus(new ComplexNumber(7,19)));
38         System.out.println();
39         System.out.println("minus:");
40         System.out.println(new ComplexNumber(1, 1).minus(new ComplexNumber(1,1)));
41         System.out.println(new ComplexNumber(-1, -1).minus(new ComplexNumber(1,1)));
42         System.out.println(new ComplexNumber(-3, -9).minus(new ComplexNumber(7,19)));
43          */

44     }
45     
46 }
47
Popular Tags