Max Alekseyev on Thu, 01 Sep 2022 13:49:11 +0200


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

integer variants of matsolve() / matinverseimage()


PARI/GP provides function matkerint() but there are no functions like matsolveint() or matinverseimageint().
It looks like matsolvemod() with D=0 does this job, but it's undocumented.
Should be it made more explicit / documented?

Just as an  example:

? M = [2, 0, 0, -1, 1, 0; 0, -2, 1, -1, 0, 0; 0, 0, 0, 0, 0, 0; 0, 0, 0, 0, 0, 0; 0, 0, 0, 0, 0, 0; 24, 20, 25, 19, 19, 14]; v = [-2, 0, 0, 0, 0, 4]~;
? matinverseimage(M,v)
%2 = [-1, 2/5, 4/5, 0, 0, 0]~
? matsolvemod(M,0,v)
%3 = [-1, 0, 0, 0, 0, 2]~
? M * %2 == M * %3
%4 = 1


Regards,
Max