docs: @Pure
  	public static boolean intersectsTriangleAlignedBox(
  			double tx1, double ty1, double tz1,
  			double tx2, double ty2, double tz2,
  			double tx3, double ty3, double tz3,
  			double minx, double miny, double minz, 
  			double maxx, double maxy, double maxz) {
  
  		// use separating axis theorem to test overlap between triangle and box
  		// need to test for overlap in these directions:
  		// 1) the {x,y,z}-directions (actually, since we use the AABB of the triangle
  		//    we do not even need to test these)
  		// 2) normal of the triangle
  		// 3) crossproduct (edge from tri, {x,y,z}-directin)
  		//    this gives 3x3=9 more tests
  
  		double halfsizex = (maxx - minx) / 2.;
  		double halfsizey = (maxy - miny) / 2.;
  		double halfsizez = (maxz - minz) / 2.;
  
  		double boxcenterx = minx + halfsizex;
  		double boxcentery = miny + halfsizey;
  		double boxcenterz = minz + halfsizez;
  
  		// This is the fastest branch on Sun
  		// move everything so that the boxcenter is in (0,0,0)
  		double v0x = tx1 - boxcenterx;
  		double v0y = ty1 - boxcentery;
  		double v0z = tz1 - boxcenterz;
  		double v1x = tx2 - boxcenterx;
  		double v1y = ty2 - boxcentery;
  		double v1z = tz2 - boxcenterz;
  		double v2x = tx3 - boxcenterx;
  		double v2y = ty3 - boxcentery;
  		double v2z = tz3 - boxcenterz;
  
  		// compute triangle edges
  		double e0x = v1x - v0x;
  		double e0y = v1y - v0y;
  		double e0z = v1z - v0z;
  		double e1x = v2x - v1x;
  		double e1y = v2y - v1y;
  		double e1z = v2z - v1z;
  		double e2x = v0x - v2x;
  		double e2y = v0y - v2y;
  		double e2z = v0z - v2z;
  
  
  		// Bullet 3:
  		// test the 9 tests first (this was faster)
  		double fex = Math.abs(e0x);
  		double fey = Math.abs(e0y);
  		double fez = Math.abs(e0z);
  
  		//AXISTEST_X01(e0[Z], e0[Y], fez, fey);
  		if (mollerAlgorithmAxisTestX01(
  				e0z, e0y, fez, fey,
  				v0y, v0z, v2y, v2z, halfsizey, halfsizez)) {
  			return false;
  		}
  
  		//AXISTEST_Y02(e0[Z], e0[X], fez, fex);
  		if (mollerAlgorithmAxisTestY02(
  				e0z, e0x, fez, fex,
  				v0x, v0z, v2x, v2z, halfsizex, halfsizez)) {
  			return false;
  		}
  
  		//AXISTEST_Z12(e0[Y], e0[X], fey, fex);
  		if (mollerAlgorithmAxisTestZ12(
  				e0y, e0x, fey, fex,
  				v1x, v1y, v2x, v2y, halfsizex, halfsizey)) {
  			return false;
  		}
  
  
  		fex = Math.abs(e1x);
  		fey = Math.abs(e1y);
  		fez = Math.abs(e1z);
  
  		//AXISTEST_X01(e1[Z], e1[Y], fez, fey);
  		if (mollerAlgorithmAxisTestX01(
  				e1z, e1y, fez, fey,
  				v0y, v0z, v2y, v2z, halfsizey, halfsizez)) {
  			return false;
  		}
  
  		//AXISTEST_Y02(e1[Z], e1[X], fez, fex);
  		if (mollerAlgorithmAxisTestY02(
  				e1z, e1x, fez, fex,
  				v0y, v0z, v2y, v2z, halfsizey, halfsizez)) {
  			return false;
  		}
  
  		//AXISTEST_Z0(e1[Y], e1[X], fey, fex);
  		if (mollerAlgorithmAxisTestZ0(
  				e1y, e1x, fey, fex,
  				v0x, v0y, v1x, v1y, halfsizex, halfsizey)) {
  			return false;
  		}
  
  		fex = Math.abs(e2x);
  		fey = Math.abs(e2y);
  		fez = Math.abs(e2z);
  
  		//AXISTEST_X2(e2[Z], e2[Y], fez, fey);
  		if (mollerAlgorithmAxisTestX02(
  				e2z, e2y, fez, fey,
  				v0y, v0z, v1y, v1z, halfsizey, halfsizez)) {
  			return false;
  		}
  
  		//AXISTEST_Y1(e2[Z], e2[X], fez, fex);
  		if (mollerAlgorithmAxisTestY01(
  				e2z, e2x, fez, fex,
  				v0x, v0z, v1x, v1z, halfsizex, halfsizez)) {
  			return false;
  		}
  
  		//AXISTEST_Z12(e2[Y], e2[X], fey, fex);
  		if (mollerAlgorithmAxisTestZ12(
  				e2y, e2x, fey, fex,
  				v1x, v1y, v2x, v2y, halfsizex, halfsizey)) {
  			return false;
  		}
  
  		// Bullet 1:
  		// first test overlap in the {x,y,z}-directions
  		// find min, max of the triangle each direction, and test for overlap in
  		// that direction -- this is equivalent to testing a minimal AABB around
  		// the triangle against the AABB
  
  		double min, max;
  
  		// test in X-direction
  		min = MathUtil.min(v0x, v1x, v2x);
  		max = MathUtil.max(v0x, v1x, v2x);
  		if (min > halfsizex || max < -halfsizex) {
  			return false;
  		}
  
  		// test in Y-direction
  		min = MathUtil.min(v0y, v1y, v2y);
  		max = MathUtil.max(v0y, v1y, v2y);
  		if (min > halfsizey || max < -halfsizey) {
  			return false;
  		}
  
  		// test in Z-direction
  		min = MathUtil.min(v0z, v1z, v2z);
  		max = MathUtil.max(v0z, v1z, v2z);
  		if (min > halfsizez || max < -halfsizez) {
  			return false;
  		}
  
  		// Bullet 2:
  		// test if the box intersects the plane of the triangle
  		// compute plane equation of triangle: normal*x+d=0
  
  		double normalx = v1y * v2z - v1z * v2y;
  		double normaly = v1z * v2x - v1x * v2z;
  		double normalz = v1x * v2y - v1y * v2x;
  
  		return mollerAlgorithmPlaneBoxOverlap(
  				normalx, normaly, normalz,
  				v0x, v0y, v0z,
  				halfsizex, halfsizey, halfsizez);
  	}