PARIrefcard

PARIrefcard - PARI-GP Reference Card (PARI-GP version...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: PARI-GP Reference Card (PARI-GP version 2.2.5) Note: optional arguments are surrounded by braces {} . Starting & Stopping GP to enter GP, just type its name: gp to exit GP, type \q or quit Help describe function ? function extended description ?? keyword list of relevant help topics ??? pattern Input/Output & Defaults output previous line, the lines before % , % , % , etc. output from line n % n separate multiple statements on line ; extend statement on additional lines \ extend statements on several lines { seq 1 ; seq 2 ;} comment /* . . . */ one-line comment, rest of line ignored \\ . . . set default d to val default ( { d } , { val } , { fl } ) mimic behaviour of GP 1.39 default(compatible,3) Metacommands toggle timer on/off # print time for last result ## print % n in raw format \a n print % n in pretty format \b n print defaults \d set debug level to n \g n set memory debug level to n \gm n enable/disable logfile \l { filename } print % n in pretty matrix format \m set output mode (raw, default, prettyprint) \o n set n significant digits \p n set n terms in series \ps n quit GP \q print the list of PARI types \t print the list of user-defined functions \u read file into GP \r filename write % n to file \w n filename GP Within Emacs to enter GP from within Emacs: M-x gp , C-u M-x gp word completion h TAB i help menu window M-\c describe function M-? display T E Xd PARI manual M-x gpman set prompt string M-\p break line at column 100, insert \ M-\\ PARI metacommand \ letter M-\ letter Reserved Variable Names = 3 . 14159 Pi Eulers constant = . 57721 Euler square root of- 1 I big-oh notation O c 2003 Karim Belabas. Permissions on back. v2.16 PARI Types & Input Formats t INT . Integers n t REAL . Real Numbers n.ddd t INTMOD . Integers modulo m Mod ( n, m ) t FRAC . Rational Numbers n/m t COMPLEX . Complex Numbers x + y * I t PADIC . p-adic Numbers x + O ( p ^ k ) t QUAD . Quadratic Numbers x + y * quadgen ( D ) t POLMOD . Polynomials modulo g Mod ( f, g ) t POL . Polynomials a * x ^ n + + b t SER . Power Series f + O ( x ^ k ) t QFI / t QFR . Imag/Real bin. quad. forms Qfb ( a, b, c, { d } ) t RFRAC . Rational Functions f/g t VEC / t COL . Row/Column Vectors [ x, y, z ] , [ x, y, z ] ~ t MAT . Matrices [ x, y ; z, t ; u, v ] t LIST . Lists List ( [ x, y, z ] ) t STR . Strings "aaa" Standard Operators basic operations + ,- , * , / , ^ i=i+1 , i=i-1 , i=i*j , . . . i++ , i-- , i*=j , . . . euclidean quotient, remainder x \/ y , x \ y , x % y , divrem ( x, y ) shift x left or right n bits x << n , x >> n or shift ( x, n ) comparison operators <= , < , >= , > , == , != boolean operators (or, and, not) || , && , !...
View Full Document

Page1 / 4

PARIrefcard - PARI-GP Reference Card (PARI-GP version...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online