Mathematica 9 is now available
Student Support Forum
Student Support Forum: 'Re: Packages create/save/load...' topicStudent Support Forum > General > "Re: Packages create/save/load..."

Help | Reply To Topic
Author Comment/Response
John Leko
11/24/00 2:06pm

>Hello !
>The problem I tried to solve for quite a while now is: How to create my own
Packages and load it into the session.
>I own the Student-Version 3.0, so the question is if ''own'' Packages can be done
>I tried to save a little test-Package using File/Save As Special/Package Format,
the load it into a new session, but it didnt work.
>(by the way: I discovered Mathematica saved my Package inside some
commet-brackets (* *), as I look to the Standard-Packages, there are also a lot of
comments, but the ''Program'' itself has no bounding comment-brackets, AFAIK )
>So, please, how to create/save/load in Packages generally??
>Thanks for patience,

Packages are a bit more then a string of interactive commands saved in a different
format. When building a package, you want to account for the fact that the
variables you are using may conflict with those of your package's user. So you
want to invoke Contexts to hide you packages variables. You also need to specify
the start and finish of you code using BeginPackage, Begin, End, and EndPackage
commands. You might want to read through section 2.6.10, ''Setting Up Mathamatica
Packages'' as well as the sections explaining Contexts. Another good source for
this information is Roman Maeder's book, ''Programming in Mathematica.''

URL: ,
Help | Reply To Topic