Gannon University

Gannon University


Home Page

Teaching

Research

Personal Information

Vita

Department of Mathematics

GU home

Gannon University
  Dr. Geoffrey Dietz

Macaulay 2 Tips
  • When running Macaulay2 from the command line using input from a file, use "<<" before a command to force the output to be displayed on screen.
  • In order to run a long computation on a remote server without staying connected, use the following command:
    nohup M2 file.m2 | & mailx -s "subject" name@domain &

    This command will run Macaulay from file.m2 and then email the output in a message with the specified subject line to the address specified. Both processes are run in the background, and the "nohup" ensures that they will not be terminated when you disconnect from the server.
    CAUTION! The email will only contain the output of the commands preceded by "<<" in your file.
    CAUTION! Since Macaulay2 needs to exit before the email is sent, you must include a final line in your file to force Macaulay2 to exit. Including "^D" (the end of file character in UNIX) as the final line will actually cause Macaulay2 to "crash", but it is sufficient to end Macaualy2 so that the email with your output can be sent.


  • To install Macaulay and emacs for Mac OS X:
    • Download Fink for OS X. Make sure the line ". /sw/bin/init.sh" is in your .profile file.
    • Add the line "source /sw/bin/init.sh" to your .xinitrc file.
    • Using Fink Commander, install the packages emacs21 and macaulay2.
    • Add the line "(load "/sw/lib/Macaulay2-0.9.2/emacs/M2-init.el")" to your .emacs file.


Geoffrey Dietz
Department of Mathematics
Gannon University
109 University Square
Erie, PA 16541

dietz005 AT gannon.edu