home *** CD-ROM | disk | FTP | other *** search
open in:
MacOS 8.1
|
Win98
|
DOS
browse contents |
view JSON data
|
view as text
This file was processed as: LaTeX Document
(document/latex).
Confidence | Program | Detection | Match Type | Support
|
---|
100%
| dexvert
| LaTeX Document (document/latex)
| magic
| Supported |
1%
| dexvert
| Corel 10 Texture (image/corel10Texture)
| ext
| Unsupported |
1%
| dexvert
| Croteam texture file (image/croteamTextureFile)
| ext
| Unsupported |
1%
| dexvert
| Text File (text/txt)
| fallback
| Supported |
100%
| file
| LaTeX document text
| default
| |
99%
| file
| LaTeX document, ASCII text
| default
| |
100%
| checkBytes
| Printable ASCII
| default
| |
100%
| perlTextCheck
| Likely Text (Perl)
| default
| |
100%
| siegfried
| fmt/281 LaTeX (Subdocument)
| default
| |
100%
| detectItEasy
| Format: plain text[LF]
| default (weak)
|
|
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 5c 63 68 61 70 74 65 72 | 20 7b 53 69 6d 70 6c 65 |\chapter| {Simple|
|00000010| 20 55 73 65 20 6f 66 20 | 50 4c 50 4c 4f 54 7d 20 | Use of |PLPLOT} |
|00000020| 5c 6c 61 62 65 6c 7b 73 | 69 6d 70 6c 65 7d 0a 0a |\label{s|imple}..|
|00000030| 5c 73 65 63 74 69 6f 6e | 20 7b 50 6c 6f 74 74 69 |\section| {Plotti|
|00000040| 6e 67 20 61 20 53 69 6d | 70 6c 65 20 47 72 61 70 |ng a Sim|ple Grap|
|00000050| 68 7d 0a 57 65 20 73 68 | 61 6c 6c 20 66 69 72 73 |h}.We sh|all firs|
|00000060| 74 20 63 6f 6e 73 69 64 | 65 72 20 70 6c 6f 74 74 |t consid|er plott|
|00000070| 69 6e 67 20 73 69 6d 70 | 6c 65 20 67 72 61 70 68 |ing simp|le graph|
|00000080| 73 20 73 68 6f 77 69 6e | 67 20 74 68 65 20 64 65 |s showin|g the de|
|00000090| 70 65 6e 64 65 6e 63 65 | 20 0a 6f 66 20 6f 6e 65 |pendence| .of one|
|000000a0| 20 76 61 72 69 61 62 6c | 65 20 75 70 6f 6e 20 61 | variabl|e upon a|
|000000b0| 6e 6f 74 68 65 72 2e 20 | 53 75 63 68 20 61 20 67 |nother. |Such a g|
|000000c0| 72 61 70 68 20 6d 61 79 | 20 62 65 20 63 6f 6d 70 |raph may| be comp|
|000000d0| 6f 73 65 64 20 6f 66 20 | 73 65 76 65 72 61 6c 20 |osed of |several |
|000000e0| 0a 65 6c 65 6d 65 6e 74 | 73 3a 0a 5c 62 65 67 69 |.element|s:.\begi|
|000000f0| 6e 7b 69 74 65 6d 69 7a | 65 7d 0a 20 20 20 5c 69 |n{itemiz|e}. \i|
|00000100| 74 65 6d 20 41 20 62 6f | 78 20 77 68 69 63 68 20 |tem A bo|x which |
|00000110| 64 65 66 69 6e 65 73 20 | 74 68 65 20 72 61 6e 67 |defines |the rang|
|00000120| 65 73 20 6f 66 20 74 68 | 65 20 76 61 72 69 61 62 |es of th|e variab|
|00000130| 6c 65 73 2c 20 70 65 72 | 68 61 70 73 20 77 69 74 |les, per|haps wit|
|00000140| 68 20 61 78 65 73 0a 20 | 20 20 20 20 20 20 20 20 |h axes. | |
|00000150| 61 6e 64 20 6e 75 6d 65 | 72 69 63 20 6c 61 62 65 |and nume|ric labe|
|00000160| 6c 73 20 61 6c 6f 6e 67 | 20 69 74 73 20 65 64 67 |ls along| its edg|
|00000170| 65 73 2c 0a 20 20 20 5c | 69 74 65 6d 20 41 20 73 |es,. \|item A s|
|00000180| 65 74 20 6f 66 20 70 6f | 69 6e 74 73 20 6f 72 20 |et of po|ints or |
|00000190| 6c 69 6e 65 73 20 77 69 | 74 68 69 6e 20 74 68 65 |lines wi|thin the|
|000001a0| 20 62 6f 78 20 73 68 6f | 77 69 6e 67 20 74 68 65 | box sho|wing the|
|000001b0| 20 66 75 6e 63 74 69 6f | 6e 61 6c 20 0a 20 20 20 | functio|nal . |
|000001c0| 20 20 20 20 20 20 64 65 | 70 65 6e 64 65 6e 63 65 | de|pendence|
|000001d0| 2c 0a 20 20 20 5c 69 74 | 65 6d 20 41 20 73 65 74 |,. \it|em A set|
|000001e0| 20 6f 66 20 6c 61 62 65 | 6c 73 20 66 6f 72 20 74 | of labe|ls for t|
|000001f0| 68 65 20 76 61 72 69 61 | 62 6c 65 73 20 61 6e 64 |he varia|bles and|
|00000200| 20 61 20 74 69 74 6c 65 | 20 66 6f 72 20 74 68 65 | a title| for the|
|00000210| 20 67 72 61 70 68 2e 0a | 5c 65 6e 64 7b 69 74 65 | graph..|\end{ite|
|00000220| 6d 69 7a 65 7d 20 20 20 | 0a 49 6e 20 6f 72 64 65 |mize} |.In orde|
|00000230| 72 20 74 6f 20 64 72 61 | 77 20 73 75 63 68 20 61 |r to dra|w such a|
|00000240| 20 67 72 61 70 68 2c 20 | 69 74 20 69 73 20 6e 65 | graph, |it is ne|
|00000250| 63 65 73 73 61 72 79 20 | 74 6f 20 63 61 6c 6c 20 |cessary |to call |
|00000260| 61 74 20 6c 65 61 73 74 | 20 66 6f 75 72 20 6f 66 |at least| four of|
|00000270| 20 0a 74 68 65 20 50 4c | 50 4c 4f 54 20 66 75 6e | .the PL|PLOT fun|
|00000280| 63 74 69 6f 6e 73 3a 0a | 5c 62 65 67 69 6e 7b 65 |ctions:.|\begin{e|
|00000290| 6e 75 6d 65 72 61 74 65 | 7d 0a 20 20 20 5c 69 74 |numerate|}. \it|
|000002a0| 65 6d 20 7b 5c 74 74 20 | 70 6c 73 74 61 72 7d 2c |em {\tt |plstar},|
|000002b0| 20 74 6f 20 73 70 65 63 | 69 66 79 20 74 68 65 20 | to spec|ify the |
|000002c0| 64 65 76 69 63 65 20 79 | 6f 75 20 77 61 6e 74 20 |device y|ou want |
|000002d0| 74 6f 20 70 6c 6f 74 20 | 6f 6e 2c 0a 20 20 20 5c |to plot |on,. \|
|000002e0| 69 74 65 6d 20 7b 5c 74 | 74 20 70 6c 65 6e 76 7d |item {\t|t plenv}|
|000002f0| 2c 20 74 6f 20 64 65 66 | 69 6e 65 20 74 68 65 20 |, to def|ine the |
|00000300| 72 61 6e 67 65 20 61 6e | 64 20 73 63 61 6c 65 20 |range an|d scale |
|00000310| 6f 66 20 74 68 65 20 67 | 72 61 70 68 2c 20 61 6e |of the g|raph, an|
|00000320| 64 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |d. | |
|00000330| 20 20 20 20 20 20 20 20 | 64 72 61 77 20 6c 61 62 | |draw lab|
|00000340| 65 6c 73 2c 20 61 78 65 | 73 2c 20 65 74 63 2e 2c |els, axe|s, etc.,|
|00000350| 0a 20 20 20 5c 69 74 65 | 6d 20 4f 6e 65 20 6f 72 |. \ite|m One or|
|00000360| 20 6d 6f 72 65 20 63 61 | 6c 6c 73 20 74 6f 20 7b | more ca|lls to {|
|00000370| 5c 74 74 20 70 6c 6c 69 | 6e 65 7d 20 6f 72 20 7b |\tt plli|ne} or {|
|00000380| 5c 74 74 20 70 6c 70 6f | 69 6e 7d 20 74 6f 20 64 |\tt plpo|in} to d|
|00000390| 72 61 77 0a 20 20 20 20 | 20 20 20 20 20 6c 69 6e |raw. | lin|
|000003a0| 65 73 20 6f 72 20 70 6f | 69 6e 74 73 20 61 73 20 |es or po|ints as |
|000003b0| 6e 65 65 64 65 64 2e 20 | 4f 74 68 65 72 20 6d 6f |needed. |Other mo|
|000003c0| 72 65 20 63 6f 6d 70 6c | 65 78 20 72 6f 75 74 69 |re compl|ex routi|
|000003d0| 6e 65 73 20 69 6e 63 6c | 75 64 65 0a 20 20 20 20 |nes incl|ude. |
|000003e0| 20 20 20 20 20 7b 5c 74 | 74 20 70 6c 62 69 6e 7d | {\t|t plbin}|
|000003f0| 20 61 6e 64 20 7b 5c 74 | 74 20 70 6c 68 69 73 74 | and {\t|t plhist|
|00000400| 7d 20 74 6f 20 64 72 61 | 77 20 68 69 73 74 6f 67 |} to dra|w histog|
|00000410| 72 61 6d 73 2c 20 7b 5c | 74 74 20 70 6c 65 72 72 |rams, {\|tt plerr|
|00000420| 78 7d 20 61 6e 64 20 0a | 20 20 20 20 20 20 20 20 |x} and .| |
|00000430| 20 7b 5c 74 74 20 70 6c | 65 72 72 79 7d 20 74 6f | {\tt pl|erry} to|
|00000440| 20 64 72 61 77 20 65 72 | 72 6f 72 2d 62 61 72 73 | draw er|ror-bars|
|00000450| 2c 20 5c 6c 61 62 65 6c | 7b 64 72 61 77 7d 0a 20 |, \label|{draw}. |
|00000460| 20 20 5c 69 74 65 6d 20 | 7b 5c 74 74 20 70 6c 65 | \item |{\tt ple|
|00000470| 6e 64 7d 2c 20 74 6f 20 | 63 6c 6f 73 65 20 74 68 |nd}, to |close th|
|00000480| 65 20 70 6c 6f 74 2e 0a | 5c 65 6e 64 7b 65 6e 75 |e plot..|\end{enu|
|00000490| 6d 65 72 61 74 65 7d 0a | 4d 6f 72 65 20 74 68 61 |merate}.|More tha|
|000004a0| 6e 20 6f 6e 65 20 67 72 | 61 70 68 20 63 61 6e 20 |n one gr|aph can |
|000004b0| 62 65 20 64 72 61 77 6e | 20 6f 6e 20 61 20 73 69 |be drawn| on a si|
|000004c0| 6e 67 6c 65 20 73 65 74 | 20 6f 66 20 61 78 65 73 |ngle set| of axes|
|000004d0| 20 62 79 20 6d 61 6b 69 | 6e 67 0a 72 65 70 65 61 | by maki|ng.repea|
|000004e0| 74 65 64 20 63 61 6c 6c | 73 20 74 6f 20 74 68 65 |ted call|s to the|
|000004f0| 20 72 6f 75 74 69 6e 65 | 73 20 6c 69 73 74 65 64 | routine|s listed|
|00000500| 20 69 6e 20 69 74 65 6d | 20 5c 72 65 66 7b 64 72 | in item| \ref{dr|
|00000510| 61 77 7d 20 61 62 6f 76 | 65 2e 20 54 68 65 20 72 |aw} abov|e. The r|
|00000520| 6f 75 74 69 6e 65 0a 7b | 5c 74 74 20 70 6c 73 74 |outine.{|\tt plst|
|00000530| 61 72 7d 20 6e 65 65 64 | 73 20 74 6f 20 62 65 20 |ar} need|s to be |
|00000540| 63 61 6c 6c 65 64 20 6f | 6e 6c 79 20 6f 6e 63 65 |called o|nly once|
|00000550| 2c 20 75 6e 6c 65 73 73 | 20 61 20 64 69 66 66 65 |, unless| a diffe|
|00000560| 72 65 6e 74 20 6f 75 74 | 70 75 74 20 64 65 76 69 |rent out|put devi|
|00000570| 63 65 0a 69 73 20 72 65 | 71 75 69 72 65 64 2e 0a |ce.is re|quired..|
|00000580| 0a 5c 73 65 63 74 69 6f | 6e 20 7b 53 74 61 72 74 |.\sectio|n {Start|
|00000590| 69 6e 67 20 50 4c 50 4c | 4f 54 7d 20 5c 6c 61 62 |ing PLPL|OT} \lab|
|000005a0| 65 6c 7b 73 74 61 72 74 | 69 6e 67 75 70 7d 0a 53 |el{start|ingup}.S|
|000005b0| 75 62 72 6f 75 74 69 6e | 65 20 7b 5c 74 74 20 70 |ubroutin|e {\tt p|
|000005c0| 6c 73 74 61 72 7d 20 73 | 65 6c 65 63 74 73 20 61 |lstar} s|elects a|
|000005d0| 20 67 72 61 70 68 69 63 | 73 20 64 65 76 69 63 65 | graphic|s device|
|000005e0| 20 6f 72 20 6f 70 65 6e | 73 20 61 20 64 69 73 6b | or open|s a disk|
|000005f0| 20 66 69 6c 65 20 74 6f | 0a 72 65 63 65 69 76 65 | file to|.receive|
|00000600| 20 61 20 70 6c 6f 74 20 | 66 6f 72 20 6c 61 74 65 | a plot |for late|
|00000610| 72 20 64 69 73 70 6c 61 | 79 2e 20 49 66 20 7b 5c |r displa|y. If {\|
|00000620| 74 74 20 70 6c 73 74 61 | 72 7d 20 69 73 20 63 61 |tt plsta|r} is ca|
|00000630| 6c 6c 65 64 20 61 67 61 | 69 6e 20 64 75 72 69 6e |lled aga|in durin|
|00000640| 67 0a 61 20 70 72 6f 67 | 72 61 6d 2c 20 74 68 65 |g.a prog|ram, the|
|00000650| 20 70 72 65 76 69 6f 75 | 73 6c 79 20 6f 70 65 6e | previou|sly open|
|00000660| 65 64 20 66 69 6c 65 20 | 77 69 6c 6c 20 62 65 20 |ed file |will be |
|00000670| 63 6c 6f 73 65 64 2e 20 | 57 68 65 6e 20 63 61 6c |closed. |When cal|
|00000680| 6c 65 64 2c 0a 74 68 65 | 20 75 73 65 72 20 69 73 |led,.the| user is|
|00000690| 20 70 72 6f 6d 70 74 65 | 64 20 66 6f 72 20 61 20 | prompte|d for a |
|000006a0| 6e 75 6d 62 65 72 20 72 | 65 70 72 65 73 65 6e 74 |number r|epresent|
|000006b0| 69 6e 67 20 74 68 65 20 | 64 65 76 69 63 65 20 6f |ing the |device o|
|000006c0| 6e 20 77 68 69 63 68 20 | 0a 74 68 65 20 70 6c 6f |n which |.the plo|
|000006d0| 74 20 69 73 20 74 6f 20 | 61 70 70 65 61 72 2e 20 |t is to |appear. |
|000006e0| 54 68 65 20 73 79 6e 74 | 61 78 20 66 6f 72 20 7b |The synt|ax for {|
|000006f0| 5c 74 74 20 70 6c 73 74 | 61 72 7d 20 69 73 3a 0a |\tt plst|ar} is:.|
|00000700| 0a 5c 6e 61 6d 65 7b 70 | 6c 73 74 61 72 28 6e 78 |.\name{p|lstar(nx|
|00000710| 2c 6e 79 29 3b 7d 0a 5c | 61 72 67 75 7b 7b 5c 74 |,ny);}.\|argu{{\t|
|00000720| 74 20 6e 78 2c 20 6e 79 | 7d 20 28 69 6e 74 2c 20 |t nx, ny|} (int, |
|00000730| 69 6e 70 75 74 29 7d 0a | 7b 54 68 65 20 6e 75 6d |input)}.|{The num|
|00000740| 62 65 72 20 6f 66 20 70 | 6c 6f 74 73 20 74 6f 20 |ber of p|lots to |
|00000750| 61 20 70 61 67 65 2e 20 | 54 68 65 20 70 61 67 65 |a page. |The page|
|00000760| 20 69 73 20 64 69 76 69 | 64 65 64 20 69 6e 74 6f | is divi|ded into|
|00000770| 20 0a 7b 5c 74 74 20 6e | 78 7d 7e 24 5c 74 69 6d | .{\tt n|x}~$\tim|
|00000780| 65 73 24 7e 7b 5c 74 74 | 20 6e 79 7d 20 73 75 62 |es$~{\tt| ny} sub|
|00000790| 70 61 67 65 73 2c 20 77 | 69 74 68 20 7b 5c 74 74 |pages, w|ith {\tt|
|000007a0| 20 6e 78 7d 20 69 6e 20 | 74 68 65 20 68 6f 72 69 | nx} in |the hori|
|000007b0| 7a 6f 6e 74 61 6c 20 0a | 64 69 72 65 63 74 69 6f |zontal .|directio|
|000007c0| 6e 2c 20 61 6e 64 20 7b | 5c 74 74 20 6e 79 7d 20 |n, and {|\tt ny} |
|000007d0| 69 6e 20 74 68 65 20 76 | 65 72 74 69 63 61 6c 20 |in the v|ertical |
|000007e0| 64 69 72 65 63 74 69 6f | 6e 2e 7d 0a 0a 53 75 62 |directio|n.}..Sub|
|000007f0| 70 61 67 65 73 20 61 72 | 65 20 75 73 65 66 75 6c |pages ar|e useful|
|00000800| 20 66 6f 72 20 70 6c 61 | 63 69 6e 67 20 73 65 76 | for pla|cing sev|
|00000810| 65 72 61 6c 20 67 72 61 | 70 68 73 20 6f 6e 20 61 |eral gra|phs on a|
|00000820| 20 70 61 67 65 2c 20 62 | 75 74 20 61 6c 6c 0a 73 | page, b|ut all.s|
|00000830| 75 62 70 61 67 65 73 20 | 61 72 65 20 63 6f 6e 73 |ubpages |are cons|
|00000840| 74 72 61 69 6e 65 64 20 | 74 6f 20 62 65 20 6f 66 |trained |to be of|
|00000850| 20 74 68 65 20 73 61 6d | 65 20 73 69 7a 65 2e 20 | the sam|e size. |
|00000860| 46 6f 72 20 67 72 65 61 | 74 65 72 20 66 6c 65 78 |For grea|ter flex|
|00000870| 69 62 69 6c 69 74 79 20 | 0a 69 6e 20 70 6c 61 63 |ibility |.in plac|
|00000880| 69 6e 67 20 67 72 61 70 | 68 73 20 6f 6e 20 61 20 |ing grap|hs on a |
|00000890| 70 61 67 65 2c 20 72 65 | 61 64 20 70 61 67 65 20 |page, re|ad page |
|000008a0| 5c 70 61 67 65 72 65 66 | 7b 76 69 65 77 70 6f 72 |\pageref|{viewpor|
|000008b0| 74 7d 20 69 6e 20 53 65 | 63 74 69 6f 6e 20 0a 5c |t} in Se|ction .\|
|000008c0| 72 65 66 7b 76 69 65 77 | 70 6f 72 74 7d 20 77 68 |ref{view|port} wh|
|000008d0| 69 63 68 20 64 69 73 63 | 75 73 73 65 73 20 76 69 |ich disc|usses vi|
|000008e0| 65 77 70 6f 72 74 73 2e | 0a 0a 5c 73 65 63 74 69 |ewports.|..\secti|
|000008f0| 6f 6e 7b 44 65 66 69 6e | 69 6e 67 20 50 6c 6f 74 |on{Defin|ing Plot|
|00000900| 20 53 63 61 6c 65 73 20 | 61 6e 64 20 41 78 65 73 | Scales |and Axes|
|00000910| 7d 0a 54 68 65 20 66 75 | 6e 63 74 69 6f 6e 20 7b |}.The fu|nction {|
|00000920| 5c 74 74 20 70 6c 65 6e | 76 7d 20 69 73 20 75 73 |\tt plen|v} is us|
|00000930| 65 64 20 74 6f 20 64 65 | 66 69 6e 65 20 74 68 65 |ed to de|fine the|
|00000940| 20 73 63 61 6c 65 73 20 | 61 6e 64 20 61 78 65 73 | scales |and axes|
|00000950| 20 66 6f 72 20 73 69 6d | 70 6c 65 0a 67 72 61 70 | for sim|ple.grap|
|00000960| 68 73 2e 20 7b 5c 74 74 | 20 70 6c 65 6e 76 7d 20 |hs. {\tt| plenv} |
|00000970| 73 74 61 72 74 73 20 61 | 20 6e 65 77 20 70 69 63 |starts a| new pic|
|00000980| 74 75 72 65 20 6f 6e 20 | 74 68 65 20 6e 65 78 74 |ture on |the next|
|00000990| 20 73 75 62 70 61 67 65 | 20 28 6f 72 20 61 20 6e | subpage| (or a n|
|000009a0| 65 77 20 70 61 67 65 0a | 69 66 20 6e 65 63 65 73 |ew page.|if neces|
|000009b0| 73 61 72 79 29 2c 20 61 | 6e 64 20 64 65 66 69 6e |sary), a|nd defin|
|000009c0| 65 73 20 74 68 65 20 72 | 61 6e 67 65 73 20 6f 66 |es the r|anges of|
|000009d0| 20 74 68 65 20 76 61 72 | 69 61 62 6c 65 73 20 72 | the var|iables r|
|000009e0| 65 71 75 69 72 65 64 2e | 20 54 68 65 0a 72 6f 75 |equired.| The.rou|
|000009f0| 74 69 6e 65 20 77 69 6c | 6c 20 61 6c 73 6f 20 64 |tine wil|l also d|
|00000a00| 72 61 77 20 61 20 62 6f | 78 2c 20 61 78 65 73 2c |raw a bo|x, axes,|
|00000a10| 20 61 6e 64 20 6e 75 6d | 65 72 69 63 20 6c 61 62 | and num|eric lab|
|00000a20| 65 6c 73 20 69 66 20 72 | 65 71 75 65 73 74 65 64 |els if r|equested|
|00000a30| 2e 0a 54 68 65 20 73 79 | 6e 74 61 78 20 66 6f 72 |..The sy|ntax for|
|00000a40| 20 7b 5c 74 74 20 70 6c | 65 6e 76 7d 20 69 73 3a | {\tt pl|env} is:|
|00000a50| 0a 0a 5c 6e 61 6d 65 7b | 70 6c 65 6e 76 28 78 6d |..\name{|plenv(xm|
|00000a60| 69 6e 2c 78 6d 61 78 2c | 79 6d 69 6e 2c 79 6d 61 |in,xmax,|ymin,yma|
|00000a70| 78 2c 6a 75 73 74 2c 61 | 78 69 73 29 3b 7d 0a 5c |x,just,a|xis);}.\|
|00000a80| 61 72 67 75 7b 7b 5c 74 | 74 20 78 6d 69 6e 2c 20 |argu{{\t|t xmin, |
|00000a90| 78 6d 61 78 7d 20 28 66 | 6c 6f 61 74 2c 20 69 6e |xmax} (f|loat, in|
|00000aa0| 70 75 74 29 7d 0a 7b 54 | 68 65 20 6c 65 66 74 20 |put)}.{T|he left |
|00000ab0| 61 6e 64 20 72 69 67 68 | 74 20 6c 69 6d 69 74 73 |and righ|t limits|
|00000ac0| 20 66 6f 72 20 74 68 65 | 20 68 6f 72 69 7a 6f 6e | for the| horizon|
|00000ad0| 74 61 6c 20 61 78 69 73 | 2e 7d 0a 5c 61 72 67 75 |tal axis|.}.\argu|
|00000ae0| 7b 7b 5c 74 74 20 79 6d | 69 6e 2c 20 79 6d 61 78 |{{\tt ym|in, ymax|
|00000af0| 7d 20 28 66 6c 6f 61 74 | 2c 20 69 6e 70 75 74 29 |} (float|, input)|
|00000b00| 7d 0a 7b 54 68 65 20 62 | 6f 74 74 6f 6d 20 61 6e |}.{The b|ottom an|
|00000b10| 64 20 74 6f 70 20 6c 69 | 6d 69 74 73 20 66 6f 72 |d top li|mits for|
|00000b20| 20 74 68 65 20 76 65 72 | 74 69 63 61 6c 20 61 78 | the ver|tical ax|
|00000b30| 69 73 2e 7d 0a 5c 61 72 | 67 75 7b 7b 5c 74 74 20 |is.}.\ar|gu{{\tt |
|00000b40| 6a 75 73 74 7d 20 28 69 | 6e 74 2c 20 69 6e 70 75 |just} (i|nt, inpu|
|00000b50| 74 29 7d 0a 7b 54 68 69 | 73 20 73 68 6f 75 6c 64 |t)}.{Thi|s should|
|00000b60| 20 62 65 20 7a 65 72 6f | 20 6f 72 20 6f 6e 65 2e | be zero| or one.|
|00000b70| 20 49 66 20 7b 5c 74 74 | 20 6a 75 73 74 7d 20 69 | If {\tt| just} i|
|00000b80| 73 20 6f 6e 65 2c 20 74 | 68 65 20 73 63 61 6c 65 |s one, t|he scale|
|00000b90| 73 20 6f 66 20 74 68 65 | 20 0a 78 2d 61 78 69 73 |s of the| .x-axis|
|00000ba0| 20 61 6e 64 20 0a 79 2d | 61 78 69 73 20 77 69 6c | and .y-|axis wil|
|00000bb0| 6c 20 62 65 20 74 68 65 | 20 73 61 6d 65 20 28 69 |l be the| same (i|
|00000bc0| 6e 20 75 6e 69 74 73 20 | 70 65 72 20 6d 69 6c 6c |n units |per mill|
|00000bd0| 69 6d 65 74 65 72 29 3b | 20 6f 74 68 65 72 77 69 |imeter);| otherwi|
|00000be0| 73 65 20 74 68 65 20 61 | 78 65 73 20 61 72 65 20 |se the a|xes are |
|00000bf0| 0a 73 63 61 6c 65 64 20 | 69 6e 64 65 70 65 6e 64 |.scaled |independ|
|00000c00| 65 6e 74 6c 79 2e 20 54 | 68 69 73 20 70 61 72 61 |ently. T|his para|
|00000c10| 6d 65 74 65 72 20 69 73 | 20 75 73 65 66 75 6c 20 |meter is| useful |
|00000c20| 66 6f 72 20 65 6e 73 75 | 72 69 6e 67 20 74 68 61 |for ensu|ring tha|
|00000c30| 74 20 6f 62 6a 65 63 74 | 73 0a 73 75 63 68 20 61 |t object|s.such a|
|00000c40| 73 20 63 69 72 63 6c 65 | 73 20 68 61 76 65 20 74 |s circle|s have t|
|00000c50| 68 65 20 63 6f 72 72 65 | 63 74 20 61 73 70 65 63 |he corre|ct aspec|
|00000c60| 74 20 72 61 74 69 6f 20 | 69 6e 20 74 68 65 20 66 |t ratio |in the f|
|00000c70| 69 6e 61 6c 20 70 6c 6f | 74 2e 7d 0a 5c 61 72 67 |inal plo|t.}.\arg|
|00000c80| 75 7b 7b 5c 74 74 20 61 | 78 69 73 7d 20 28 69 6e |u{{\tt a|xis} (in|
|00000c90| 74 2c 20 69 6e 70 75 74 | 29 7d 0a 7b 7b 5c 74 74 |t, input|)}.{{\tt|
|00000ca0| 20 61 78 69 73 7d 20 63 | 6f 6e 74 72 6f 6c 73 20 | axis} c|ontrols |
|00000cb0| 77 68 65 74 68 65 72 20 | 61 20 62 6f 78 2c 20 74 |whether |a box, t|
|00000cc0| 69 63 6b 20 6d 61 72 6b | 73 2c 20 6c 61 62 65 6c |ick mark|s, label|
|00000cd0| 73 2c 20 61 78 65 73 2c | 20 61 6e 64 2f 6f 72 20 |s, axes,| and/or |
|00000ce0| 61 20 0a 67 72 69 64 20 | 61 72 65 20 64 72 61 77 |a .grid |are draw|
|00000cf0| 6e 2e 0a 5c 62 65 67 69 | 6e 7b 69 74 65 6d 69 7a |n..\begi|n{itemiz|
|00000d00| 65 7d 0a 20 20 20 20 20 | 5c 69 74 65 6d 20 7b 5c |e}. |\item {\|
|00000d10| 74 74 20 61 78 69 73 3d | 2d 32 7d 3a 20 4e 6f 20 |tt axis=|-2}: No |
|00000d20| 62 6f 78 20 6f 72 20 61 | 6e 6e 6f 74 61 74 69 6f |box or a|nnotatio|
|00000d30| 6e 2e 0a 20 20 20 20 20 | 5c 69 74 65 6d 20 7b 5c |n.. |\item {\|
|00000d40| 74 74 20 61 78 69 73 3d | 2d 31 7d 3a 20 44 72 61 |tt axis=|-1}: Dra|
|00000d50| 77 20 62 6f 78 20 6f 6e | 6c 79 2e 0a 20 20 20 20 |w box on|ly.. |
|00000d60| 20 5c 69 74 65 6d 20 7b | 5c 74 74 20 61 78 69 73 | \item {|\tt axis|
|00000d70| 3d 20 30 7d 3a 20 44 72 | 61 77 20 62 6f 78 2c 20 |= 0}: Dr|aw box, |
|00000d80| 6c 61 62 65 6c 6c 65 64 | 20 77 69 74 68 20 63 6f |labelled| with co|
|00000d90| 6f 72 64 69 6e 61 74 65 | 20 76 61 6c 75 65 73 20 |ordinate| values |
|00000da0| 61 72 6f 75 6e 64 20 65 | 64 67 65 2e 0a 20 20 20 |around e|dge.. |
|00000db0| 20 20 5c 69 74 65 6d 20 | 7b 5c 74 74 20 61 78 69 | \item |{\tt axi|
|00000dc0| 73 3d 20 31 7d 3a 20 49 | 6e 20 61 64 64 69 74 69 |s= 1}: I|n additi|
|00000dd0| 6f 6e 20 74 6f 20 62 6f | 78 20 61 6e 64 20 6c 61 |on to bo|x and la|
|00000de0| 62 65 6c 73 2c 20 64 72 | 61 77 20 74 68 65 20 74 |bels, dr|aw the t|
|00000df0| 77 6f 20 61 78 65 73 20 | 0a 20 20 20 20 20 20 20 |wo axes |. |
|00000e00| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00000e10| 20 20 20 58 3d 30 20 61 | 6e 64 20 59 3d 30 2e 0a | X=0 a|nd Y=0..|
|00000e20| 20 20 20 20 20 5c 69 74 | 65 6d 20 7b 5c 74 74 20 | \it|em {\tt |
|00000e30| 61 78 69 73 3d 20 32 7d | 3a 20 41 73 20 66 6f 72 |axis= 2}|: As for|
|00000e40| 20 7b 5c 74 74 20 61 78 | 69 73 3d 31 7d 2c 20 62 | {\tt ax|is=1}, b|
|00000e50| 75 74 20 61 6c 73 6f 20 | 64 72 61 77 20 61 20 67 |ut also |draw a g|
|00000e60| 72 69 64 20 61 74 20 74 | 68 65 20 6d 61 6a 6f 72 |rid at t|he major|
|00000e70| 20 74 69 63 6b 20 69 6e | 74 65 72 76 61 6c 2e 0a | tick in|terval..|
|00000e80| 20 20 20 20 20 5c 69 74 | 65 6d 20 7b 5c 74 74 20 | \it|em {\tt |
|00000e90| 61 78 69 73 3d 31 30 7d | 3a 20 4c 6f 67 61 72 69 |axis=10}|: Logari|
|00000ea0| 74 68 6d 69 63 20 58 20 | 61 78 69 73 2c 20 6c 69 |thmic X |axis, li|
|00000eb0| 6e 65 61 72 20 59 20 61 | 78 69 73 2e 0a 20 20 20 |near Y a|xis.. |
|00000ec0| 20 20 5c 69 74 65 6d 20 | 7b 5c 74 74 20 61 78 69 | \item |{\tt axi|
|00000ed0| 73 3d 31 31 7d 3a 20 4c | 6f 67 61 72 69 74 68 6d |s=11}: L|ogarithm|
|00000ee0| 69 63 20 58 20 61 78 69 | 73 2c 20 6c 69 6e 65 61 |ic X axi|s, linea|
|00000ef0| 72 20 59 20 61 78 69 73 | 20 61 6e 64 20 64 72 61 |r Y axis| and dra|
|00000f00| 77 20 6c 69 6e 65 20 59 | 3d 30 2e 0a 20 20 20 20 |w line Y|=0.. |
|00000f10| 20 5c 69 74 65 6d 20 7b | 5c 74 74 20 61 78 69 73 | \item {|\tt axis|
|00000f20| 3d 32 30 7d 3a 20 4c 69 | 6e 65 61 72 20 58 20 61 |=20}: Li|near X a|
|00000f30| 78 69 73 2c 20 6c 6f 67 | 61 72 69 74 68 6d 69 63 |xis, log|arithmic|
|00000f40| 20 59 20 61 78 69 73 2e | 0a 20 20 20 20 20 5c 69 | Y axis.|. \i|
|00000f50| 74 65 6d 20 7b 5c 74 74 | 20 61 78 69 73 3d 32 31 |tem {\tt| axis=21|
|00000f60| 7d 3a 20 4c 69 6e 65 61 | 72 20 58 20 61 78 69 73 |}: Linea|r X axis|
|00000f70| 2c 20 6c 6f 67 61 72 69 | 74 68 6d 69 63 20 59 20 |, logari|thmic Y |
|00000f80| 61 78 69 73 20 61 6e 64 | 20 64 72 61 77 20 6c 69 |axis and| draw li|
|00000f90| 6e 65 20 58 3d 30 2e 0a | 20 20 20 20 20 5c 69 74 |ne X=0..| \it|
|00000fa0| 65 6d 20 7b 5c 74 74 20 | 61 78 69 73 3d 33 30 7d |em {\tt |axis=30}|
|00000fb0| 3a 20 4c 6f 67 61 72 69 | 74 68 6d 69 63 20 58 20 |: Logari|thmic X |
|00000fc0| 61 6e 64 20 59 20 61 78 | 65 73 2e 0a 5c 65 6e 64 |and Y ax|es..\end|
|00000fd0| 7b 69 74 65 6d 69 7a 65 | 7d 20 0a 7d 0a 0a 4e 6f |{itemize|} .}..No|
|00000fe0| 74 65 3a 20 4c 6f 67 61 | 72 69 74 68 6d 69 63 20 |te: Loga|rithmic |
|00000ff0| 61 78 65 73 20 6f 6e 6c | 79 20 61 66 66 65 63 74 |axes onl|y affect|
|00001000| 20 74 68 65 20 61 70 70 | 65 61 72 61 6e 63 65 20 | the app|earance |
|00001010| 6f 66 20 74 68 65 20 61 | 78 65 73 20 61 6e 64 20 |of the a|xes and |
|00001020| 74 68 65 69 72 20 0a 6c | 61 62 65 6c 73 2c 20 73 |their .l|abels, s|
|00001030| 6f 20 69 74 20 69 73 20 | 75 70 20 74 6f 20 74 68 |o it is |up to th|
|00001040| 65 20 75 73 65 72 20 74 | 6f 20 63 6f 6d 70 75 74 |e user t|o comput|
|00001050| 65 20 74 68 65 20 6c 6f | 67 61 72 69 74 68 6d 73 |e the lo|garithms|
|00001060| 20 70 72 69 6f 72 20 74 | 6f 20 70 61 73 73 69 6e | prior t|o passin|
|00001070| 67 20 0a 74 68 65 6d 20 | 74 6f 20 7b 5c 74 74 20 |g .them |to {\tt |
|00001080| 70 6c 65 6e 76 7d 20 61 | 6e 64 20 61 6e 79 20 6f |plenv} a|nd any o|
|00001090| 66 20 74 68 65 20 6f 74 | 68 65 72 20 72 6f 75 74 |f the ot|her rout|
|000010a0| 69 6e 65 73 2e 20 54 68 | 75 73 2c 20 69 66 20 61 |ines. Th|us, if a|
|000010b0| 20 67 72 61 70 68 20 68 | 61 73 20 61 20 33 2d 63 | graph h|as a 3-c|
|000010c0| 79 63 6c 65 0a 6c 6f 67 | 61 72 69 74 68 6d 69 63 |ycle.log|arithmic|
|000010d0| 20 61 78 69 73 20 66 72 | 6f 6d 20 31 20 74 6f 20 | axis fr|om 1 to |
|000010e0| 31 30 30 30 2c 20 77 65 | 20 6e 65 65 64 20 74 6f |1000, we| need to|
|000010f0| 20 73 65 74 20 7b 5c 74 | 74 20 78 6d 69 6e 7d 24 | set {\t|t xmin}$|
|00001100| 3d 5c 6c 6f 67 5f 7b 31 | 30 7d 31 3d 30 2e 30 24 |=\log_{1|0}1=0.0$|
|00001110| 2c 20 0a 61 6e 64 20 7b | 5c 74 74 20 78 6d 61 78 |, .and {|\tt xmax|
|00001120| 7d 24 3d 5c 6c 6f 67 5f | 7b 31 30 7d 31 30 30 30 |}$=\log_|{10}1000|
|00001130| 3d 33 2e 30 24 2e 0a 0a | 46 6f 72 20 67 72 65 61 |=3.0$...|For grea|
|00001140| 74 65 72 20 63 6f 6e 74 | 72 6f 6c 20 6f 76 65 72 |ter cont|rol over|
|00001150| 20 74 68 65 20 73 69 7a | 65 20 6f 66 20 74 68 65 | the siz|e of the|
|00001160| 20 70 6c 6f 74 73 2c 20 | 61 78 69 73 20 6c 61 62 | plots, |axis lab|
|00001170| 65 6c 6c 69 6e 67 20 61 | 6e 64 20 74 69 63 6b 0a |elling a|nd tick.|
|00001180| 69 6e 74 65 72 76 61 6c | 73 2c 20 6d 6f 72 65 20 |interval|s, more |
|00001190| 63 6f 6d 70 6c 65 78 20 | 67 72 61 70 68 73 20 73 |complex |graphs s|
|000011a0| 68 6f 75 6c 64 20 6d 61 | 6b 65 20 75 73 65 20 6f |hould ma|ke use o|
|000011b0| 66 20 74 68 65 20 66 75 | 6e 63 74 69 6f 6e 73 0a |f the fu|nctions.|
|000011c0| 5c 72 6f 75 7b 70 6c 76 | 70 6f 72 7d 2c 20 5c 72 |\rou{plv|por}, \r|
|000011d0| 6f 75 7b 70 6c 77 69 6e | 64 7d 2c 20 61 6e 64 20 |ou{plwin|d}, and |
|000011e0| 5c 72 6f 75 7b 70 6c 62 | 6f 78 7d 0a 64 65 73 63 |\rou{plb|ox}.desc|
|000011f0| 72 69 62 65 64 20 69 6e | 20 43 68 61 70 74 65 72 |ribed in| Chapter|
|00001200| 20 5c 72 65 66 7b 72 65 | 66 65 72 65 6e 63 65 7d | \ref{re|ference}|
|00001210| 2e 0a 0a 5c 73 65 63 74 | 69 6f 6e 20 7b 4c 61 62 |...\sect|ion {Lab|
|00001220| 65 6c 6c 69 6e 67 20 74 | 68 65 20 47 72 61 70 68 |elling t|he Graph|
|00001230| 7d 20 0a 54 68 65 20 66 | 75 6e 63 74 69 6f 6e 20 |} .The f|unction |
|00001240| 7b 5c 74 74 20 70 6c 6c | 61 62 7d 20 6d 61 79 20 |{\tt pll|ab} may |
|00001250| 62 65 20 63 61 6c 6c 65 | 64 20 61 66 74 65 72 20 |be calle|d after |
|00001260| 7b 5c 74 74 20 70 6c 65 | 6e 76 7d 20 74 6f 20 77 |{\tt ple|nv} to w|
|00001270| 72 69 74 65 20 6c 61 62 | 65 6c 73 0a 6f 6e 20 74 |rite lab|els.on t|
|00001280| 68 65 20 78 20 61 6e 64 | 20 79 20 61 78 65 73 2c |he x and| y axes,|
|00001290| 20 61 6e 64 20 61 74 20 | 74 68 65 20 74 6f 70 20 | and at |the top |
|000012a0| 6f 66 20 74 68 65 20 70 | 69 63 74 75 72 65 2e 20 |of the p|icture. |
|000012b0| 41 6c 6c 20 74 68 65 0a | 76 61 72 69 61 62 6c 65 |All the.|variable|
|000012c0| 73 20 61 72 65 20 63 68 | 61 72 61 63 74 65 72 20 |s are ch|aracter |
|000012d0| 76 61 72 69 61 62 6c 65 | 73 20 6f 72 20 63 6f 6e |variable|s or con|
|000012e0| 73 74 61 6e 74 73 2e 20 | 54 72 61 69 6c 69 6e 67 |stants. |Trailing|
|000012f0| 20 73 70 61 63 65 73 0a | 61 72 65 20 72 65 6d 6f | spaces.|are remo|
|00001300| 76 65 64 20 61 6e 64 20 | 74 68 65 20 6c 61 62 65 |ved and |the labe|
|00001310| 6c 20 69 73 20 63 65 6e | 74 72 65 64 20 69 6e 20 |l is cen|tred in |
|00001320| 74 68 65 20 61 70 70 72 | 6f 70 72 69 61 74 65 20 |the appr|opriate |
|00001330| 66 69 65 6c 64 2e 0a 54 | 68 65 20 73 79 6e 74 61 |field..T|he synta|
|00001340| 78 20 66 6f 72 20 7b 5c | 74 74 20 70 6c 6c 61 62 |x for {\|tt pllab|
|00001350| 7d 20 69 73 3a 0a 0a 5c | 6e 61 6d 65 7b 70 6c 6c |} is:..\|name{pll|
|00001360| 61 62 28 78 6c 62 6c 2c | 79 6c 62 6c 2c 74 6f 70 |ab(xlbl,|ylbl,top|
|00001370| 6c 62 6c 29 3b 7d 0a 5c | 61 72 67 75 7b 7b 5c 74 |lbl);}.\|argu{{\t|
|00001380| 74 20 78 6c 62 6c 7d 20 | 28 63 68 61 72 20 2a 2c |t xlbl} |(char *,|
|00001390| 20 69 6e 70 75 74 29 7d | 0a 7b 50 6f 69 6e 74 65 | input)}|.{Pointe|
|000013a0| 72 20 74 6f 20 73 74 72 | 69 6e 67 20 77 69 74 68 |r to str|ing with|
|000013b0| 20 6c 61 62 65 6c 20 66 | 6f 72 20 74 68 65 20 58 | label f|or the X|
|000013c0| 2d 61 78 69 73 20 28 62 | 6f 74 74 6f 6d 20 6f 66 |-axis (b|ottom of|
|000013d0| 20 67 72 61 70 68 29 2e | 7d 0a 5c 61 72 67 75 7b | graph).|}.\argu{|
|000013e0| 7b 5c 74 74 20 79 6c 62 | 6c 7d 20 28 63 68 61 72 |{\tt ylb|l} (char|
|000013f0| 20 2a 2c 20 69 6e 70 75 | 74 29 7d 0a 7b 50 6f 69 | *, inpu|t)}.{Poi|
|00001400| 6e 74 65 72 20 74 6f 20 | 73 74 72 69 6e 67 20 77 |nter to |string w|
|00001410| 69 74 68 20 6c 61 62 65 | 6c 20 66 6f 72 20 74 68 |ith labe|l for th|
|00001420| 65 20 59 2d 61 78 69 73 | 20 28 6c 65 66 74 20 6f |e Y-axis| (left o|
|00001430| 66 20 67 72 61 70 68 29 | 2e 7d 0a 5c 61 72 67 75 |f graph)|.}.\argu|
|00001440| 7b 7b 5c 74 74 20 74 6f | 70 6c 62 6c 7d 20 28 63 |{{\tt to|plbl} (c|
|00001450| 68 61 72 20 2a 2c 20 69 | 6e 70 75 74 29 7d 0a 7b |har *, i|nput)}.{|
|00001460| 50 6f 69 6e 74 65 72 20 | 74 6f 20 73 74 72 69 6e |Pointer |to strin|
|00001470| 67 20 77 69 74 68 20 6c | 61 62 65 6c 20 66 6f 72 |g with l|abel for|
|00001480| 20 74 68 65 20 70 6c 6f | 74 20 28 74 6f 70 20 6f | the plo|t (top o|
|00001490| 66 20 70 69 63 74 75 72 | 65 29 2e 7d 0a 0a 4d 6f |f pictur|e).}..Mo|
|000014a0| 72 65 20 63 6f 6d 70 6c | 65 78 20 6c 61 62 65 6c |re compl|ex label|
|000014b0| 73 20 63 61 6e 20 62 65 | 20 64 72 61 77 6e 20 75 |s can be| drawn u|
|000014c0| 73 69 6e 67 20 74 68 65 | 20 66 75 6e 63 74 69 6f |sing the| functio|
|000014d0| 6e 20 5c 72 6f 75 7b 70 | 6c 6d 74 65 78 7d 2e 0a |n \rou{p|lmtex}..|
|000014e0| 53 65 65 20 61 6c 73 6f | 20 53 65 63 74 69 6f 6e |See also| Section|
|000014f0| 20 5c 72 65 66 7b 67 72 | 61 70 68 2d 74 65 78 74 | \ref{gr|aph-text|
|00001500| 7d 20 6f 6e 20 70 61 67 | 65 0a 5c 70 61 67 65 72 |} on pag|e.\pager|
|00001510| 65 66 7b 67 72 61 70 68 | 2d 74 65 78 74 7d 20 66 |ef{graph|-text} f|
|00001520| 6f 72 20 69 6e 66 6f 72 | 6d 61 74 69 6f 6e 20 61 |or infor|mation a|
|00001530| 62 6f 75 74 20 74 68 65 | 20 66 75 6e 63 74 69 6f |bout the| functio|
|00001540| 6e 20 7b 5c 74 74 20 70 | 6c 70 74 65 78 7d 20 77 |n {\tt p|lptex} w|
|00001550| 68 69 63 68 0a 77 72 69 | 74 65 73 20 6c 61 62 65 |hich.wri|tes labe|
|00001560| 6c 73 20 77 69 74 68 69 | 6e 20 61 20 67 72 61 70 |ls withi|n a grap|
|00001570| 68 2e 0a 0a 5c 73 65 63 | 74 69 6f 6e 20 7b 44 72 |h...\sec|tion {Dr|
|00001580| 61 77 69 6e 67 20 74 68 | 65 20 47 72 61 70 68 7d |awing th|e Graph}|
|00001590| 0a 0a 50 4c 50 4c 4f 54 | 20 63 61 6e 20 64 72 61 |..PLPLOT| can dra|
|000015a0| 77 20 67 72 61 70 68 73 | 20 63 6f 6e 73 69 73 74 |w graphs| consist|
|000015b0| 69 6e 67 20 6f 66 20 70 | 6f 69 6e 74 73 20 77 69 |ing of p|oints wi|
|000015c0| 74 68 20 6f 70 74 69 6f | 6e 61 6c 20 65 72 72 6f |th optio|nal erro|
|000015d0| 72 20 62 61 72 73 2c 0a | 6c 69 6e 65 20 73 65 67 |r bars,.|line seg|
|000015e0| 6d 65 6e 74 73 20 6f 72 | 20 68 69 73 74 6f 67 72 |ments or| histogr|
|000015f0| 61 6d 73 2e 20 46 75 6e | 63 74 69 6f 6e 73 20 77 |ams. Fun|ctions w|
|00001600| 68 69 63 68 20 70 65 72 | 66 6f 72 6d 20 65 61 63 |hich per|form eac|
|00001610| 68 20 6f 66 20 74 68 65 | 73 65 0a 61 63 74 69 6f |h of the|se.actio|
|00001620| 6e 73 20 6d 61 79 20 62 | 65 20 63 61 6c 6c 65 64 |ns may b|e called|
|00001630| 20 61 66 74 65 72 20 73 | 65 74 74 69 6e 67 20 75 | after s|etting u|
|00001640| 70 20 74 68 65 20 70 6c | 6f 74 74 69 6e 67 20 65 |p the pl|otting e|
|00001650| 6e 76 69 72 6f 6e 6d 65 | 6e 74 20 0a 75 73 69 6e |nvironme|nt .usin|
|00001660| 67 20 7b 5c 74 74 20 70 | 6c 65 6e 76 7d 2e 20 41 |g {\tt p|lenv}. A|
|00001670| 6c 6c 20 6f 66 20 74 68 | 65 20 66 6f 6c 6c 6f 77 |ll of th|e follow|
|00001680| 69 6e 67 20 66 75 6e 63 | 74 69 6f 6e 73 20 64 72 |ing func|tions dr|
|00001690| 61 77 20 77 69 74 68 69 | 6e 20 74 68 65 20 62 6f |aw withi|n the bo|
|000016a0| 78 20 0a 64 65 66 69 6e | 65 64 20 62 79 20 7b 5c |x .defin|ed by {\|
|000016b0| 74 74 20 70 6c 65 6e 76 | 7d 2c 20 61 6e 64 20 61 |tt plenv|}, and a|
|000016c0| 6e 79 20 6c 69 6e 65 73 | 20 63 72 6f 73 73 69 6e |ny lines| crossin|
|000016d0| 67 20 74 68 65 20 62 6f | 75 6e 64 61 72 79 20 61 |g the bo|undary a|
|000016e0| 72 65 20 63 6c 69 70 70 | 65 64 2e 0a 46 75 6e 63 |re clipp|ed..Func|
|000016f0| 74 69 6f 6e 73 20 61 72 | 65 20 61 6c 73 6f 20 70 |tions ar|e also p|
|00001700| 72 6f 76 69 64 65 64 20 | 66 6f 72 20 64 72 61 77 |rovided |for draw|
|00001710| 69 6e 67 20 73 75 72 66 | 61 63 65 20 61 6e 64 20 |ing surf|ace and |
|00001720| 63 6f 6e 74 6f 75 72 20 | 72 65 70 72 65 73 65 6e |contour |represen|
|00001730| 74 61 74 69 6f 6e 73 0a | 6f 66 20 6d 75 6c 74 69 |tations.|of multi|
|00001740| 2d 64 69 6d 65 6e 73 69 | 6f 6e 61 6c 20 66 75 6e |-dimensi|onal fun|
|00001750| 63 74 69 6f 6e 73 2e 20 | 54 68 65 73 65 20 61 72 |ctions. |These ar|
|00001760| 65 20 64 65 73 63 72 69 | 62 65 64 20 69 6e 20 0a |e descri|bed in .|
|00001770| 43 68 61 70 74 65 72 20 | 5c 72 65 66 7b 61 64 76 |Chapter |\ref{adv|
|00001780| 61 6e 63 65 64 7d 2e 0a | 0a 5c 73 75 62 73 65 63 |anced}..|.\subsec|
|00001790| 74 69 6f 6e 20 7b 44 72 | 61 77 69 6e 67 20 50 6f |tion {Dr|awing Po|
|000017a0| 69 6e 74 73 7d 0a 7b 5c | 74 74 20 70 6c 70 6f 69 |ints}.{\|tt plpoi|
|000017b0| 6e 7d 20 61 6e 64 20 7b | 5c 74 74 20 70 6c 73 79 |n} and {|\tt plsy|
|000017c0| 6d 7d 20 6d 61 72 6b 20 | 6f 75 74 20 7b 5c 74 74 |m} mark |out {\tt|
|000017d0| 20 6e 7d 20 70 6f 69 6e | 74 73 20 0a 7b 5c 74 74 | n} poin|ts .{\tt|
|000017e0| 20 28 78 5b 69 5d 2c 79 | 5b 69 5d 29 7d 20 77 69 | (x[i],y|[i])} wi|
|000017f0| 74 68 20 74 68 65 20 0a | 73 70 65 63 69 66 69 65 |th the .|specifie|
|00001800| 64 20 73 79 6d 62 6f 6c | 2e 20 54 68 65 20 72 6f |d symbol|. The ro|
|00001810| 75 74 69 6e 65 73 20 64 | 69 66 66 65 72 20 6f 6e |utines d|iffer on|
|00001820| 6c 79 20 69 6e 20 74 68 | 65 20 69 6e 74 65 72 70 |ly in th|e interp|
|00001830| 72 65 74 61 74 69 6f 6e | 20 0a 6f 66 20 74 68 65 |retation| .of the|
|00001840| 20 73 79 6d 62 6f 6c 20 | 0a 63 6f 64 65 73 2e 20 | symbol |.codes. |
|00001850| 7b 5c 74 74 20 70 6c 70 | 6f 69 6e 7d 20 75 73 65 |{\tt plp|oin} use|
|00001860| 73 20 61 6e 20 65 78 74 | 65 6e 64 65 64 20 41 53 |s an ext|ended AS|
|00001870| 43 49 49 20 72 65 70 72 | 65 73 65 6e 74 61 74 69 |CII repr|esentati|
|00001880| 6f 6e 2c 20 77 69 74 68 | 20 74 68 65 20 0a 70 72 |on, with| the .pr|
|00001890| 69 6e 74 61 62 6c 65 20 | 0a 41 53 43 49 49 20 63 |intable |.ASCII c|
|000018a0| 6f 64 65 73 20 6d 61 70 | 70 69 6e 67 20 74 6f 20 |odes map|ping to |
|000018b0| 74 68 65 20 72 65 73 70 | 65 63 74 69 76 65 20 63 |the resp|ective c|
|000018c0| 68 61 72 61 63 74 65 72 | 73 20 69 6e 20 74 68 65 |haracter|s in the|
|000018d0| 20 63 75 72 72 65 6e 74 | 20 66 6f 6e 74 2c 20 61 | current| font, a|
|000018e0| 6e 64 20 0a 74 68 65 20 | 63 6f 64 65 73 20 66 72 |nd .the |codes fr|
|000018f0| 6f 6d 20 30 2d 33 31 20 | 6d 61 70 70 69 6e 67 20 |om 0-31 |mapping |
|00001900| 74 6f 20 76 61 72 69 6f | 75 73 20 75 73 65 66 75 |to vario|us usefu|
|00001910| 6c 20 73 79 6d 62 6f 6c | 73 2e 20 0a 49 6e 20 7b |l symbol|s. .In {|
|00001920| 5c 74 74 20 70 6c 73 79 | 6d 7d 20 68 6f 77 65 76 |\tt plsy|m} howev|
|00001930| 65 72 2c 20 0a 74 68 65 | 20 63 6f 64 65 20 69 73 |er, .the| code is|
|00001940| 20 61 20 48 65 72 73 68 | 65 79 20 66 6f 6e 74 20 | a Hersh|ey font |
|00001950| 63 6f 64 65 20 6e 75 6d | 62 65 72 2e 20 45 78 61 |code num|ber. Exa|
|00001960| 6d 70 6c 65 20 70 72 6f | 67 72 61 6d 73 20 61 72 |mple pro|grams ar|
|00001970| 65 20 70 72 6f 76 69 64 | 65 64 0a 77 68 69 63 68 |e provid|ed.which|
|00001980| 20 64 69 73 70 6c 61 79 | 20 65 61 63 68 20 6f 66 | display| each of|
|00001990| 20 74 68 65 20 73 79 6d | 62 6f 6c 73 20 61 76 61 | the sym|bols ava|
|000019a0| 69 6c 61 62 6c 65 20 75 | 73 69 6e 67 20 74 68 65 |ilable u|sing the|
|000019b0| 73 65 20 72 6f 75 74 69 | 6e 65 73 2e 0a 20 0a 5c |se routi|nes.. .\|
|000019c0| 6e 61 6d 65 7b 70 6c 70 | 6f 69 6e 28 6e 2c 78 2c |name{plp|oin(n,x,|
|000019d0| 79 2c 63 6f 64 65 29 3b | 20 7b 5c 72 6d 20 61 6e |y,code);| {\rm an|
|000019e0| 64 20 7d 20 70 6c 73 79 | 6d 28 6e 2c 78 2c 79 2c |d } plsy|m(n,x,y,|
|000019f0| 63 6f 64 65 29 3b 7d 0a | 5c 61 72 67 75 7b 7b 5c |code);}.|\argu{{\|
|00001a00| 74 74 20 6e 7d 20 28 69 | 6e 74 2c 20 69 6e 70 75 |tt n} (i|nt, inpu|
|00001a10| 74 29 7d 0a 7b 74 68 65 | 20 6e 75 6d 62 65 72 20 |t)}.{the| number |
|00001a20| 6f 66 20 70 6f 69 6e 74 | 73 20 74 6f 20 70 6c 6f |of point|s to plo|
|00001a30| 74 2e 7d 0a 5c 61 72 67 | 75 7b 7b 5c 74 74 20 78 |t.}.\arg|u{{\tt x|
|00001a40| 2c 20 79 7d 20 28 66 6c | 6f 61 74 20 2a 2c 20 69 |, y} (fl|oat *, i|
|00001a50| 6e 70 75 74 29 7d 0a 7b | 70 6f 69 6e 74 65 72 73 |nput)}.{|pointers|
|00001a60| 20 74 6f 20 61 72 72 61 | 79 73 20 6f 66 20 74 68 | to arra|ys of th|
|00001a70| 65 20 63 6f 6f 72 64 69 | 6e 61 74 65 73 20 6f 66 |e coordi|nates of|
|00001a80| 20 74 68 65 20 7b 5c 74 | 74 20 6e 7d 20 70 6f 69 | the {\t|t n} poi|
|00001a90| 6e 74 73 2e 7d 0a 5c 61 | 72 67 75 7b 7b 5c 74 74 |nts.}.\a|rgu{{\tt|
|00001aa0| 20 63 6f 64 65 7d 20 28 | 69 6e 74 2c 20 69 6e 70 | code} (|int, inp|
|00001ab0| 75 74 29 7d 0a 7b 63 6f | 64 65 20 6e 75 6d 62 65 |ut)}.{co|de numbe|
|00001ac0| 72 20 6f 66 20 73 79 6d | 62 6f 6c 20 74 6f 20 64 |r of sym|bol to d|
|00001ad0| 72 61 77 2e 7d 0a 0a 5c | 73 75 62 73 65 63 74 69 |raw.}..\|subsecti|
|00001ae0| 6f 6e 20 7b 44 72 61 77 | 69 6e 67 20 4c 69 6e 65 |on {Draw|ing Line|
|00001af0| 73 20 6f 72 20 43 75 72 | 76 65 73 7d 0a 0a 50 4c |s or Cur|ves}..PL|
|00001b00| 50 4c 4f 54 20 70 72 6f | 76 69 64 65 73 20 74 77 |PLOT pro|vides tw|
|00001b10| 6f 20 66 75 6e 63 74 69 | 6f 6e 73 20 66 6f 72 20 |o functi|ons for |
|00001b20| 64 72 61 77 69 6e 67 20 | 6c 69 6e 65 20 67 72 61 |drawing |line gra|
|00001b30| 70 68 73 2e 20 0a 41 6c | 6c 20 6c 69 6e 65 73 20 |phs. .Al|l lines |
|00001b40| 61 72 65 20 64 72 61 77 | 6e 20 69 6e 0a 74 68 65 |are draw|n in.the|
|00001b50| 20 63 75 72 72 65 6e 74 | 6c 79 20 73 65 6c 65 63 | current|ly selec|
|00001b60| 74 65 64 20 63 6f 6c 6f | 72 20 61 6e 64 20 6c 69 |ted colo|r and li|
|00001b70| 6e 65 20 73 74 79 6c 65 | 2e 20 53 65 65 20 70 61 |ne style|. See pa|
|00001b80| 67 65 20 5c 70 61 67 65 | 72 65 66 7b 63 6f 6c 6f |ge \page|ref{colo|
|00001b90| 75 72 7d 20 69 6e 0a 53 | 65 63 74 69 6f 6e 20 5c |ur} in.S|ection \|
|00001ba0| 72 65 66 7b 63 6f 6c 6f | 75 72 7d 20 61 6e 64 20 |ref{colo|ur} and |
|00001bb0| 70 61 67 65 20 5c 70 61 | 67 65 72 65 66 7b 73 74 |page \pa|geref{st|
|00001bc0| 79 6c 65 7d 20 69 6e 20 | 53 65 63 74 69 6f 6e 20 |yle} in |Section |
|00001bd0| 5c 72 65 66 7b 73 74 79 | 6c 65 7d 20 66 6f 72 0a |\ref{sty|le} for.|
|00001be0| 69 6e 66 6f 72 6d 61 74 | 69 6f 6e 20 61 62 6f 75 |informat|ion abou|
|00001bf0| 74 20 63 68 61 6e 67 69 | 6e 67 20 74 68 65 73 65 |t changi|ng these|
|00001c00| 20 70 61 72 61 6d 65 74 | 65 72 73 2e 0a 0a 7b 5c | paramet|ers...{\|
|00001c10| 74 74 20 70 6c 6c 69 6e | 65 7d 20 64 72 61 77 73 |tt pllin|e} draws|
|00001c20| 20 61 20 6c 69 6e 65 20 | 6f 72 20 63 75 72 76 65 | a line |or curve|
|00001c30| 2e 20 54 68 65 20 63 75 | 72 76 65 20 63 6f 6e 73 |. The cu|rve cons|
|00001c40| 69 73 74 73 20 6f 66 20 | 7b 5c 74 74 20 6e 2d 31 |ists of |{\tt n-1|
|00001c50| 7d 20 6c 69 6e 65 20 0a | 73 65 67 6d 65 6e 74 73 |} line .|segments|
|00001c60| 20 6a 6f 69 6e 69 6e 67 | 20 74 68 65 20 7b 5c 74 | joining| the {\t|
|00001c70| 74 20 6e 7d 20 70 6f 69 | 6e 74 73 20 69 6e 20 74 |t n} poi|nts in t|
|00001c80| 68 65 20 69 6e 70 75 74 | 20 61 72 72 61 79 73 2e |he input| arrays.|
|00001c90| 20 46 6f 72 20 73 69 6e | 67 6c 65 20 6c 69 6e 65 | For sin|gle line|
|00001ca0| 0a 73 65 67 6d 65 6e 74 | 73 2c 20 7b 5c 74 74 20 |.segment|s, {\tt |
|00001cb0| 70 6c 6a 6f 69 6e 7d 20 | 69 73 20 75 73 65 64 20 |pljoin} |is used |
|00001cc0| 74 6f 20 6a 6f 69 6e 20 | 74 77 6f 20 70 6f 69 6e |to join |two poin|
|00001cd0| 74 73 2e 0a 0a 5c 6e 61 | 6d 65 7b 70 6c 6c 69 6e |ts...\na|me{pllin|
|00001ce0| 65 28 6e 2c 78 2c 79 29 | 3b 7d 0a 5c 61 72 67 75 |e(n,x,y)|;}.\argu|
|00001cf0| 7b 7b 5c 74 74 20 6e 7d | 20 28 69 6e 74 2c 20 69 |{{\tt n}| (int, i|
|00001d00| 6e 70 75 74 29 7d 0a 7b | 74 68 65 20 6e 75 6d 62 |nput)}.{|the numb|
|00001d10| 65 72 20 6f 66 20 70 6f | 69 6e 74 73 2e 7d 0a 5c |er of po|ints.}.\|
|00001d20| 61 72 67 75 7b 7b 5c 74 | 74 20 78 2c 20 79 7d 20 |argu{{\t|t x, y} |
|00001d30| 28 66 6c 6f 61 74 20 2a | 2c 20 69 6e 70 75 74 29 |(float *|, input)|
|00001d40| 7d 0a 7b 70 6f 69 6e 74 | 65 72 73 20 74 6f 20 61 |}.{point|ers to a|
|00001d50| 72 72 61 79 73 20 77 69 | 74 68 20 63 6f 6f 72 64 |rrays wi|th coord|
|00001d60| 69 6e 61 74 65 73 20 6f | 66 20 74 68 65 20 7b 5c |inates o|f the {\|
|00001d70| 74 74 20 6e 7d 20 70 6f | 69 6e 74 73 2e 7d 0a 0a |tt n} po|ints.}..|
|00001d80| 5c 6e 61 6d 65 7b 70 6c | 6a 6f 69 6e 28 78 31 2c |\name{pl|join(x1,|
|00001d90| 79 31 2c 78 32 2c 79 32 | 29 3b 7d 0a 5c 61 72 67 |y1,x2,y2|);}.\arg|
|00001da0| 75 7b 7b 5c 74 74 20 78 | 31 2c 20 79 31 7d 20 28 |u{{\tt x|1, y1} (|
|00001db0| 66 6c 6f 61 74 2c 20 69 | 6e 70 75 74 29 7d 0a 7b |float, i|nput)}.{|
|00001dc0| 63 6f 6f 72 64 69 6e 61 | 74 65 73 20 6f 66 20 74 |coordina|tes of t|
|00001dd0| 68 65 20 66 69 72 73 74 | 20 70 6f 69 6e 74 2e 7d |he first| point.}|
|00001de0| 0a 5c 61 72 67 75 7b 7b | 5c 74 74 20 78 32 2c 20 |.\argu{{|\tt x2, |
|00001df0| 79 32 7d 20 28 66 6c 6f | 61 74 2c 20 69 6e 70 75 |y2} (flo|at, inpu|
|00001e00| 74 29 7d 0a 7b 63 6f 6f | 72 64 69 6e 61 74 65 73 |t)}.{coo|rdinates|
|00001e10| 20 6f 66 20 74 68 65 20 | 73 65 63 6f 6e 64 20 70 | of the |second p|
|00001e20| 6f 69 6e 74 2e 7d 0a 0a | 5c 73 75 62 73 65 63 74 |oint.}..|\subsect|
|00001e30| 69 6f 6e 20 7b 57 72 69 | 74 69 6e 67 20 54 65 78 |ion {Wri|ting Tex|
|00001e40| 74 20 6f 6e 20 61 20 47 | 72 61 70 68 7d 20 5c 6c |t on a G|raph} \l|
|00001e50| 61 62 65 6c 20 7b 67 72 | 61 70 68 2d 74 65 78 74 |abel {gr|aph-text|
|00001e60| 7d 0a 0a 7b 5c 74 74 20 | 70 6c 70 74 65 78 7d 20 |}..{\tt |plptex} |
|00001e70| 61 6c 6c 6f 77 73 20 74 | 65 78 74 20 74 6f 20 62 |allows t|ext to b|
|00001e80| 65 20 77 72 69 74 74 65 | 6e 20 77 69 74 68 69 6e |e writte|n within|
|00001e90| 20 74 68 65 20 6c 69 6d | 69 74 73 20 73 65 74 20 | the lim|its set |
|00001ea0| 62 79 20 0a 7b 5c 74 74 | 20 70 6c 65 6e 76 7d 2e |by .{\tt| plenv}.|
|00001eb0| 20 54 68 65 20 72 65 66 | 65 72 65 6e 63 65 20 70 | The ref|erence p|
|00001ec0| 6f 69 6e 74 20 6f 66 20 | 61 20 74 65 78 74 20 73 |oint of |a text s|
|00001ed0| 74 72 69 6e 67 20 6d 61 | 79 20 62 65 20 6c 6f 63 |tring ma|y be loc|
|00001ee0| 61 74 65 64 20 0a 61 6e | 79 77 68 65 72 65 20 61 |ated .an|ywhere a|
|00001ef0| 6c 6f 6e 67 20 61 6e 20 | 69 6d 61 67 69 6e 61 72 |long an |imaginar|
|00001f00| 79 20 68 6f 72 69 7a 6f | 6e 74 61 6c 20 6c 69 6e |y horizo|ntal lin|
|00001f10| 65 20 70 61 73 73 69 6e | 67 20 74 68 72 6f 75 67 |e passin|g throug|
|00001f20| 68 20 74 68 65 20 73 74 | 72 69 6e 67 20 0a 61 74 |h the st|ring .at|
|00001f30| 20 68 61 6c 66 20 74 68 | 65 20 68 65 69 67 68 74 | half th|e height|
|00001f40| 20 6f 66 20 61 20 63 61 | 70 69 74 61 6c 20 6c 65 | of a ca|pital le|
|00001f50| 74 74 65 72 2e 20 54 68 | 65 20 70 61 72 61 6d 65 |tter. Th|e parame|
|00001f60| 74 65 72 20 22 6a 75 73 | 74 22 20 73 70 65 63 69 |ter "jus|t" speci|
|00001f70| 66 69 65 73 20 0a 77 68 | 65 72 65 20 61 6c 6f 6e |fies .wh|ere alon|
|00001f80| 67 20 74 68 69 73 20 6c | 69 6e 65 20 74 68 65 20 |g this l|ine the |
|00001f90| 72 65 66 65 72 65 6e 63 | 65 20 70 6f 69 6e 74 20 |referenc|e point |
|00001fa0| 69 73 20 6c 6f 63 61 74 | 65 64 2e 20 54 68 65 20 |is locat|ed. The |
|00001fb0| 73 74 72 69 6e 67 20 69 | 73 20 74 68 65 6e 0a 72 |string i|s then.r|
|00001fc0| 6f 74 61 74 65 64 20 61 | 62 6f 75 74 20 74 68 65 |otated a|bout the|
|00001fd0| 20 72 65 66 65 72 65 6e | 63 65 20 70 6f 69 6e 74 | referen|ce point|
|00001fe0| 20 74 68 72 6f 75 67 68 | 20 61 6e 20 61 6e 67 6c | through| an angl|
|00001ff0| 65 20 73 70 65 63 69 66 | 69 65 64 20 62 79 20 74 |e specif|ied by t|
|00002000| 68 65 0a 70 61 72 61 6d | 65 74 65 72 73 20 7b 5c |he.param|eters {\|
|00002010| 74 74 20 64 78 7d 20 61 | 6e 64 20 7b 5c 74 74 20 |tt dx} a|nd {\tt |
|00002020| 64 79 7d 2c 20 73 6f 20 | 74 68 61 74 20 74 68 65 |dy}, so |that the|
|00002030| 20 73 74 72 69 6e 67 20 | 62 65 63 6f 6d 65 73 20 | string |becomes |
|00002040| 70 61 72 61 6c 6c 65 6c | 20 0a 74 6f 20 61 20 6c |parallel| .to a l|
|00002050| 69 6e 65 20 6a 6f 69 6e | 69 6e 67 20 7b 5c 74 74 |ine join|ing {\tt|
|00002060| 20 28 78 2c 79 29 7d 20 | 74 6f 20 7b 5c 74 74 20 | (x,y)} |to {\tt |
|00002070| 28 78 2b 64 78 2c 79 2b | 64 79 29 7d 2e 0a 0a 5c |(x+dx,y+|dy)}...\|
|00002080| 6e 61 6d 65 7b 70 6c 70 | 74 65 78 28 78 2c 79 2c |name{plp|tex(x,y,|
|00002090| 64 78 2c 64 79 2c 6a 75 | 73 74 2c 74 65 78 74 29 |dx,dy,ju|st,text)|
|000020a0| 3b 7d 0a 5c 61 72 67 75 | 7b 7b 5c 74 74 20 78 2c |;}.\argu|{{\tt x,|
|000020b0| 20 79 7d 20 28 66 6c 6f | 61 74 2c 20 69 6e 70 75 | y} (flo|at, inpu|
|000020c0| 74 29 7d 0a 7b 63 6f 6f | 72 64 69 6e 61 74 65 73 |t)}.{coo|rdinates|
|000020d0| 20 6f 66 20 74 68 65 20 | 72 65 66 65 72 65 6e 63 | of the |referenc|
|000020e0| 65 20 70 6f 69 6e 74 2e | 7d 0a 5c 61 72 67 75 7b |e point.|}.\argu{|
|000020f0| 7b 5c 74 74 20 64 78 2c | 20 64 79 7d 20 28 66 6c |{\tt dx,| dy} (fl|
|00002100| 6f 61 74 2c 20 69 6e 70 | 75 74 29 7d 0a 7b 74 68 |oat, inp|ut)}.{th|
|00002110| 65 73 65 20 73 70 65 63 | 69 66 79 20 74 68 65 20 |ese spec|ify the |
|00002120| 61 6e 67 6c 65 20 61 74 | 20 77 68 69 63 68 20 74 |angle at| which t|
|00002130| 68 65 20 74 65 78 74 20 | 69 73 20 74 6f 20 62 65 |he text |is to be|
|00002140| 20 70 72 69 6e 74 65 64 | 2e 20 54 68 65 20 74 65 | printed|. The te|
|00002150| 78 74 20 69 73 20 0a 20 | 77 72 69 74 74 65 6e 20 |xt is . |written |
|00002160| 70 61 72 61 6c 6c 65 6c | 20 74 6f 20 61 20 6c 69 |parallel| to a li|
|00002170| 6e 65 20 6a 6f 69 6e 69 | 6e 67 20 74 68 65 20 70 |ne joini|ng the p|
|00002180| 6f 69 6e 74 73 20 7b 5c | 74 74 20 28 78 2c 79 29 |oints {\|tt (x,y)|
|00002190| 7d 20 74 6f 20 0a 20 7b | 5c 74 74 20 28 78 2b 64 |} to . {|\tt (x+d|
|000021a0| 78 2c 79 2b 64 79 29 7d | 20 6f 6e 20 74 68 65 20 |x,y+dy)}| on the |
|000021b0| 67 72 61 70 68 2e 7d 0a | 5c 61 72 67 75 7b 7b 5c |graph.}.|\argu{{\|
|000021c0| 74 74 20 6a 75 73 74 7d | 20 28 66 6c 6f 61 74 2c |tt just}| (float,|
|000021d0| 20 69 6e 70 75 74 29 7d | 0a 7b 64 65 74 65 72 6d | input)}|.{determ|
|000021e0| 69 6e 65 73 20 6a 75 73 | 74 69 66 69 63 61 74 69 |ines jus|tificati|
|000021f0| 6f 6e 20 6f 66 20 74 68 | 65 20 73 74 72 69 6e 67 |on of th|e string|
|00002200| 20 62 79 20 73 70 65 63 | 69 66 79 69 6e 67 20 77 | by spec|ifying w|
|00002210| 68 69 63 68 20 70 6f 69 | 6e 74 20 77 69 74 68 69 |hich poi|nt withi|
|00002220| 6e 0a 20 74 68 65 20 73 | 74 72 69 6e 67 20 69 73 |n. the s|tring is|
|00002230| 20 70 6c 61 63 65 64 20 | 61 74 20 74 68 65 20 72 | placed |at the r|
|00002240| 65 66 65 72 65 6e 63 65 | 20 70 6f 69 6e 74 20 7b |eference| point {|
|00002250| 5c 74 74 20 28 78 2c 79 | 29 7d 2e 20 54 68 69 73 |\tt (x,y|)}. This|
|00002260| 20 70 61 72 61 6d 65 74 | 65 72 0a 20 69 73 20 61 | paramet|er. is a|
|00002270| 20 66 72 61 63 74 69 6f | 6e 20 6f 66 20 74 68 65 | fractio|n of the|
|00002280| 20 64 69 73 74 61 6e 63 | 65 20 61 6c 6f 6e 67 20 | distanc|e along |
|00002290| 74 68 65 20 73 74 72 69 | 6e 67 2e 20 54 68 75 73 |the stri|ng. Thus|
|000022a0| 20 69 66 20 7b 5c 74 74 | 20 6a 75 73 74 3d 30 2e | if {\tt| just=0.|
|000022b0| 30 7d 2c 20 0a 20 74 68 | 65 20 72 65 66 65 72 65 |0}, . th|e refere|
|000022c0| 6e 63 65 20 70 6f 69 6e | 74 20 69 73 20 61 74 20 |nce poin|t is at |
|000022d0| 74 68 65 20 6c 65 66 74 | 2d 68 61 6e 64 20 65 64 |the left|-hand ed|
|000022e0| 67 65 20 6f 66 20 74 68 | 65 20 73 74 72 69 6e 67 |ge of th|e string|
|000022f0| 2e 0a 20 49 66 20 7b 5c | 74 74 20 6a 75 73 74 3d |.. If {\|tt just=|
|00002300| 30 2e 35 7d 2c 20 69 74 | 20 69 73 20 61 74 20 74 |0.5}, it| is at t|
|00002310| 68 65 20 63 65 6e 74 65 | 72 20 61 6e 64 20 69 66 |he cente|r and if|
|00002320| 20 7b 5c 74 74 20 6a 75 | 73 74 3d 31 2e 30 7d 2c | {\tt ju|st=1.0},|
|00002330| 20 69 74 20 69 73 20 61 | 74 20 0a 20 74 68 65 20 | it is a|t . the |
|00002340| 72 69 67 68 74 2d 68 61 | 6e 64 20 65 64 67 65 2e |right-ha|nd edge.|
|00002350| 7d 0a 5c 61 72 67 75 7b | 7b 5c 74 74 20 74 65 78 |}.\argu{|{\tt tex|
|00002360| 74 7d 20 28 63 68 61 72 | 20 2a 2c 20 69 6e 70 75 |t} (char| *, inpu|
|00002370| 74 29 7d 0a 7b 70 6f 69 | 6e 74 65 72 20 74 6f 20 |t)}.{poi|nter to |
|00002380| 74 68 65 20 73 74 72 69 | 6e 67 20 6f 66 20 63 68 |the stri|ng of ch|
|00002390| 61 72 61 63 74 65 72 73 | 20 74 6f 20 62 65 20 77 |aracters| to be w|
|000023a0| 72 69 74 74 65 6e 2e 7d | 0a 0a 5c 73 75 62 73 65 |ritten.}|..\subse|
|000023b0| 63 74 69 6f 6e 20 7b 4d | 6f 72 65 20 43 6f 6d 70 |ction {M|ore Comp|
|000023c0| 6c 65 78 20 47 72 61 70 | 68 73 20 28 48 69 73 74 |lex Grap|hs (Hist|
|000023d0| 6f 67 72 61 6d 73 20 61 | 6e 64 20 45 72 72 6f 72 |ograms a|nd Error|
|000023e0| 20 42 61 72 73 29 7d 0a | 0a 46 75 6e 63 74 69 6f | Bars)}.|.Functio|
|000023f0| 6e 73 20 5c 72 6f 75 7b | 70 6c 62 69 6e 7d 20 61 |ns \rou{|plbin} a|
|00002400| 6e 64 20 5c 72 6f 75 7b | 70 6c 68 69 73 74 7d 20 |nd \rou{|plhist} |
|00002410| 61 72 65 20 70 72 6f 76 | 69 64 65 64 20 66 6f 72 |are prov|ided for|
|00002420| 0a 64 72 61 77 69 6e 67 | 20 68 69 73 74 6f 67 72 |.drawing| histogr|
|00002430| 61 6d 73 2c 20 61 6e 64 | 20 66 75 6e 63 74 69 6f |ams, and| functio|
|00002440| 6e 73 20 5c 72 6f 75 7b | 70 6c 65 72 72 78 7d 0a |ns \rou{|plerrx}.|
|00002450| 61 6e 64 20 5c 72 6f 75 | 7b 70 6c 65 72 72 79 7d |and \rou|{plerry}|
|00002460| 20 64 72 61 77 20 65 72 | 72 6f 72 20 62 61 72 73 | draw er|ror bars|
|00002470| 20 61 62 6f 75 74 20 73 | 70 65 63 69 66 69 65 64 | about s|pecified|
|00002480| 0a 70 6f 69 6e 74 73 2e | 20 54 68 65 79 20 61 72 |.points.| They ar|
|00002490| 65 20 64 65 73 63 72 69 | 62 65 64 20 69 6e 20 64 |e descri|bed in d|
|000024a0| 65 74 61 69 6c 20 69 6e | 20 43 68 61 70 74 65 72 |etail in| Chapter|
|000024b0| 20 5c 72 65 66 7b 72 65 | 66 65 72 65 6e 63 65 7d | \ref{re|ference}|
|000024c0| 2e 0a 0a 5c 73 65 63 74 | 69 6f 6e 20 7b 46 69 6e |...\sect|ion {Fin|
|000024d0| 69 73 68 69 6e 67 20 55 | 70 7d 0a 0a 42 65 66 6f |ishing U|p}..Befo|
|000024e0| 72 65 20 74 68 65 20 65 | 6e 64 20 6f 66 20 74 68 |re the e|nd of th|
|000024f0| 65 20 70 72 6f 67 72 61 | 6d 2c 20 61 6c 77 61 79 |e progra|m, alway|
|00002500| 73 20 63 61 6c 6c 20 5c | 72 6f 75 7b 70 6c 65 6e |s call \|rou{plen|
|00002510| 64 7d 0a 74 6f 20 63 6c | 6f 73 65 20 61 6e 79 20 |d}.to cl|ose any |
|00002520| 6f 75 74 70 75 74 20 70 | 6c 6f 74 20 66 69 6c 65 |output p|lot file|
|00002530| 20 61 6e 64 20 74 6f 20 | 66 72 65 65 20 75 70 20 | and to |free up |
|00002540| 61 6e 79 20 6d 65 6d 6f | 72 79 20 74 68 61 74 20 |any memo|ry that |
|00002550| 6d 61 79 0a 68 61 76 65 | 20 62 65 65 6e 20 61 6c |may.have| been al|
|00002560| 6c 6f 63 61 74 65 64 2e | 0a 46 6f 72 20 64 65 76 |located.|.For dev|
|00002570| 69 63 65 73 20 74 68 61 | 74 20 68 61 76 65 20 73 |ices tha|t have s|
|00002580| 65 70 61 72 61 74 65 20 | 67 72 61 70 68 69 63 73 |eparate |graphics|
|00002590| 0a 61 6e 64 20 74 65 78 | 74 20 6d 6f 64 65 73 2c |.and tex|t modes,|
|000025a0| 20 7b 5c 74 74 20 70 6c | 65 6e 64 7d 20 61 6c 77 | {\tt pl|end} alw|
|000025b0| 61 79 73 20 72 65 73 65 | 74 73 20 74 68 65 20 64 |ays rese|ts the d|
|000025c0| 65 76 69 63 65 20 69 6e | 74 6f 20 74 65 78 74 20 |evice in|to text |
|000025d0| 6d 6f 64 65 2e 20 49 66 | 0a 69 74 20 69 73 20 72 |mode. If|.it is r|
|000025e0| 65 71 75 69 72 65 64 20 | 74 6f 20 73 77 69 74 63 |equired |to switc|
|000025f0| 68 20 62 65 74 77 65 65 | 6e 20 6d 6f 64 65 73 20 |h betwee|n modes |
|00002600| 77 69 74 68 69 6e 20 61 | 20 70 72 6f 67 72 61 6d |within a| program|
|00002610| 2c 20 74 68 65 20 66 75 | 6e 63 74 69 6f 6e 73 0a |, the fu|nctions.|
|00002620| 5c 72 6f 75 7b 70 6c 67 | 72 61 7d 20 61 6e 64 20 |\rou{plg|ra} and |
|00002630| 5c 72 6f 75 7b 70 6c 74 | 65 78 74 7d 20 73 65 74 |\rou{plt|ext} set|
|00002640| 20 74 68 65 20 64 65 76 | 69 63 65 20 74 6f 20 67 | the dev|ice to g|
|00002650| 72 61 70 68 69 63 73 20 | 61 6e 64 20 74 65 78 74 |raphics |and text|
|00002660| 20 6d 6f 64 65 73 0a 72 | 65 73 70 65 63 74 69 76 | modes.r|espectiv|
|00002670| 65 6c 79 2e 0a 0a 0a | |ely.... | |
+--------+-------------------------+-------------------------+--------+--------+