Skip to main content

Diameter

diameter sizes a circle — the number a drawing carries for a hole or a shaft.

In the viewport

  1. Click one circle.
  2. Click Dimension. The label appears across the circle with a ⌀ prefix; type the value and press Enter.

Double-clicking a circle's edge opens its diameter directly. Double-click the label later to change it.

The constraint bar with one circle picked and the Dimension button highlighted
One circle picked: Dimension writes a diameter.
BeforeBefore mode

The bore is drawn at ⌀20 and the bolt hole at ⌀14.

AfterAfter modediameter(bore, 30)

The bore held at ⌀30 and the bolt hole at ⌀9.

The code behind it

Two diameter statements size the bore and the bolt hole (1 DOF each); the bolt hole's position on the pitch circle comes from horizontal and a center-to-center distance.

flange.part.js
import { sketch, circle, origin } from 'fluidcad/core';
import { diameter, coincident, horizontal, distance } from "fluidcad/constraints";

sketch("xy", () => {
// A flange: a bore on the origin and one bolt hole on the pitch
// circle. Circles are dimensioned by diameter — the number a drawing
// carries for a hole or a shaft.
const bore = circle([0, 0], 20);
coincident(bore.center(), origin());
diameter(bore, 30);
const bolt = circle([40, 0], 14);
horizontal(bore.center(), bolt.center());
distance(bore.center(), bolt.center(), 45); // pitch radius
diameter(bolt, 9);
})

In code

diameter(c, 60) // 1 DOF
diameter(a, 20) // an arc can be dimensioned by diameter too

circle(center, diameter) already takes a diameter as its guess; the dimension is what makes the size hold when other constraints pull on the circle. Pair several holes with equal and dimension only one.

See also