FUNCTIONS OF THE DIAGRAM OBJECT
The constructor of the object takes an array
of points, and the number of points,
diagram(pointArray[], int numPoints)
The following functions are for the insertion of
the predictes:
-
insertCollinear(Point p1,Point
p2,Point p3,Point p4)
-
insertParallel(Point p1,Point
p2,Point p3,Point p4)
-
insertPerp(Point p1,Point p2,Point
p3,Point p4)
-
insertCircum(Point A,Point B,Point
C,Point D)
-
insertCyclic(Point A,Point B,Point
C,Point D)
-
insertMidPoint(Point O,Point
A,Point B)
-
insertCong(Point a,Point b,Point
c,Point d)
-
insertPerpBisector(Point a,Point
b,Point c,Point d)
-
insertEqangle(AngleNode a1,AngleNode
a2)
-
insertIncenter(Point a,Point
b,Point c,Point d)
-
insertOrthocenter(Point a,Point
b,Point c,Point d)
-
insertRatio(Point a,Point b,Point
c,Point d,double value)
These functions are used to tell the hypothesis of the problem to the object
as the input string is being parsed.
The object maintains a list of polynomial equations which represent the
constraints of the problem.
The function used to reduce the polynomial equations to a triangular
form is :
It also contains an object called DisplayFrame which opens up a frame window
on the screen showing the diagram.
To draw the diagram, following functions are used : -
-
void drawLine(int x1, int y1, int x2, int y2)
-
void drawCircle(int x,int y,int r)
-
void showPoint(char ch,int x,int y)