Thread: Power number
View Single Post
Old 2020-08-01, 16:08   #1
Citrix
 
Citrix's Avatar
 
Jun 2003

62616 Posts
Default Power number

Given a natural number N is there a fast way to test if the number is of the form k*b^n+-c where b^n contributes to 99% size of N; c<m*n where m is small.

Brute force could be one way:- calculating N%b, N%b^2 ... and checking if they are all same.

Anything faster? Would taking log of N help?
Citrix is offline   Reply With Quote