Here we derive a formula describing the minimum number of moves a knight needs to go from the origin $(0,0)$ to a point $(m,n)$. We encode the $8$ different knight moves algebraically by
\begin{align*}
xy^2, x^2y, x^2y^{-1},xy^{-2},x^{-1}y^{-2}, x^{-2}y^{-1},x^{-2}y,x^{-1}y^2
\end{align*}
where for instance $xy^2$ means one horizontal step to the right and two vertical steps up. At first we look at the graphic where the number of moves is given for a distance up to $6$ from the origin and we check if we can find some patterns.

The graphic:
We see due to symmetry of the knight moves it is sufficient to consider the points $(x,y)$ in the first quadrant. We even see the symmetry between the first and second octant, so that is sufficient to restrict the analysis to the first octant
\begin{align*}
0\leq y\leq x
\end{align*}
Let's focus on the red colored $6$ at position $(12,4)$, which means that the knight needs a minimum number of $6$ moves to go from $(0,0)$ to $(12,4)$. Let's go back from $(12,4)$ to $(0,0)$. A convenient way is to successively move $x^{-2}y^{-1}$ till the $x$-axes is touched. This is indicated by the red dashed line which touches the $x$-axis at $(4,0)$. Here we need $y=4$ moves to go back from $(12,4)$ to $(4,0)$ and since $(4,0)$ is marked with $2$ we have to add $2$ to the $4$ moves giving a total of $6$ moves.
Going back from $(x,y)$ using $x^{-2}y^{-1}$ steps does not always touch the $x$-axis as we can see when starting from the green marked $6$ at position $(9,7)$. Following the green dashed line we see we touch the diagonal $x=y$ before the $x$-axis which is the other boundary of the first octant. Starting at $(9,7)$ we go $2$ moves back till $(5,5)$ (note: $y-x=9 - 7=2$). The point $(5,5)$ is marked with $4$ meaning that we have $4$ moves to add to $2$ giving a total of $6$ moves.
When do we touch the $x$-axis and when the diagonal? We observe:
If $x>2y$ we can write $(x,y)$ as
\begin{align*}
(x,y)=(x-2y,0)+(2y,y)\tag{1}
\end{align*}
which means we go $y$ times a move $x^{-2}y^{-1}$ from $(x,y)$ backwards till we touch the $x$-axis at $(x-2y,0)$.
If $x\leq 2y$ we can write $(x,y)$ as
\begin{align*}
(x,y)=(2y-x,2y-x)+(2x-2y,x-y)\tag{2}
\end{align*}
which means we go $x-y$ times a move $x^{-2}y^{-1}$ from $(x,y)$ backwards till we touch the diagonal at $(2y-x,2y-x)$.
In order to find a formula for the minimal number of moves from $(0,0)$ to $(x,y)$ we have to find the number of moves along the $x$-axis and the diagonal. Then we can add $y$ resp. $x-y$ moves depending on case (1) or (2).
$x$-axis:
Let $a(x,y)$ denote the minimal number of moves from $(0,0)$ to $(x,y)$, with $(x,y)$ a point in the first octant. We look at the values at the $x$-axis and see starting with $(x,0)=(2,0)$ a sequence organised in groups of $4$ values
\begin{align*}
\begin{array}{r|cccccccccccccccc}
x&2&3&4&5&&6&7&8&9&&10&11&12&13&&\ldots\\
a(x,0)&2&3&2&3&\ &4&5&4&5&\ &6&7&6&7&&\ldots\tag{3}
\end{array}
\end{align*}
We derive from (3) by inspection for $x\geq 2$:
\begin{align*}
\color{blue}{a(4n+k,0)=2n+k\qquad }&\color{blue}{n\geq 0, 0\leq k\leq 3}\tag{4}\\
\end{align*}
We have the grey marked special case $a(1,0)=3$ which does not fit the formula (4) and which is therefore considered separately.
Diagonal:
We look at the values at the diagonal and see starting with $(x,y)=(3,3)$ a sequence organised in groups of $3$ values
\begin{align*}
\begin{array}{r|cccccccccccccccc}
x&3&4&5&&6&7&8&&9&10&11&&\ldots\\
a(x,x)&2&4&4&\ &4&6&6&\ &6&8&8&&\ldots\tag{5}
\end{array}
\end{align*}
We derive from (5) by inspection for $x\geq 3$:
\begin{align*}
\color{blue}{a(3n,3n)=2n\qquad }&\color{blue}{n\geq 0}\tag{6}\\
\color{blue}{a(3n+k,3n+k)=2n+2\qquad}&\color{blue}{n\geq 0, k=1,2}
\end{align*}
We have the grey marked special case $a(2,2)=4$ which does not fit the formula (6) and which is therefore considered separately.
A formula:
We are now well prepared to derive a formula for $a(x,y)$ with $0\leq y\leq x$.
Case $x>2y$:
Excluding the special case $a(1,0)=1$ we obtain from (1), (3) and (4):
\begin{align*}
(x,y)&=(x-2y,0)+(2y,y)\\
\color{blue}{a(x,y)}&=2\left\lfloor\frac{x-2y}{4}\right\rfloor+\left((x-2y)-4\left\lfloor\frac{x-2y}{4}\right\rfloor\right)+y\\
&\,\,\color{blue}{=x-y-2\left\lfloor\frac{x-2y}{4}\right\rfloor}
\end{align*}
Case $x\leq 2y$:
Excluding the special case $a(2,2)=4$ we obtain from (2), (5) and (6):
\begin{align*}
(x,y)&=(2y-x,2y-x)+(2x-2y,x-y)\\
\color{blue}{a(x,y)}&\color{blue}{=
\begin{cases}
2\left\lfloor\frac{2y-x}{3}\right\rfloor+x-y&2y-x\equiv 0(3)\\
\\
2\left\lfloor\frac{2y-x}{3}\right\rfloor+2+x-y&2y-x\not \equiv 0(3)\\
\end{cases}}
\end{align*}
Special cases:
Finally we list the two special cases
\begin{align*}
\color{blue}{a(1,0)=1}\\
\color{blue}{a(2,2)=4}
\end{align*}
which are due to the specific moves of the knight near the origin $(0,0)$ where also $a(2,-1)=a(-1,2)=1$ outside the first octant are needed to reach $(1,1)$ in a minimum number of $a(1,1)=2$ moves.