The Museum of HP Calculators

HP Forum Archive 21

[ Return to Index | Top of Index ]

Prime: Quick and Dirty AXL
Message #1 Posted by Helge Gabert on 3 Oct 2013, 6:36 p.m.

Here is an attempt to duplicate the AXL utility (which I find helpful in the 50G); alas, I can't get it work with symbolic elements in either vectors or lists - - but it works with integers, reals, and complex values as elements in both HOME and CAS.

No doubt it can be optimized.

EXPORT AXL(r)
BEGIN
LOCAL b, n, j;
SIZE(r)->n;

IF TYPE(r)==4 THEN b:={}; FOR j FROM 1 TO n(1) DO CONCAT(b,r(j))->b; END;

ELSE

IF TYPE(r)==6 THEN MAKEMAT(0,n)->b; FOR j FROM 1 TO n DO r(j)->b(1,j); END;

ELSE RETURN "Error: Not list or vector"; END;

END; b; END;


[ Return to Index | Top of Index ]

Go back to the main exhibit hall