| American Citizen on Sun, 03 May 2026 03:53:21 +0200 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
| Re: why is this happening? |
Silly me
I thought that subtracting the 2 elliptic curves would result in a vector of zeroes.
I believe that we are left with the one option to test if 2 elliptic curves are the same
? e1 = e2.
And trust that GP pari can get this right.
On Sat 2 May, 2026, at 02:31, American Citizen wrote:? Vecsmall([1]) - Vecsmall([1])
*** at top-level: Vecsmall([1])-Vecsmall([1])
*** ^--------------
*** _-_: forbidden addition t_VECSMALL + t_VECSMALL.
*** Break loop: type 'break' to go back to GP prompt
break>
Can anyone explain why this won't work?
Can't we subtract any element in GP Pari from itself and get 0 or null ?
You cannot add/subtract two vecsmalls, because the sum/difference oftwo (short) integers of 64 bits (32 on 32 bit platforms) can easily overrun64 bits. If you just want to know whether the 2 vecsmalls are equal, youcan use ==.
Hope this helps,
Loïc