find the number of possible solution for the given the condition

Правка en1, от liveoverflow, 2020-03-30 18:12:04

Given an integer X. Your task is to find out how many positive integers n ( 1 <= n <= X) satisfies the following condition:-

$$$na^n \equiv \, b(mod\,p)$$$

Constraints:
2 <= p <= 106,
1 <= a,b< p,
1 <= X <= 1012
I have no idea how to solve this question, any approach or proof will be highly helpful.

Thanks.

Теги maths, #modular arithmetic, discrete math, #algorithms

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en9 Английский liveoverflow 2020-03-31 10:56:42 6
en8 Английский liveoverflow 2020-03-31 10:55:09 311 Tiny change: 'nts: \n$$2⩽p⩽1061⩽a,b<p1⩽X⩽2012\begin{ali' -> 'nts: \n$$\begin{ali'
en7 Английский liveoverflow 2020-03-31 09:40:54 4
en6 Английский liveoverflow 2020-03-31 09:40:09 17 Reverted to en3
en5 Английский liveoverflow 2020-03-31 09:39:57 6 Reverted to en1
en4 Английский liveoverflow 2020-03-31 09:39:41 11 Reverted to en2
en3 Английский liveoverflow 2020-03-31 09:21:38 11 Tiny change: 'Given an integer X,p,a,b. ' -> 'Given X,p,a,b. '
en2 Английский liveoverflow 2020-03-31 09:20:51 6 Tiny change: ' integer X. Your tas' -> ' integer X,p,a,b. Your tas'
en1 Английский liveoverflow 2020-03-30 18:12:04 393 Initial revision (published)