- java.lang.Object
-
- swim.math.R3
-
- All Implemented Interfaces:
Debug,AffineSpace<R3Point,R3Vector,Double>,F3<R3Vector,Double>,TensorSpace<R3Vector,Double>,VectorModule<R3Vector,Double>,VectorSpace<R3Vector,Double>
public class R3 extends Object implements AffineSpace<R3Point,R3Vector,Double>, VectorSpace<R3Vector,Double>, F3<R3Vector,Double>, Debug
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedR3()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description R3Vectoradd(R3Vector u, R3Vector v)R3Vectorcombine(Double a, R3Vector u, Double b, R3Vector v)<T> Output<T>debug(Output<T> output)Writes a developer readable, debug-formatted string representation of this object tooutput.R3Vectordifference(R3Point p, R3Point q)TensorDimsdimensions()DoublegetX(R3Vector v)DoublegetY(R3Vector v)DoublegetZ(R3Vector v)R3Vectormultiply(R3Vector u, Double a)R3Vectorof(Double x, Double y, Double z)R3Vectoropposite(R3Vector v)R3Pointorigin()Rscalar()static R3space()R3Vectorsubtract(R3Vector u, R3Vector v)StringtoString()R3Pointtranslate(R3Point p, R3Vector v)R3vector()R3Vectorzero()
-
-
-
Method Detail
-
vector
public final R3 vector()
- Specified by:
vectorin interfaceAffineSpace<R3Point,R3Vector,Double>
-
scalar
public final R scalar()
- Specified by:
scalarin interfaceAffineSpace<R3Point,R3Vector,Double>- Specified by:
scalarin interfaceTensorSpace<R3Vector,Double>- Specified by:
scalarin interfaceVectorModule<R3Vector,Double>- Specified by:
scalarin interfaceVectorSpace<R3Vector,Double>
-
dimensions
public TensorDims dimensions()
- Specified by:
dimensionsin interfaceTensorSpace<R3Vector,Double>
-
origin
public final R3Point origin()
- Specified by:
originin interfaceAffineSpace<R3Point,R3Vector,Double>
-
zero
public final R3Vector zero()
- Specified by:
zeroin interfaceTensorSpace<R3Vector,Double>- Specified by:
zeroin interfaceVectorModule<R3Vector,Double>- Specified by:
zeroin interfaceVectorSpace<R3Vector,Double>
-
add
public final R3Vector add(R3Vector u, R3Vector v)
- Specified by:
addin interfaceTensorSpace<R3Vector,Double>- Specified by:
addin interfaceVectorModule<R3Vector,Double>- Specified by:
addin interfaceVectorSpace<R3Vector,Double>
-
opposite
public final R3Vector opposite(R3Vector v)
- Specified by:
oppositein interfaceTensorSpace<R3Vector,Double>- Specified by:
oppositein interfaceVectorModule<R3Vector,Double>- Specified by:
oppositein interfaceVectorSpace<R3Vector,Double>
-
subtract
public final R3Vector subtract(R3Vector u, R3Vector v)
- Specified by:
subtractin interfaceTensorSpace<R3Vector,Double>- Specified by:
subtractin interfaceVectorModule<R3Vector,Double>- Specified by:
subtractin interfaceVectorSpace<R3Vector,Double>
-
multiply
public final R3Vector multiply(R3Vector u, Double a)
- Specified by:
multiplyin interfaceTensorSpace<R3Vector,Double>- Specified by:
multiplyin interfaceVectorModule<R3Vector,Double>- Specified by:
multiplyin interfaceVectorSpace<R3Vector,Double>
-
combine
public final R3Vector combine(Double a, R3Vector u, Double b, R3Vector v)
- Specified by:
combinein interfaceTensorSpace<R3Vector,Double>- Specified by:
combinein interfaceVectorModule<R3Vector,Double>- Specified by:
combinein interfaceVectorSpace<R3Vector,Double>
-
translate
public final R3Point translate(R3Point p, R3Vector v)
- Specified by:
translatein interfaceAffineSpace<R3Point,R3Vector,Double>
-
difference
public final R3Vector difference(R3Point p, R3Point q)
- Specified by:
differencein interfaceAffineSpace<R3Point,R3Vector,Double>
-
debug
public <T> Output<T> debug(Output<T> output)
Description copied from interface:DebugWrites a developer readable, debug-formatted string representation of this object tooutput.
-
space
public static R3 space()
-
-