org.jscience.mathematics.geometry
Class Point3D

java.lang.Object
  extended by org.jscience.mathematics.geometry.GeometryElement
      extended by org.jscience.mathematics.geometry.AbstractPoint
          extended by org.jscience.mathematics.geometry.Point3D
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
CartesianPoint3D, HomogeneousPoint3D, IntersectionPoint3D, PointOnGeometry3D

public abstract class Point3D
extends AbstractPoint

�R�����̓_��\����?ۃN���X?B

See Also:
Vector3D, Serialized Form

Field Summary
static Point3D origin
          �R�����̌��_ (0, 0, 0)?
 
Constructor Summary
protected Point3D()
          �I�u�W�F�N�g��?
 
Method Summary
 Point3D add(Vector3D vector)
          ���̓_�ɗ^����ꂽ�x�N�g���𑫂����_��Ԃ�?
 int dimension()
          ������Ԃ�?
 double distance(Point3D mate)
          ���̓_�Ɨ^����ꂽ�_�Ƃ̊Ԃ̋�����Ԃ�?
 double distance2(Point3D mate)
          ���̓_�Ɨ^����ꂽ�_�Ƃ̊Ԃ̋����̎�?
 Point3D divide(double scale)
          ���̓_��^����ꂽ�X�P?
protected abstract  Point3D doTransformBy(boolean reverseTransform, CartesianTransformationOperator3D transformationOperator, java.util.Hashtable transformedGeometries)
          ���̓_��?
 boolean identical(Point3D mate)
          �Q�_�̓���?
 boolean is3D()
          �R�������ۂ���Ԃ�

?

 boolean isOn(ParametricCurve3D mate)
          ���̓_���^����ꂽ��?
 boolean isOn(ParametricSurface3D mate)
          ���̓_���^����ꂽ�Ȗʂ�?
 Point3D linearInterpolate(Point3D mate, double weightForThis)
          ���̓_�Ɨ^����ꂽ�_��?
 Point3D longestPoint(Point3D[] pnts)
          �^����ꂽ�_��̒���?
 Point3D longestPoint(Point3D[] pnts, int start, int end)
          �^����ꂽ�_��̎w��͈̔͂̒���?
 Point3D midPoint(Point3D mate)
          ���̓_�Ɨ^����ꂽ�_�̒��_��Ԃ�?
 Point3D multiply(double scale)
          ���̓_�ɗ^����ꂽ�X�P?
static CartesianPoint3D of(double[] components)
          CartesianPoint3D �̃C���X�^���X��?
static CartesianPoint3D of(double x, double y, double z)
          CartesianPoint3D �̃C���X�^���X��?
 PointOnCurve3D[] project(ParametricCurve3D mate)
          ���̓_����^����ꂽ��?
static Point3D[] reverseTransform(Point3D[] points, CartesianTransformationOperator3D transformationOperator, java.util.Hashtable transformedGeometries)
          �_���?
 Point3D reverseTransformBy(CartesianTransformationOperator3D transformationOperator, java.util.Hashtable transformedGeometries)
          ���̓_��?
 Vector3D subtract(Point3D mate)
          ���̓_�Ɨ^����ꂽ�_�Ƃ�?
 Point3D subtract(Vector3D vector)
          ���̓_����^����ꂽ�x�N�g����򢂽�_��Ԃ�?
 Vector3D toVector3D()
          ���̓_��R�����̃x�N�g�� (Vector3D) �ɕϊ�����?
static Vector3D[] toVector3D(Point3D[] pnts)
          �_�̔z���x�N�g�� (Vector3D) �̔z��ɕϊ�����?
static Point3D[] transform(Point3D[] points, boolean reverseTransform, CartesianTransformationOperator3D transformationOperator, java.util.Hashtable transformedGeometries)
          �_���?
static Point3D[] transform(Point3D[] points, CartesianTransformationOperator3D transformationOperator, java.util.Hashtable transformedGeometries)
          �_���?
 Point3D transformBy(boolean reverseTransform, CartesianTransformationOperator3D transformationOperator, java.util.Hashtable transformedGeometries)
          ���̓_��?
 Point3D transformBy(CartesianTransformationOperator3D transformationOperator, java.util.Hashtable transformedGeometries)
          ���̓_��?
abstract  double x()
          �_�� X ?
abstract  double y()
          �_�� Y ?
abstract  double z()
          �_�� Z ?
 
Methods inherited from class org.jscience.mathematics.geometry.AbstractPoint
isPoint
 
Methods inherited from class org.jscience.mathematics.geometry.GeometryElement
getClassName, getToleranceForAngle, getToleranceForAngleAsObject, getToleranceForDistance, getToleranceForDistance2, getToleranceForDistanceAsObject, getToleranceForParameter, getToleranceForParameterAsObject, getToleranceForRealNumber, getToleranceForRealNumberAsObject, is1D, is2D, isCurve, isFreeform, isParametric, isPlacement, isSurface, isTransformationOperator, isVector, makeIndent, output, output
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

origin

public static final Point3D origin
�R�����̌��_ (0, 0, 0)?B

Constructor Detail

Point3D

protected Point3D()
�I�u�W�F�N�g��?\�z����?B

See Also:
ConditionOfOperation
Method Detail

dimension

public int dimension()
������Ԃ�?B

?�� 3 ��Ԃ�?B

Specified by:
dimension in class GeometryElement
Returns:
�R�����Ȃ̂�?A?�� 3

is3D

public boolean is3D()
�R�������ۂ���Ԃ�

?�� true ��Ԃ�?B

Overrides:
is3D in class GeometryElement
Returns:
�R�����Ȃ̂�?A?�� true

x

public abstract double x()
�_�� X ?W�l��Ԃ���?ۃ?�\�b�h?B

Returns:
�_�� X ?W�l

y

public abstract double y()
�_�� Y ?W�l��Ԃ���?ۃ?�\�b�h?B

Returns:
�_�� Y ?W�l

z

public abstract double z()
�_�� Z ?W�l��Ԃ���?ۃ?�\�b�h?B

Returns:
�_�� Z ?W�l

add

public Point3D add(Vector3D vector)
���̓_�ɗ^����ꂽ�x�N�g���𑫂����_��Ԃ�?B

Parameters:
vector - �_�ɑ����x�N�g��
Returns:
�^����ꂽ�x�N�g���𑫂����_ (this + vector)

subtract

public Point3D subtract(Vector3D vector)
���̓_����^����ꂽ�x�N�g����򢂽�_��Ԃ�?B

Parameters:
vector - �_�����x�N�g��
Returns:
�^����ꂽ�x�N�g����򢂽�_ (this - vector)

subtract

public Vector3D subtract(Point3D mate)
���̓_�Ɨ^����ꂽ�_�Ƃ�?���Ԃ�?B

Parameters:
mate - ?����鑊��̓_
Returns:
��_��?� (this - mate)

multiply

public Point3D multiply(double scale)
���̓_�ɗ^����ꂽ�X�P?[����?悶���_��Ԃ�?B

Parameters:
scale - �X�P?[��
Returns:
(this * scale)

divide

public Point3D divide(double scale)
���̓_��^����ꂽ�X�P?[���Ŋ��B��_��Ԃ�?B

Parameters:
scale - �X�P?[��
Returns:
(this / scale)

linearInterpolate

public Point3D linearInterpolate(Point3D mate,
                                 double weightForThis)
���̓_�Ɨ^����ꂽ�_��?�^��Ԃ������ʂ�Ԃ�?B

Parameters:
mate - ?�`��Ԃ̑���ƂȂ�_
weightForThis - ��?g�ɑ΂���?d�� (����ɑ΂���?d�݂� 1 - weightForThis)
Returns:
?�`��Ԃ������ʂ̓_ (weightForThis * this + (1 - weightForThis) * mate)

midPoint

public Point3D midPoint(Point3D mate)
���̓_�Ɨ^����ꂽ�_�̒��_��Ԃ�?B

Parameters:
mate - ���_��?�߂鑊��ƂȂ�_
Returns:
���_ (0.5 * this + 0.5 * mate)

identical

public boolean identical(Point3D mate)
�Q�_�̓���?��𔻒肷��?B

Parameters:
mate - ����̑�?ۂƂȂ�_
Returns:
this �� mate ��?u�����̋��e��?�?v�ȓ�� ����̓_�ł���Ƃ݂Ȃ���� true?A����Ȃ��� false
See Also:
ConditionOfOperation

toVector3D

public Vector3D toVector3D()
���̓_��R�����̃x�N�g�� (Vector3D) �ɕϊ�����?B

Returns:
���_����̃x�N�g���Ƃ݂Ȃ����x�N�g��

toVector3D

public static Vector3D[] toVector3D(Point3D[] pnts)
�_�̔z���x�N�g�� (Vector3D) �̔z��ɕϊ�����?B

Returns:
���_����̃x�N�g���Ƃ݂Ȃ����x�N�g���̔z��

project

public PointOnCurve3D[] project(ParametricCurve3D mate)
                         throws IndefiniteSolutionException
���̓_����^����ꂽ��?�ւ̓��e�_��?�߂�?B

Parameters:
mate - ���e��?ۂ̋�?�
Returns:
�w�肳�ꂽ��?�ւ̓��e�_ (��?݂��Ȃ��Ƃ��͒���0�̔z���Ԃ�)
Throws:
IndefiniteSolutionException - �⪕s��ł���

isOn

public boolean isOn(ParametricCurve3D mate)
���̓_���^����ꂽ��?��?��?�BĂ��邩�ǂ�����Ԃ�?B

Parameters:
mate - �����?ۂ̋�?�
Returns:
��?��?��?�BĂ���� true?A�����łȂ���� false

isOn

public boolean isOn(ParametricSurface3D mate)
���̓_���^����ꂽ�Ȗʂ�?��?�BĂ��邩�ǂ�����Ԃ�?B

Parameters:
mate - �����?ۂ̋Ȗ�
Returns:
�Ȗʂ�?��?�BĂ���� true?A�����łȂ���� false

distance

public double distance(Point3D mate)
���̓_�Ɨ^����ꂽ�_�Ƃ̊Ԃ̋�����Ԃ�?B

Parameters:
mate - ������?�߂�_
Returns:
this - mate �Ԃ̋���

distance2

public double distance2(Point3D mate)
���̓_�Ɨ^����ꂽ�_�Ƃ̊Ԃ̋����̎�?��Ԃ�?B

Parameters:
mate - �����̎�?��?�߂�_
Returns:
this - mate �Ԃ̋����̎�?�

longestPoint

public Point3D longestPoint(Point3D[] pnts)
�^����ꂽ�_��̒���?A���̓_����?łɓ���_��Ԃ�?B

Parameters:
pnts - �_��
Returns:
?łɓ���_

longestPoint

public Point3D longestPoint(Point3D[] pnts,
                            int start,
                            int end)
�^����ꂽ�_��̎w��͈̔͂̒���?A���̓_����?łɓ���_��Ԃ�?B

Parameters:
pnts - �_��
start - �J�n�_�̃C���f�b�N�X (0 ~ pnts.length - 1)
end - ?I���_�̃C���f�b�N�X (0 ~ pnts.length - 1, start <= end)
Returns:
?łɓ���_

doTransformBy

protected abstract Point3D doTransformBy(boolean reverseTransform,
                                         CartesianTransformationOperator3D transformationOperator,
                                         java.util.Hashtable transformedGeometries)
���̓_��?A�^����ꂽ�􉽓I�ϊ����Z�q�ŕϊ�����?B

transformedGeometries ��?A �ϊ��O�̊􉽗v�f��L?[�Ƃ�?A �ϊ���̊􉽗v�f��l�Ƃ���n�b�V���e?[�u���ł���?B

this �� transformedGeometries ��ɃL?[�Ƃ��đ�?݂��Ȃ�?�?��ɂ�?A this �� transformationOperator �ŕϊ�������̂�Ԃ�?B ����?ۂɃ?�\�b�h�Ք�ł� this ��L?[?A �ϊ����ʂ�l�Ƃ��� transformedGeometries �ɒljB���?B

this �� transformedGeometries ��Ɋ�ɃL?[�Ƃ��đ�?݂���?�?��ɂ�?A ��?ۂ̕ϊ���?s�Ȃ킸?A���̃L?[�ɑΉ�����l��Ԃ�?B ����?��?��?ċA�I��?s�Ȃ���?B

transformedGeometries �� null �ł�?\��Ȃ�?B transformedGeometries �� null ��?�?��ɂ�?A ?�� this �� transformationOperator �ŕϊ�������̂�Ԃ�?B

Parameters:
reverseTransform - �t�ϊ�����̂ł���� true?A�����łȂ���� false
transformationOperator - �􉽓I�ϊ����Z�q
transformedGeometries - ��ɓ��l�̕ϊ���{�����􉽗v�f��܂ރn�b�V���e?[�u��
Returns:
�ϊ���̊􉽗v�f

transformBy

public Point3D transformBy(boolean reverseTransform,
                           CartesianTransformationOperator3D transformationOperator,
                           java.util.Hashtable transformedGeometries)
���̓_��?A�^����ꂽ�􉽓I�ϊ����Z�q�ŕϊ�����?B

transformedGeometries ��?A �ϊ��O�̊􉽗v�f��L?[�Ƃ�?A �ϊ���̊􉽗v�f��l�Ƃ���n�b�V���e?[�u���ł���?B

this �� transformedGeometries ��ɃL?[�Ƃ��đ�?݂��Ȃ�?�?��ɂ�?A this �� transformationOperator �ŕϊ�������̂�Ԃ�?B ����?ۂɃ?�\�b�h�Ք�ł� this ��L?[?A �ϊ����ʂ�l�Ƃ��� transformedGeometries �ɒljB���?B

this �� transformedGeometries ��Ɋ�ɃL?[�Ƃ��đ�?݂���?�?��ɂ�?A ��?ۂ̕ϊ���?s�Ȃ킸?A���̃L?[�ɑΉ�����l��Ԃ�?B ����?��?��?ċA�I��?s�Ȃ���?B

transformedGeometries �� null �ł�?\��Ȃ�?B transformedGeometries �� null ��?�?��ɂ�?A ?�� this �� transformationOperator �ŕϊ�������̂�Ԃ�?B

Parameters:
reverseTransform - �t�ϊ�����̂ł���� true?A�����łȂ���� false
transformationOperator - �􉽓I�ϊ����Z�q
transformedGeometries - ��ɓ��l�̕ϊ���{�����􉽗v�f��܂ރn�b�V���e?[�u��
Returns:
�ϊ���̊􉽗v�f

transformBy

public Point3D transformBy(CartesianTransformationOperator3D transformationOperator,
                           java.util.Hashtable transformedGeometries)
���̓_��?A�^����ꂽ�􉽓I�ϊ����Z�q�ŕϊ�����?B

transformedGeometries ��?A �ϊ��O�̊􉽗v�f��L?[�Ƃ�?A �ϊ���̊􉽗v�f��l�Ƃ���n�b�V���e?[�u���ł���?B

this �� transformedGeometries ��ɃL?[�Ƃ��đ�?݂��Ȃ�?�?��ɂ�?A this �� transformationOperator �ŕϊ�������̂�Ԃ�?B ����?ۂɃ?�\�b�h�Ք�ł� this ��L?[?A �ϊ����ʂ�l�Ƃ��� transformedGeometries �ɒljB���?B

this �� transformedGeometries ��Ɋ�ɃL?[�Ƃ��đ�?݂���?�?��ɂ�?A ��?ۂ̕ϊ���?s�Ȃ킸?A���̃L?[�ɑΉ�����l��Ԃ�?B ����?��?��?ċA�I��?s�Ȃ���?B

transformedGeometries �� null �ł�?\��Ȃ�?B transformedGeometries �� null ��?�?��ɂ�?A ?�� this �� transformationOperator �ŕϊ�������̂�Ԃ�?B

Parameters:
transformationOperator - �􉽓I�ϊ����Z�q
transformedGeometries - ��ɓ��l�̕ϊ���{�����􉽗v�f��܂ރn�b�V���e?[�u��
Returns:
�ϊ���̊􉽗v�f

reverseTransformBy

public Point3D reverseTransformBy(CartesianTransformationOperator3D transformationOperator,
                                  java.util.Hashtable transformedGeometries)
���̓_��?A�^����ꂽ�􉽓I�ϊ����Z�q�ŋt�ϊ�����?B

transformedGeometries ��?A �ϊ��O�̊􉽗v�f��L?[�Ƃ�?A �ϊ���̊􉽗v�f��l�Ƃ���n�b�V���e?[�u���ł���?B

this �� transformedGeometries ��ɃL?[�Ƃ��đ�?݂��Ȃ�?�?��ɂ�?A this �� transformationOperator �ŋt�ϊ�������̂�Ԃ�?B ����?ۂɃ?�\�b�h�Ք�ł� this ��L?[?A �ϊ����ʂ�l�Ƃ��� transformedGeometries �ɒljB���?B

this �� transformedGeometries ��Ɋ�ɃL?[�Ƃ��đ�?݂���?�?��ɂ�?A ��?ۂ̕ϊ���?s�Ȃ킸?A���̃L?[�ɑΉ�����l��Ԃ�?B ����?��?��?ċA�I��?s�Ȃ���?B

transformedGeometries �� null �ł�?\��Ȃ�?B transformedGeometries �� null ��?�?��ɂ�?A ?�� this �� transformationOperator �ŋt�ϊ�������̂�Ԃ�?B

Parameters:
transformationOperator - �􉽓I�ϊ����Z�q
transformedGeometries - ��ɓ��l�̕ϊ���{�����􉽗v�f��܂ރn�b�V���e?[�u��
Returns:
�t�ϊ���̊􉽗v�f

transform

public static Point3D[] transform(Point3D[] points,
                                  boolean reverseTransform,
                                  CartesianTransformationOperator3D transformationOperator,
                                  java.util.Hashtable transformedGeometries)
�_���?A�^����ꂽ�􉽓I�ϊ����Z�q�ŕϊ�����?B

transformedGeometries ��?A �ϊ��O�̊􉽗v�f��L?[�Ƃ�?A �ϊ���̊􉽗v�f��l�Ƃ���n�b�V���e?[�u���ł���?B

��?ۂƂȂ�_�� transformedGeometries ��ɃL?[�Ƃ��đ�?݂��Ȃ�?�?��ɂ�?A ����� transformationOperator �ŕϊ�������̂�Ԃ�?B ����?ۂɃ?�\�b�h�Ք�ł͑�?ۂƂȂ��L?[?A ���̕ϊ����ʂ�l�Ƃ��� transformedGeometries �ɒljB���?B

��?ۂƂȂ邪 transformedGeometries ��Ɋ�ɃL?[�Ƃ��đ�?݂���?�?��ɂ�?A ��?ۂ̕ϊ���?s�Ȃ킸?A���̃L?[�ɑΉ�����l��Ԃ�?B ����?��?��?ċA�I��?s�Ȃ���?B

transformedGeometries �� null �ł�?\��Ȃ�?B transformedGeometries �� null ��?�?��ɂ�?A ?�ɑ�?ۂƂȂ�_�� transformationOperator �ŕϊ�������̂�Ԃ�?B

Parameters:
points - �_��
reverseTransform - �t�ϊ�����̂ł���� true?A�����łȂ���� false
transformationOperator - �􉽓I�ϊ����Z�q
transformedGeometries - ��ɓ��l�̕ϊ���{�����􉽗v�f��܂ރn�b�V���e?[�u��

transform

public static Point3D[] transform(Point3D[] points,
                                  CartesianTransformationOperator3D transformationOperator,
                                  java.util.Hashtable transformedGeometries)
�_���?A�^����ꂽ�􉽓I�ϊ����Z�q�ŕϊ�����?B

transformedGeometries ��?A �ϊ��O�̊􉽗v�f��L?[�Ƃ�?A �ϊ���̊􉽗v�f��l�Ƃ���n�b�V���e?[�u���ł���?B

��?ۂƂȂ�_�� transformedGeometries ��ɃL?[�Ƃ��đ�?݂��Ȃ�?�?��ɂ�?A ����� transformationOperator �ŕϊ�������̂�Ԃ�?B ����?ۂɃ?�\�b�h�Ք�ł͑�?ۂƂȂ�_��L?[?A ���̕ϊ����ʂ�l�Ƃ��� transformedGeometries �ɒljB���?B

��?ۂƂȂ邪 transformedGeometries ��Ɋ�ɃL?[�Ƃ��đ�?݂���?�?��ɂ�?A ��?ۂ̕ϊ���?s�Ȃ킸?A���̃L?[�ɑΉ�����l��Ԃ�?B ����?��?��?ċA�I��?s�Ȃ���?B

transformedGeometries �� null �ł�?\��Ȃ�?B transformedGeometries �� null ��?�?��ɂ�?A ?�ɑ�?ۂƂȂ�_�� transformationOperator �ŕϊ�������̂�Ԃ�?B

Parameters:
points - �_��
transformationOperator - �􉽓I�ϊ����Z�q
transformedGeometries - ��ɓ��l�̕ϊ���{�����􉽗v�f��܂ރn�b�V���e?[�u��

reverseTransform

public static Point3D[] reverseTransform(Point3D[] points,
                                         CartesianTransformationOperator3D transformationOperator,
                                         java.util.Hashtable transformedGeometries)
�_���?A�^����ꂽ�􉽓I�ϊ����Z�q�ŋt�ϊ�����?B

transformedGeometries ��?A �ϊ��O�̊􉽗v�f��L?[�Ƃ�?A �ϊ���̊􉽗v�f��l�Ƃ���n�b�V���e?[�u���ł���?B

��?ۂƂȂ�_�� transformedGeometries ��ɃL?[�Ƃ��đ�?݂��Ȃ�?�?��ɂ�?A ����� transformationOperator �ŋt�ϊ�������̂�Ԃ�?B ����?ۂɃ?�\�b�h�Ք�ł͑�?ۂƂȂ�_��L?[?A ���̕ϊ����ʂ�l�Ƃ��� transformedGeometries �ɒljB���?B

��?ۂƂȂ邪 transformedGeometries ��Ɋ�ɃL?[�Ƃ��đ�?݂���?�?��ɂ�?A ��?ۂ̕ϊ���?s�Ȃ킸?A���̃L?[�ɑΉ�����l��Ԃ�?B ����?��?��?ċA�I��?s�Ȃ���?B

transformedGeometries �� null �ł�?\��Ȃ�?B transformedGeometries �� null ��?�?��ɂ�?A ?�ɑ�?ۂƂȂ�_�� transformationOperator �ŋt�ϊ�������̂�Ԃ�?B

Parameters:
points - �_��
transformationOperator - �􉽓I�ϊ����Z�q
transformedGeometries - ��ɓ��l�̕ϊ���{�����􉽗v�f��܂ރn�b�V���e?[�u��

of

public static CartesianPoint3D of(double x,
                                  double y,
                                  double z)
CartesianPoint3D �̃C���X�^���X��?�?�����?B

Parameters:
x - X ?���
y - Y ?���
z - Z ?���
Returns:
CartesianPoint3D �̃C���X�^���X

of

public static CartesianPoint3D of(double[] components)
CartesianPoint3D �̃C���X�^���X��?�?�����?B

Parameters:
components - X, Y?����̔z�� (�v�f?� 3)
Returns:
CartesianPoint3D �̃C���X�^���X