How can I cast np.longdouble to mpmath.mpf?
import numpy as np
import mpmath
b = np.longdouble(1.0)
a = mpmath.mpf(b)
print (a)
You will have to convert the longdouble
to np.float64
:
import numpy as np
import mpmath
b = np.longdouble(1.0)
c= np.float64(b)
a = mpmath.mpf(c)
print (a)