This page lists every supported Geant4 solid and its Python builder function. The full Geant4 geometry guide is at the Geant4 User Guide.
Each solid is built inside a GVolume via one of the make_* methods described below.
G4Box — Simple Box
gvolume.make_box(dx, dy, dz, lunit='mm')
| Parameter | Description |
|---|---|
dx |
half-length in X |
dy |
half-length in Y |
dz |
half-length in Z |
lunit |
length unit (default: mm) |

gvolume.make_box(30, 20, 10) # 30×20×10 mm half-lengths
gvolume.make_box(3, 2, 1, lunit='cm') # same in cm
gemc-system-template -gv G4Box -gvp '30, 20, 10' -silent
G4Tubs — Cylindrical Section or Tube
gvolume.make_tube(rin, rout, length, phistart, phitotal, lunit1='mm', lunit2='deg')
| Parameter | Description |
|---|---|
rin |
inner radius |
rout |
outer radius |
length |
half-length in Z |
phistart |
starting φ angle |
phitotal |
total φ angle |
lunit1 |
length unit (default: mm) |
lunit2 |
angle unit (default: deg) |

gvolume.make_tube(10, 20, 30, 0, 360) # full tube
gvolume.make_tube(0, 15, 25, 0, 270) # three-quarter open cylinder
gemc-system-template -gv G4Tubs -gvp '10, 20, 30, 0, 360' -silent
G4Cons — Cone or Conical Section
gvolume.make_cons(rin1, rout1, rin2, rout2, length, phi_start, phi_total,
lunit1='mm', lunit2='deg')
| Parameter | Description |
|---|---|
rin1 |
inner radius at −dz |
rout1 |
outer radius at −dz |
rin2 |
inner radius at +dz |
rout2 |
outer radius at +dz |
length |
half-length in Z |
phi_start |
starting φ angle |
phi_total |
total φ angle |

gvolume.make_cons(5, 15, 15, 25, 30, 0, 270) # hollow truncated cone, 270°
gvolume.make_cons(0, 10, 0, 20, 40, 0, 360) # solid cone, full rotation
gemc-system-template -gv G4Cons -gvp '5, 15, 15, 25, 30, 0, 270' -silent
G4Trd — Trapezoid
gvolume.make_trapezoid(dx1, dx2, dy1, dy2, z, lunit='mm')
| Parameter | Description |
|---|---|
dx1 |
half-length X at −dz |
dx2 |
half-length X at +dz |
dy1 |
half-length Y at −dz |
dy2 |
half-length Y at +dz |
z |
half-length in Z |
lunit |
length unit (default: mm) |

gvolume.make_trapezoid(20, 10, 15, 8, 25)
gemc-system-template -gv G4Trd -gvp '20, 10, 15, 8, 25' -silent
G4Trap — General Trapezoid
Three builder functions map to the three Geant4 G4Trap constructors.
11-parameter general trapezoid
gvolume.make_general_trapezoid(pDz, pTheta, pPhi,
pDy1, pDx1, pDx2, pAlp1,
pDy2, pDx3, pDx4, pAlp2,
lunit1='mm', lunit2='deg')
| Parameter | Description |
|---|---|
pDz |
half-length in Z |
pTheta |
polar angle of axis joining face centres |
pPhi |
azimuthal angle of that axis |
pDy1 |
half-length Y at −pDz |
pDx1 |
half-length X at small Y of −pDz face |
pDx2 |
half-length X at large Y of −pDz face |
pAlp1 |
tilt of −pDz face from Y axis |
pDy2 |
half-length Y at +pDz |
pDx3 |
half-length X at small Y of +pDz face |
pDx4 |
half-length X at large Y of +pDz face |
pAlp2 |
tilt of +pDz face from Y axis |

gvolume.make_general_trapezoid(25, 5, 10, 12, 15, 10, 8, 10, 12, 8, 5)
gemc-system-template -gv G4TrapG -gvp '25, 5, 10, 12, 15, 10, 8, 10, 12, 8, 5' -silent
4-parameter right-angular wedge
gvolume.make_trap_from_right_angular_wedges(pz, py, px, pltx, unit='mm')
| Parameter | Description |
|---|---|
pz |
length along Z |
py |
length along Y |
px |
length along X at the wider side |
pltx |
length along X at the narrower side (pltx ≤ px) |
unit |
length unit (default: mm) |

gemc-system-template -gv G4TrapRAW -gvp '30, 40, 50, 20' -silent
8-vertex form (24 parameters)
gvolume.make_trap_from_vertices(v1x, v1y, v1z, v2x, v2y, v2z,
v3x, v3y, v3z, v4x, v4y, v4z,
v5x, v5y, v5z, v6x, v6y, v6z,
v7x, v7y, v7z, v8x, v8y, v8z, lunit1='mm')
| Vertices | Description |
|---|---|
v1, v2 |
edge at small Y of −z face |
v3, v4 |
edge at large Y of −z face |
v5, v6 |
edge at small Y of +z face |
v7, v8 |
edge at large Y of +z face |

G4Sphere — Sphere or Spherical Shell Section
gvolume.make_sphere(rmin, rmax, sphi, dphi, stheta, dtheta,
lunit1='mm', lunit2='deg')
| Parameter | Description |
|---|---|
rmin |
inner radius |
rmax |
outer radius |
sphi |
starting φ angle |
dphi |
delta φ angle |
stheta |
starting θ angle |
dtheta |
delta θ angle |

gvolume.make_sphere(10, 20, 0, 270, 10, 120) # partial shell
gvolume.make_sphere(0, 15, 0, 360, 0, 180) # full solid sphere
gemc-system-template -gv G4Sphere -gvp '10, 20, 0, 270, 10, 120' -silent
G4Polycone — Polycone
gvolume.make_polycone(phiStart, phiTotal, zplane, iradius, oradius,
lunit1='mm', lunit2='deg')
| Parameter | Description |
|---|---|
phiStart |
starting φ angle |
phiTotal |
total φ angle |
zplane |
list of Z coordinates of cross-section planes |
iradius |
list of inner radii at each Z plane |
oradius |
list of outer radii at each Z plane |

zplane = [-30, -10, 10, 30]
iradius = [ 0, 10, 10, 0]
oradius = [ 15, 20, 20, 15]
gvolume.make_polycone(0, 360, zplane, iradius, oradius)
gemc-system-template -gv G4Polycone -gvp '0, 360, -30, -10, 10, 30, 0, 10, 10, 0, 15, 20, 20, 15' -silent