On Wed, Jul 20, 2016 at 10:27:50AM +0200, AB wrote:
> Hello
>
> W dniu 2016-07-17 o 17:23, Steven D'Aprano pisze:
> >[...]
> >What result did you expect? 2**-1 as an int32 cannot be 0.5, as that's a
> >float.
>
> I expected 0.5: as 2^(-1) is in fact 1/2, and as in Python 3 division of
> two inte
On Sun, Jul 17, 2016 at 02:41:33PM +0200, A.Brozi wrote:
> Hello
>
> I'm puzzling over some strange behavior of raising a matrix to a matrix
> power:
>
> If I create two matrices (containing integers):
> a = np.array([2])
> and
> b = np.array([-1])
> the operation a**b produces:
> array([0], dty
A.Brozi wrote:
> Hello
>
> I'm puzzling over some strange behavior of raising a matrix to a matrix
> power:
>
> If I create two matrices (containing integers):
> a = np.array([2])
> and
> b = np.array([-1])
> the operation a**b produces:
> array([0], dtype=int32)
>
> The result of division b/a
Hello
I'm puzzling over some strange behavior of raising a matrix to a matrix
power:
If I create two matrices (containing integers):
a = np.array([2])
and
b = np.array([-1])
the operation a**b produces:
array([0], dtype=int32)
The result of division b/a is correct:
array([-0.5])
If any one o