# LinuxCNC G5.1

Instructions · `G5.1` · verification: source checked

G5.1 creates a quadratic B-spline in the XY plane using only the X and Y axes. I and J are incremental offsets from the start point to the control point on the X and Y axes respectively. An unspecified I or J offset is zero, so at least one of I or J must be given.

## Specification

| Property | Value |
|---|---|
| Language | gcode |
| Code | G5.1 |
| Syntax | G5.1 X- Y- I- J- |
| Dialect | LinuxCNC |

### Parameters

| Name | Data type | Description |
|---|---|---|
| I | real | X incremental offset from start point to control point |
| J | real | Y incremental offset from start point to control point |

## Study notes

- The active plane must be G17 (XY); G5.1 is an error if another plane is active.
- Only X and Y axis words are permitted; specifying any other axis is an error.
- Both I and J unspecified or zero is an error.
- G5.1 differs from G5: G5 creates a cubic B-spline and requires both P and Q, while G5.1 is quadratic and uses I and J offsets to one control point.
- Document example: G90 G17; G0 X-2 Y4; G5.1 X2 I2 J-8 programs a parabola through the origin from X-2 Y4 to X2 Y4.

## Sources

1. [G-Codes](https://linuxcnc.org/docs/html/gcode/g-code.html#gcode:g5.1) (accessed 2026-10-26)

---

Source page: https://machineschema.com/instruction/gcode-g05-1  
JSON: https://machineschema.com/instruction/gcode-g05-1.json  
License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Cite Machine Schema and the original sources.
