[−][src]Function reikna::totient::totient_all
pub fn totient_all(data: Vec<u64>) -> Vec<u64>
Calculate the value of Euler's totient function for each
value in data
, and return a new Vec<u64>
of the results.
The resulting vector has the same size as the input vector.
The computation of the totient function itself is done
through totient()
, see the documentation for that function
for more information.
Examples
use reikna::totient::totient_all; assert_eq!(totient_all(vec![1, 2, 3]), vec![1, 1, 2]); assert_eq!(totient_all(vec![81]), vec![54]);