Let $n$ and $n$ are positive integers, $b>1$.
Express $n$ in $b$-basis
$$n = a\_kb^k + \cdots + a\_1b + a\_0.$$
We consider the polynomial
$$f\_{b,n}(X) = a\_kX^k + \cdots + a\_1X + a\_0 \in \mathbb{Z}[X].$$


Question 1: Let $p$ is a prime number. Then, is it true that $f\_{2,p}(X)$ is an irreducible polynomial?


I have checked this question for all $p < 10^6$, and some cases.


Question 2: Is it true that: p is prime number iff $f\_{b, p}(X)$ is an irreducible polynomial for all $b>1$?


It is clear that if $n$ is a composite number and $b$ is the least prime divisor of $n$, then $f\_{b, n}(X)$ is reducible.



irreducible polynomial with repect to prime number
The answer is yes to both questions: it is a theorem of Brillhart, Filaseta, and Odlyzko
(see corollary 2, p.1058):


<http://cms.math.ca/10.4153/CJM-1981-080-0>


