multiprecision Questions
6
I am trying to write a program for finding Mersenne prime numbers. Using the unsigned long long type I was able to determine the value of the 9th Mersenne prime, which is (2^61)-1. For larger value...
Cantina asked 24/3, 2013 at 17:9
2
Consider that you want to calculate the low 128-bits of the result of multiplying a 64-bit and 128-bit unsigned number, and that the largest multiplication you have available is the C-like 64-bit m...
Kandykane asked 17/8, 2018 at 19:27
1
I need to calculate dot product of two vectors: uint64_t a[N], b[N]; (N<=60) containing 64-bit unsigned integers. Precisely this loop:
unsigned __int128 ans = 0;
for(int i=0;i<N;++i)
ans +=...
Myology asked 3/1, 2020 at 8:38
1
I'm trying to use the CAMPARY library (CudA Multiple Precision ARithmetic librarY). I've downloaded the code and included it in my project. Since it supports both cpu and gpu, I'm starting with cpu...
Dioptometer asked 14/3, 2019 at 22:5
2
Solved
I am running a simulation of physical experiments, so I need really high floating point precision (more than 16 digits). I use Boost.Multiprecision, however I can't get a precision higher than 16 d...
Laellaertes asked 3/11, 2015 at 8:39
1
Solved
Do you know how to do this simple line of code without error using Boost::multiprecison ?
boost::multiprecision::cpp_int v, uMax, candidate;
//...
v += 6 * ceil((sqrt(uMax * uMax - candidate) - v)...
Haematoma asked 5/4, 2015 at 13:29
1
Solved
I am using Boost.Multiprecision for wrappers around the mpfr backend, and I am having some trouble creating pi (and e or any other math constant) to my desired precision. I feel like what I want to...
Hullda asked 13/2, 2015 at 3:2
1
I'm using the boost multiprecision library, and more precisely the boost::multiprecision::float128 type. Using ICPC for compiling, I get some errors when trying to to do something like:
double a =...
Menorca asked 30/1, 2015 at 17:43
2
Solved
I have a C program which uses GCC's __uint128_t which is great, but now my needs have grown beyond it.
What are my options for fast arithmetic with 196 or 256 bits?
The only operation I need is a...
Sulky asked 2/3, 2014 at 9:47
1
© 2022 - 2024 — McMap. All rights reserved.