public function __construct($dimension) { if ($dimension < 1) { throw new LogicException('a space dimension cannot be null or negative'); } $this->dimension = $dimension; }