![]() |
![]() |
#1 |
May 2004
31610 Posts |
![]()
Using pari how do we plot graphs: For example would be glad to receive step by step instructions to plot
2^n+ 7. tks |
![]() |
![]() |
![]() |
#2 | |
Romulan Interpreter
Jun 2011
Thailand
11·853 Posts |
![]() Quote:
step 2: write at the command prompt: plot(x=-10,10,2^x+7) and press enter ![]() Code:
(12:40:06) gp > ?plot plot(X=a,b,expr,{Ymin},{Ymax}): crude plot of expression expr, X goes from a to b, with Y ranging from Ymin to Ymax. If Ymin (resp. Ymax) is not given, the minima (resp. the maxima) of the expression is used instead. (12:40:10) gp > plot(x=-10,10,2^x+7) 1031 |''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''" | : | :| | :| | x| | :| | : | | _ | | : | | : | | x | | | | _ | | | | x | | _ | | | | _" | | _ | | _" | | __x" | 0 ________________________________xxxxxxxxxxxxx""",,,,,,,,,,,,,,,, -10 10 (12:40:54) gp > Last fiddled with by LaurV on 2012-08-21 at 05:43 Reason: code |
|
![]() |
![]() |
![]() |
#3 |
May 2004
22×79 Posts |
![]()
Thank you very much; will try.
|
![]() |
![]() |
![]() |
#4 |
May 2004
22·79 Posts |
![]()
Thanks once again. Just tried- success!
|
![]() |
![]() |
![]() |
#5 |
Romulan Interpreter
Jun 2011
Thailand
24A716 Posts |
![]()
you can type "?10" at pari prompt (without quotes) for help on plotting functions. If you have the bitmaps associated with some application (like ms fax wiewer, ACDSee, whatever) then you can also use "ploth" function. That would make a nice bitmap/jpg/gif from your graphic and send it to the associated application, so you can see it on screen in a nice graphic mode.
Try: ploth(x=-10,10,sin(x)/x) |
![]() |
![]() |
![]() |
#6 | |
"Forget I exist"
Jul 2009
Dumbassville
203008 Posts |
![]() Quote:
Last fiddled with by science_man_88 on 2012-08-22 at 14:01 |
|
![]() |
![]() |
![]() |
#7 | |
May 2004
22×79 Posts |
![]() Quote:
Code:
? plot(x=-5,5,sqrt(25-x^2)) 4.9993701 |''''''''''''''''''''''__xxx""""""""xxx__''''''''''''''''''''''| | _xx" "xx_ | | _x" "x_ | | _x x_ | | _" "_ | | _x x_ | | _ _ | | x x | | " " | | " " | | " " | | " " | | x x | | | | " " | | | |x x| |: :| |: :| : : : : 0 _,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,_ -5 5 (10:20) gp > Last fiddled with by Batalov on 2012-08-28 at 05:16 Reason: wrapped in [code] |
|
![]() |
![]() |
![]() |
#8 |
May 2004
4748 Posts |
![]()
Reading GPRC: /cygdrive/c/Program Files/PARI/.gprc ...Done.
GP/PARI CALCULATOR Version 2.3.4 (released) i686 running cygwin (ix86/GMP-4.2.1 kernel) 32-bit version compiled: Jul 12 2008, gcc-3.4.4 (cygming special, gdc 0.12, using dmd 0.125) (readline v5.2 enabled, extended help available) Copyright (C) 2000-2006 The PARI Group PARI/GP is free software, covered by the GNU General Public License, and comes WITHOUT ANY WARRANTY WHATSOEVER. Type ? for help, \q to quit. Type ?12 for how to get moral (and possibly technical) support. parisize = 4000000, primelimit = 500000 (10:20) gp > plot(x=-5,5,sqrt(25-x^2)) 4.9993701 |''''''''''''''''''''''__xxx""""""""xxx__''''''''''''''''''''''| | _xx" "xx_ | | _x" "x_ | | _x x_ | | _" "_ | | _x x_ | | _ _ | | x x | | " " | | " " | | " " | | " " | | x x | | | | " " | | | |x x| |: :| |: :| : : : : 0 _,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,_ -5 5 (10:20) gp >The above is actually a semi-circle; how do I program a full circle pl? |
![]() |
![]() |
![]() |
#9 |
Romulan Interpreter
Jun 2011
Thailand
222478 Posts |
![]()
How about "ploth(X=0,2*Pi,[sin(X),cos(X)],1)" ?
|
![]() |
![]() |
![]() |
#10 |
Romulan Interpreter
Jun 2011
Thailand
24A716 Posts |
![]()
It doesn't make too much sense to ask the same question over and over...
|
![]() |
![]() |
![]() |
#11 |
Jun 2003
32×547 Posts |
![]()
Something that almost works
![]() Code:
plot(x=-5,5,sqrt(25-x^2)); plot(x=-5,5,-sqrt(25-x^2)) |
![]() |
![]() |
![]() |
Thread Tools | |
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
What is best in life? Is it PARI/GP? | JM Montolio A | Lounge | 11 | 2018-03-08 06:26 |
Pari/GP to PFGW | carpetpool | Programming | 6 | 2017-12-21 06:04 |
LLL in GP/Pari | paul0 | Programming | 2 | 2015-11-17 13:04 |
PARI vs GAP | skan | Miscellaneous Math | 0 | 2012-12-16 00:13 |
64-bit Pari? | CRGreathouse | Software | 2 | 2009-03-13 04:22 |