Skip to main content
A ramp is a sloped plate along a path in the plan. It climbs from one height to another at one even slope, and a landing is a flat stretch on the way. This page draws a ramp that turns through a quarter of a circle, reads its exact length, and sets a curved grid line and a column beside it.

Before you start

You have a session from Start a building. The fields of a ramp are in the Ramp API.

Write the ramp

A ramp has a path of plan points in metres, a width, the heights of its first and last point, and a thickness. This ramp has two points, [6, 0] and [0, 6], and rises 1.2 m.

A curved ramp

arcs has one entry for each segment of the path: null for a straight segment, or { through }, a point on the arc between the two points of the segment. The point [radius * √½, radius * √½] lies halfway round, so the ramp above is a quarter circle of radius 6 m. The ramp keeps its slope along the arc: the plan outline, the walkline and the 3D body follow the curve, and the 1:n label is the slope along it. An arc is checked as a wall arc is. A through point on the line between the two points is refused with arc-collinear. An arc whose radius is less than half the width of the ramp is refused with ramp-arc-tight, because the inner edge of the ramp would turn back on itself.

Add a landing

A landing sits at a station along the path: at is the distance in metres along the arc from the first point. The landing is flat, and the rest of the ramp takes the rise at an even slope. A landing 1 m long at 4.7 m puts a flat stretch on the arc.

Read the length

The length of a path with arcs is the sum of its chords and its arcs. An arc through three points has the radius of the circle through them, and the angle it spans: a point through that makes an obtuse angle at itself lies on the short way round.
For this ramp the length is 3π, which is 9.4248 m. Without a landing the slope is 1 in 7.85. With the landing of 1 m the sloped length is 8.4248 m and the slope is 1 in 7.02.

Run a curved grid line beside it

A grid line is saved in BmBuilding.grids. With arc: { through } it is the circular arc from start through that point to end, not the chord. Here grid A follows the same quarter circle as the ramp, and grid 1 is a radial line from the centre of the circle. snapToGrids snaps a point to the arc, and columnGridLocation names a column by the two grids that cross at it.
The point given to snapToGrids is 0.1 m outside the arc. The column lands on the arc, 2.5 m from the start of grid A along it (the station), and columnGridLocation gives A-1. The crossing is measured along the arc, not along the chord.

Next

Add a stair

Climb a storey in equal steps.

Ramp API

See each field of a ramp.
Last modified on November 10, 2026