Offset URM Program is Primitive Recursive

Theorem
There exists a primitive recursive function $\operatorname {Offset} : \N^2 \to \N$ such that, for $e, k \in \N$:


 * If $e$ does not code a URM program, then $\map {\operatorname {Offset} } {e, k} = 0$.


 * If $e$ codes a URM program $P$, then $\map {\operatorname {Offset} } {e, k}$ codes a program $P'$, with the following properties:
 * $(1): \quad$ The basic instructions of $P'$ with line numbers from $1$ to $k$ are all $\map C {0,0}$.
 * $(2): \quad$ Every Jump instruction in $P'$ is of the form $\map J {m,n,q}$, where $q > k$.
 * $(3): \quad$ $P$ and $P'$ compute the same function.