33.6 How to set up if someone else compiled the code — UNIX

It is easy to bum off of a friend who is running NC on the same system.

33.6.1 When your system administrator installed the code

When your system administrator installed the code, he had several choices.

The first thing you should try is to start Mathematica by typing math and then type <<SetNCPath.m. If there are no error messages, then type <<NCAlgebra.m. Mathematica should respond with a sequence of statements indicating that various files are being loaded.

If Mathematica responds with Get::noopen: Cannot open SetNCPath.m, then additional steps are required as described below.

You need to determine where your system administrator installed NCAlgebra. The easiest way to do this is to ask your system administrator. If that is not easy and/or convenient, then you can type

cd   find / -name
and look at the result. Note that this command will take some time and will access the hard drive quite a bit. If this is done on our system, then the result is the directory
/home/ncalg/NC/NCAlgebra/NCAlgebra.m    .
The location of the installation in this case is /home/ncalg/NC .

Let us suppose that you know the location of the installation of NCAlgebra. Let us suppose that it is located in the directory /usr/local/NC.

Move into the directory where you want to use NCAlgebra (or create such a directory using the mkdir command). Create an init.m file with your favorite editor which contains the following lines:

AppendTo[$Path,"/usr/local/NC/"];  
Get["SetNCPath.m"];

Type math and then type <<NCAlgebra.m. Then Mathematica responds with a sequence of statements indicating that files are being loaded.

33.6.2 When your friend installed the code

Suppose that your friend has installed the code and he is willing to let you use his version of the code (see (6)), then you can follow this procedure:

(1) Have your friend log into his account and change directories into the one which contains the NC code. Suppose for definitiveness that it is located in the directory /home/JoeShmo/NC/. In this case, you would type cd /home/JoeShmo/NC
(2) Type chmod -R uog+r *. This allows all of these files to be read by anyone. (These files are available through the web, so giving permission to read them should be OK with your friend.)
(3) Edit the file SetNCPath.m. Make sure that there is a command
$NCDir$ = "/home/JoeShmo/NC"

(4) Type cd ../
(5) Type chmod u+rx NC. This allows the directory to be readable by anyone. For some reason, some computer systems require that a directory be executable. I don’t know why.
(6) Type cd ..
(7) Type chmod u+rx JoeShmo. This allows the directory to be readable by anyone. For some reason, some computer systems require that an directory be executable. I don’t know why. Your friend may or may not be willing to take this step.

Now, follow the directions in Section 33.6.1.