|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--net.aerith.misao.util.Quadrics
The Quadrics
represents a quadric function of x and y.
It consists of 6 coefficients from A to F which represent:
z = A + Bx + Cy + Dxx + Exy + Fyy
Field Summary | |
private double |
A
The constant item. |
private double |
B
The coefficient of x. |
private double |
C
The coefficient of y. |
private double |
D
The coefficient of x^2. |
private int |
data_count
The number of (x,y,z) data to solve the simultaneous equation. |
private double |
E
The coefficient of x y. |
private double |
F
The coefficient of y^2. |
private SimultaneousEquation |
se
The simultaneous equation to solve this quadric function. |
Constructor Summary | |
Quadrics()
Constructs an empty Quadrics . |
Method Summary | |
static Quadrics |
create(java.lang.String string)
Creates a Quadrics object from the String
object which represents the quadric function. |
java.lang.String |
getOutputString()
Returns a string representation of the state of this object. |
Position |
getPeak()
Calculates the peak (x,y). |
double |
getValue(double x,
double y)
Gets z value of the specified (x,y). |
Quadrics |
negative()
Creates a negative quadric function of this one. |
void |
setData(double x,
double y,
double z)
Adds a (x,y,z) data to solve the simultaneous equation. |
void |
solve()
Solves the simultaneous equation and calculates this quadric function in the least square method. |
Methods inherited from class java.lang.Object |
|
Field Detail |
private double A
private double B
private double C
private double D
private double E
private double F
private SimultaneousEquation se
private int data_count
Constructor Detail |
public Quadrics()
Quadrics
.Method Detail |
public double getValue(double x, double y)
x
- the x value.y
- the y value.public void setData(double x, double y, double z)
x
- the x value.y
- the y value.z
- the z value.public void solve()
public Quadrics negative()
public static Quadrics create(java.lang.String string)
Quadrics
object from the String
object which represents the quadric function.string
- the string which represents the quadric function.Quadrics
of the specified string.public Position getPeak()
public java.lang.String getOutputString()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |