A computer-implemented method of compiling a target single-qubit unitary into a Repeat-Until-Success circuit that can be implemented by a quantum processor, the method comprising: establishing a rational cyclotomic approximation of a target single-qubit unitary to a requested precision by using an integer relation algorithm to find a relation between (cos(θ / 2) - sin(θ / 2)), 2 cos θ / 2, ( cos ( θ / 2) + sin ( θ / 2)), 2 sin θ / 2 where θ denotes a selected rotation angle and wherein the target unitary is an axial rotation and is approximated by z*/z wherein z is a cyclotomic integer and wherein establishing the rational cyclotomic approximation of the target single-qubit unitary comprises establishing the rational cyclotomic approximation of the target single-qubit unitary so as to solve a required norm equation; modifying z by randomly selecting at least one value of r ∈ Z 2 such that the norm equation is solvable for z replaced by rz wherein a single-qubit matrix defined by z and r is of the form 1 2 L rz y − y ∗ r ∗ z ∗ and the norm equation is |y | 2 = 2 L - | rz | 2, wherein L is a positive integer; expanding the rational cyclotomic approximation into a multi-qubit unitary that implements the target single-qubit unitary upon successful measurement; defining the multiple-qubit unitary based on the rational cyclotomic approximation, wherein the multi-qubit unitary is a multi-qubit unitary defined with respect to at least one ancillary qubit and a primary qubit; decomposing the multi-qubit unitary into a Clifford+T circuit; and providing the Repeat-Until-Success circuit that can be implemented on the quantum processor based on the decomposition wherein at least one value of r is selected so as to boost the one-round probability of success p(r) =| rz | 2 /2 L of the RUS circuit and the probability of success is proportional to a square of a magnitude of the product of r and z. establishing a rational cyclotomic approximation of a target single-qubit unitary to a requested precision by using an integer relation algorithm to find a relation between (cos(θ / 2) - sin(θ / 2)), 2 cos θ / 2, ( cos ( θ / 2) + sin ( θ / 2)), 2 sin θ / 2 where θ denotes a selected rotation angle and wherein the target unitary is an axial rotation and is approximated by z*/z wherein z is a cyclotomic integer and wherein establishing the rational cyclotomic approximation of the target single-qubit unitary comprises establishing the rational cyclotomic approximation of the target single-qubit unitary so as to solve a required norm equation; modifying z by randomly selecting at least one value of r ∈ Z 2 such that the norm equation is solvable for z replaced by rz wherein a single-qubit matrix defined by z and r is of the form 1 2 L rz y − y ∗ r ∗ z ∗ and the norm equation is |y | 2 = 2 L - | rz | 2, wherein L is a positive integer; expanding the rational cyclotomic approximation into a multi-qubit unitary that implements the target single-qubit unitary upon successful measurement; defining the multiple-qubit unitary based on the rational cyclotomic approximation, wherein the multi-qubit unitary is a multi-qubit unitary defined with respect to at least one ancillary qubit and a primary qubit; decomposing the multi-qubit unitary into a Clifford+T circuit; and providing the Repeat-Until-Success circuit that can be implemented on the quantum processor based on the decomposition wherein at least one value of r is selected so as to boost the one-round probability of success p(r) =| rz | 2 /2 L of the RUS circuit and the probability of success is proportional to a square of a magnitude of the product of r and z.