Is there an efficient algorithm that given an integer $n$, it finds any $a$ and $p$ such that $a$ has order $n$ in $(\mathbb Z/p\mathbb Z)^\times$?
$n$ may be moderately large, say ~$10^5$.
If it helps, the specific $n$ I have in mind is $49\times2^{11}=100352$.
Not necessarily efficient, but here is a suggestion:
$n$ must be a divisor of $p-1$, so you have to
For $n=100\,352$, a probabilistic test says that $3n+1=301\,057$ is prime.