int_from_prime_division(pd)
Instance Public methods
Re-composes a prime factorization and returns the product.
Parameters
- pd
-
Array of pairs of integers. The each internal pair consists of a prime number â a prime factor â and a natural number â an exponent.
Example
For [[p_1, e_1], [p_2, e_2], ...., [p_n, e_n]]
, it returns:
1 2 3 | p_1**e_1 * p_2**e_2 * .... * p_n**e_n. Prime.int_from_prime_division([[ 2 , 2 ], [ 3 , 1 ]]) #=> 12 |
Please login to continue.