Package gprover
Class CNdg
- java.lang.Object
-
- gprover.CNdg
-
public class CNdg extends java.lang.ObjectThe CNdg class represents a geometric non-degenerate condition. It includes properties for dependent constructions, equivalent conditions, existence flag, type, number, points, and a string description.
-
-
Field Summary
Fields Modifier and Type Field Description java.lang.ObjectdepThe dependent construction.java.lang.ObjectequThe equivalent conditions.booleanexistsThe existence flag.static intMAX_GEOThe maximum number of geometric objects.intnoThe number of points.int[]pThe array of points.inttypeThe type of the geometric condition.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddAllPt(int[] p1)Adds all points from the specified array to the condition.voidaddAPt(int pt)Adds a point to the condition.booleancontain(int pt)Checks if the condition contains the specified point.booleancontain2(int a, int b)Checks if the condition contains the specified points.intgetMaxInt()Gets the maximum integer value from the points array.intgetRedundentPt()Gets the redundant point in the condition.booleanredundentPt()Checks if there are redundant points in the condition.java.lang.StringtoString()Returns a string representation of the geometric condition.
-
-
-
Field Detail
-
MAX_GEO
public static final int MAX_GEO
The maximum number of geometric objects.- See Also:
- Constant Field Values
-
dep
public java.lang.Object dep
The dependent construction.
-
equ
public java.lang.Object equ
The equivalent conditions.
-
exists
public boolean exists
The existence flag.
-
type
public int type
The type of the geometric condition.
-
no
public int no
The number of points.
-
p
public int[] p
The array of points.
-
-
Constructor Detail
-
CNdg
public CNdg()
Constructs a CNdg object with default values.
-
CNdg
public CNdg(CNdg c1)
Constructs a CNdg object by copying another CNdg object.- Parameters:
c1- the CNdg object to copy
-
-
Method Detail
-
getMaxInt
public int getMaxInt()
Gets the maximum integer value from the points array.- Returns:
- the maximum integer value from the points array
-
toString
public java.lang.String toString()
Returns a string representation of the geometric condition.- Overrides:
toStringin classjava.lang.Object- Returns:
- the string description of the geometric condition
-
contain2
public boolean contain2(int a, int b)Checks if the condition contains the specified points.- Parameters:
a- the first pointb- the second point- Returns:
- true if the condition contains the specified points, false otherwise
-
contain
public boolean contain(int pt)
Checks if the condition contains the specified point.- Parameters:
pt- the point to check- Returns:
- true if the condition contains the specified point, false otherwise
-
redundentPt
public boolean redundentPt()
Checks if there are redundant points in the condition.- Returns:
- true if there are redundant points, false otherwise
-
addAPt
public void addAPt(int pt)
Adds a point to the condition.- Parameters:
pt- the point to add
-
addAllPt
public void addAllPt(int[] p1)
Adds all points from the specified array to the condition.- Parameters:
p1- the array of points to add
-
getRedundentPt
public int getRedundentPt()
Gets the redundant point in the condition.- Returns:
- the redundant point, or 0 if there are no redundant points
-
-