g[i3][i2][i1] = _f[node.index]; if (d!=null) { float d1 = x1-node.x(); float d2 = x2-node.y(); float d3 = x3-node.z();
/** * Locates a point. */ private PointLocation locatePoint(double x, double y, double z) { // If no tets yet, search the node list for an exact match. // Here, we use unperturbed node coordinates. if (_troot==null) { if (_nroot!=null) { Node node = _nroot; do { if (x==node.x() && y==node.y() && z==node.z()) return new PointLocation(node); node = node._next; } while (node!=_nroot); } return new PointLocation(null,false); } // Otherwise, find a good tet in which to begin the recursive search. Node nmin = _nroot; double dmin = distanceSquared(nmin,x,y,z); for (Node n:_sampledNodes) { double d = distanceSquared(n,x,y,z); if (d<dmin) { dmin = d; nmin = n; } } Tet tet = nmin._tet; return locatePoint(tet,x,y,z); }
for (int iv=0; iv<nv; ++iv) { TetMesh.Node node = _nodes[i[iv]]; float xn = node.x(); float yn = node.y(); float zn = node.z();
public String toString() { return "("+x()+","+y()+","+z()+")"; }
/** * Returns the x coordinate of this node. * @return the x coordinate. */ public final float x() { return _meshNode.x(); }