home *** CD-ROM | disk | FTP | other *** search
/ Math Solutions 1995 October / Math_Solutions_CD-ROM_Walnut_Creek_October_1995.iso / pc / mac / graphing / rlab / readme.mac < prev    next >
Encoding:
Text File  |  1995-02-25  |  11.1 KB  |  260 lines

  1.                                                 
  2.                                                             02/25/1995
  3.  
  4.  
  5. This is the Macintosh port of RLaB 1.18c program. RLaB is a Matlab-like 
  6. linear algebra package.  The author is 
  7.     
  8.          Ian Searle
  9.          ians@eskimo.com
  10.     
  11. RLaB is an interpreter for the RLaB Programming Language/Environment. 
  12. The RLaB language is useful for matrix or array oriented numerical
  13. analyses. RLaB is especially useful for prototyping and experimenting 
  14. with algorithms. RLaB extensively uses the BLAS, LAPACK, FFTPACK and 
  15. RANLIB sources available from netlib.att.com and PLPLOT from 
  16. dino.ph.utexas.edu.
  17.         
  18. MacRLaB is not a full port of RLaB.  Some items will probably never
  19. be fully supported as they are too tied to the Unix operating system.  
  20. Examples are the 'pipe', the 'fork', and many others.  
  21. Other features are handled a little differently in the Mac version.  
  22. Most of the important differences or extensions of the MacRLaB port 
  23. are described below.
  24.  
  25. 1. Please print out and study the RLaB Primer first, the file is in
  26.    ":doc:rlabp.ps". You can print this Postscript file using 'Drop•PS' 
  27.    program (simply drag and drop it onto Drop•PS).
  28.  
  29.    (Files in rlab folder are getting larger, many folders are compressed
  30.     as self-extracting-archives (.sea), you can double-click on them to 
  31.     uncompress them.)
  32.   
  33. 2. You can set up your own file search-path(RLAB_SEARCH_PATH), 
  34.    start-up file (RLAB_RC0), etc.. The default settings are stored in the file 
  35.    'RLab-Preference'. 
  36.    
  37.    To change these settings, just use a text editor to change.  You have to
  38.    set the PLPLOT_DIR environmental variable to the path of your RLaB folder.  
  39.    This setting is important because PLPLOT has to know the location of font 
  40.    files 'plstnd5.fnt' and 'plxtnd5.fnt'.  After making the changes, the file 
  41.    'RLab-Preference' has to be placed in the 'System Folder:Preferences' folder.
  42.  
  43.    For example, if your absolute RLaB folder (directory) path is like this
  44.    
  45.    HD --- Appl --- RLaB 
  46.    
  47.    then you can put the following environmental variables in 'RLab-Preference':
  48.    
  49.    RLAB_RC0 = "HD:Appl:RLaB:_rlab";
  50.    PLPLOT_DIR = "HD:Appl:RLaB";
  51.    RLAB_HELP_DIR = "HD:Appl:RLaB:help";
  52.    RLAB_LIB_DIR = "HD:Appl:RLaB:rlib";
  53.    RLAB_SEARCH_PATH = ";HD:Appl:RLaB:toolbox;HD:Appl:RLaB:examples"; 
  54.  
  55.    You can have several search-paths, just put them together and use ';' as
  56.    delimiter (see above example with 3 search paths, first one is for the
  57.    current folder).
  58.    
  59.    If you feel the font/size on the MacRLaB console is not the best choice, 
  60.    feel free to change it.  The environmental variable RLAB_FONT can be set
  61.    to one of the following numbers (check Mac document for more):
  62.    
  63.                0 SystemFont
  64.                1 AppleFont
  65.                2 NewYork
  66.                3 Geneva
  67.                4 Monaco
  68.                5 Venice
  69.                6 London
  70.                7 Athens
  71.                8 SanFrancisco
  72.                9 Toronto
  73.               11 Cairo
  74.               12 LosAngles
  75.               20 Times
  76.               21 Helvetica
  77.               22 Courier
  78.  
  79.    It is better to use constant width fonts such as Monaco and Courier,
  80.    otherwise the output will not be aligned.
  81.    The font size (RLAB_SIZE) can be set to any number between 1 and 127 point.  
  82.    The popular font sizes for the console are 
  83.                
  84.                9 points
  85.               10 points
  86.               11 points
  87.               12 points
  88.               14 points
  89.               18 points
  90.               
  91.    You can change the number of text rows (RLAB_ROWS) on the console.  
  92.    Default values are   
  93.  
  94.               RLAB_FONT = "4 Monaco";
  95.               RLAB_SIZE = "9 points";
  96.               RLAB_ROWS = "25";
  97.     
  98.    The console window width will be set to 80 columns based on the largest 
  99.    character width of the selected font.
  100.            
  101. 3. By the way, do you know how to change directory (folder) using cd() on the 
  102.    Mac? 
  103.    
  104.    Suppose your hard disk directory tree is like this
  105.    
  106.                             ----- Peggy
  107.                             |                             |-- rlib
  108.          --------- App -----|                             |
  109.          |                  |                             |-- examples
  110.    HD ---|                  ----- RLaB (you are here) ----|
  111.          |                                                |-- help
  112.          -------- Kevin                                   |
  113.                                                           |-- toolbox
  114.          
  115.    When you launch RLaB, you are in RLaB directory.  If you wish to 
  116.    change directory to "examples", you can use either
  117.    
  118.    >cd(":examples");  // relative method
  119.    
  120.    or
  121.    
  122.    >cd("HD:App:RLaB:examples");  // absolute method
  123.    
  124.    The colon ":" means present directory, it is similar to "." on the Unix
  125.    but not exactly the same.  You MUST supply a ":" as first char if partial 
  126.    (relative) pathname is used.  If the first character of a pathname is not 
  127.    a ":", it is a full (absolute) pathname.  Two colons "::" means parent 
  128.    directory (folder).  Three colons ":::" means grandparent directory.
  129.    The ":" character also acts as directory delimiter, like "/" on the unix 
  130.    and "\" on the MS-DOS.
  131.    
  132.    For example, if your work directory is in Kevin and you are in 
  133.    RLaB now,  you can use either
  134.    
  135.    >cd(":::Kevin");   // relative method
  136.    
  137.    or
  138.    
  139.    >cd("HD:Kevin");   // absolute method
  140.    
  141.    to change directory to Kevin.
  142.  
  143. 4. RLaB comes with a built-in plotting library PLPLOT.  PLPLOT is a powerful 
  144.    tool for XY and XYZ graphics.  It can generate (via plprint) Postscript, 
  145.    color Postscript, HP LJ, and lots of other formats for post processing. 
  146.  
  147.    I've implemented a minimum Mac interface for PLPLOT4.99i.  Multi-window is 
  148.    allowed but the redrawing is slow; well, that depends on what machine you 
  149.    got.  The number of windows is limited to 10.  
  150.    
  151.    The mac-plplot interface is based on ColorQuickDraw routines.  Sixteen 
  152.    colors are directly available in PLPLOT. These colors are pre-assigned 
  153.    as the following numbers:
  154.    
  155.       1       2         3        4        5         6         7       8
  156.      black   red    yellow      green  aquamarine  pink     wheat   gray
  157.    
  158.       9      10        11       12       13        14        15      16
  159.      brown   blue   blueviolet  cyan   turquoise   magenta  salmon  white 
  160.       
  161.    You can select color by _plcol() function.  More colors are available by
  162.    using RGB combinations (see PLPLOT manual). There are three things remained  
  163.    to be done -- add scroll bar to the MacRLaB window, add copy/paste ability 
  164.    in the graphics windows, and add PICT image to the generated EPSF files.
  165.    
  166.    You can include the PLPLOT generated Postscript output (EPSF) in your 
  167.    document (Word, MacDraw, Canvas, TeX, ...) but you can only see a 
  168.    big crossed box (the bounding box) on the screen due to the lack of the 
  169.    PICT image. You can perform scaling, rotating, dragging,... on the box 
  170.    except there is no picture inside.  Don't worry, the picture will appear 
  171.    in the printed copy.
  172.    
  173.    If you need superscript, subscript, over/under line char, and Greek letters 
  174.    in annotation of axis, title, etc., then you need to get a copy of PLPLOT 
  175.    manual.  See README.PLPLOT for detail.  
  176.    
  177.    There is a plotting example in ":examples:plot_test.r", try
  178.    
  179.    >rfile plot_test
  180.  
  181.    You can click on those background windows to see them again. The graphics 
  182.    windows are numbered as plplot 0, plplot 1, plplot 2, ..., and so on.  You 
  183.    can also resize or drag them.  Resizing on the screen will not affect 
  184.    the quality of later plprint() output. 
  185.    
  186.    For each graph window, there is a temporary file (SCRATCH????) 
  187.    associated with it.  It contains your plotting commands which can be used
  188.    later to produce a Postscript or other types of graphics file (via
  189.    plprint).  It is also used by my Mac interface in redrawing.  Don't dump
  190.    them into trash can during the execution of MacRLaB.   They will be 
  191.    automatically eliminated after the execution.   Also, don't use pend() 
  192.    to close graphics windows unless you don't want to plot anymore. Use 
  193.    pclose() instead.  plplot has a bug that it does not close the plotting 
  194.    command file even you close the graphics window by pend() or pclose().  
  195.    So if you plot after pend(), the old picture together with the new picture
  196.    will appear on the graphics window.
  197.    
  198.    If you plot several pages of PS graph into a file, you have to change 
  199.    the file type to 'TEXT' (all capital) by drag and drop the file onto
  200.    ctc 1.5.  After the file type has been changed, you can print it out 
  201.    by Drop•PS or ShowPages.  Why?  Because plplot creates the PS output file
  202.    in binary mode, but Drop•PS and ShowPages accept only TEXT file.
  203.       
  204.  
  205. 5. The full history command editing capacity is built-in.  To recall 
  206.    previous commands, just press up and down arrow keys.  
  207.    The 'control' key described in the RLaB Primer can be replaced by the 
  208.    'command' key on the Mac keyboard.  Delete-cursor-character (del) is also 
  209.    supported.  The full description of command line editing is in the file
  210.    ":help:COMMAND_EDIT", or type "help COMMAND_EDIT" in RLaB.
  211.  
  212.    
  213. 6. Your machine must have a 68020 or better cpu to run MacRLaB.  You also 
  214.    need System 7 to run it.  If your machine does not have an fpu (68881 or 
  215.    better) then you should run MacRLaB-nofpu instead of MacRLaB.
  216.    
  217.    Try
  218.    
  219.    >load("test")
  220.  
  221.    on your machine to see if your machine can pass all tests.
  222.          
  223. 7. The total size of arrays is only limited by the available memory of your 
  224.    machine.  If RLaB runs out of memory, it will display
  225.        
  226.         RLaB: out of memory. 
  227.         
  228.    on the screen.  You can either increase RLaB memory using 'Get Info' of 
  229.    System 7 Finder or, if your physical RAM is limited, turn on the virtual
  230.    memory and set the memory size large enough for your application.
  231.  
  232. 8. To interrupt RLaB during execution, type command-. (i.e. press command 
  233.    key + period key), it will return to the interactive mode in the next i/o.  
  234.    To abort RLaB and kick it out, you can use File-Quit (command-Q) on Menu bar. 
  235.    You can also do so by type in command-d at the beginning of a command 
  236.    line, or type "quit" directly.
  237.    If RLaB hangs, press command-option-esc to abort it.
  238.  
  239. 9. The source code of mac version is merged in the rlab source code 
  240.    distribution (see :misc:ftp-sites).  Those statements within 
  241.                #ifdef THINK_C  ... #endif 
  242.    are my modifications for THINK C 7.03 compiler on the Mac.  I've modified the 
  243.    console user interface.  Three difference files diff1, diff2, and diff3 
  244.    tell you those modifications (they are in :misc:MAC).  You also need f2c 
  245.    and POSIX libraries.  They are available in info-mac archives.
  246.    
  247. 10. If you wish to join the RLaB community, send an email to Ian 
  248.     (ians@eskimo.com) and ask him to add your name in the mailing list.  
  249.     You can reach the RLaB community by sending email to rlab-list@eskimo.com.
  250.    
  251. 11. We need more tools.  Please send your useful rfiles to Ian.  Thanks.
  252.  
  253. 12. THIS IS FREE SOFTWARE. THERE IS NO WARRANTY FOR THE PROGRAM.  USE IT AT 
  254.     YOUR OWN RISK.  
  255.  
  256. Have fun!
  257.  
  258. Tzong-Shuoh Yang   
  259. (tsyang@ce.berkeley.edu) 
  260.