* indicates optional
This feature performs three-dimensional cutter compensation.
The form is:
Subsequent lines can be:
Some CAM systems are able to output the X, Y, and Z with values for I, J, K. The I, J, and K values tell the control the direction in which to apply the compensation at the machine. Similar to other uses of I, J, and K, these are incremental distances from the X, Y, and Z point called.
The I, J, and K specify the normal direction, relative to the center of the tool, to the contact point of the tool in the CAM system. The I, J, and K vectors are required by the control to be able to shift the toolpath in the correct direction. The value of the compensation can be in a positive or negative direction.
The offset amount entered in radius or diameter (Setting 40) for the tool will compensate the path by this amount, even if the tool motions are 2 or 3 axes. Only G00 and G01 can use G141. A Dnn will have to be programmed; the D-code selects which tool wear diameter offset to use. A feedrate must be programmed on each line if in G93 Inverse Time Feed mode.
With a unit vector, the length of the vector line must always equal 1. In the same way that a unit circle in mathematics is a circle with a radius of 1, a unit vector is a line that indicates a direction with a length of 1. Remember, the vector line does not tell the control how far to move the tool when a wear value is entered, just the direction in which to go.
Only the endpoint of the commanded block is compensated in the direction of I, J, and K. For this reason, this compensation is recommended only for surface toolpaths having a tight tolerance (small motion between blocks of code). G141 compensation does not prohibit the toolpath from crossing over itself when excessive cutter compensation is entered. The tool will be offset, in the direction of the vector line, by the combined values of the tool offset geometry plus the tool offset wear. If compensation values are in diameter mode (Setting 40), the move will be half the amount entered in these fields.
For best results, program from the tool center using a ball nose endmill.
In the above example, we can see where the I, J, and K were derived by plugging the points into the following formula:
AB = [(x2-x1)2 + (y2-y1)2 + (z2-z1)2], a 3D version of the distance formula. Looking at line N1, we use 0.15 for x2, 0.25 for y2, and 0.9566 for Z2. Because I, J, and K are incremental, we will use 0 for x1, y1, and z1.Unit Vector Example: The commanded line endpoint  is compensated in the direction of the vector line (I,J,K), by the amount of the Tool Offset Wear.
A simplified example is listed below:
In this case, the wear value (DIA) for T01 is set to -.02. Line N1 moves the tool from (X0., Y0., Z0.) to (X5., Y0., Z0.). The J value tells the control to compensate the endpoint of the programmed line only in the Y Axis.
Line N1 could have been written using only the J-1. (not using I0. or K0.), but a Y value must be entered if a compensation is to be made in this axis (J value used).