Can you provide a proof for the following claim: >Let $P_m(x)=2^{-m}\cdot \left(\left(x-\sqrt{x^2-4})^m+(x+\sqrt{x^2-4}\right)^m\right)$ . Let $N= 4kp^n+1 $ such that $p$ is a prime number greater than $3$ , $k$ is an odd natural number , $3 \nmid k$ , $n\ge1$ and $4k <p^n$. Let $S_i=P_p(S_{i-1})$ with $S_0=P_{k}(10)$, then $N$ is a prime iff $S_{n} \equiv 0 \pmod{N}$ . You can run this test [here][1]. I have verified this claim for $k \in [1,300]$ with $p \in [5,109]$ and $n \in [1,50]$ . [1]: https://sagecell.sagemath.org/?z=eJxtjbEOgjAURXcT_wEZSAtNpCjT47k4OUhM2E0UatoAbVMajH9vGdTF7d5zc3J7LMEi56BxV8J6pR5kn_aVveooSSJ9yFmNAaQBZBwaPJuOFKk1QyvF_TVJMZOeccbzbUFZTaH1Djk8pRoECblCzf5KNkjNz8mQUwjfDWLOrFPak_ji1Cg2Mf30oxmtmZRf2Bee9HwbVBcJ7Z0S0zLBG9QMQDo=&lang=gp&interacts=eJyLjgUAARUAuQ==