Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2004
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2004

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Mathematica 2.2 and 'EllipticIntegrate' package problem

  • To: mathgroup at smc.vnet.net
  • Subject: [mg46274] Re: Mathematica 2.2 and 'EllipticIntegrate' package problem
  • From: tdickens at att.net (Tom Dickens)
  • Date: Thu, 12 Feb 2004 22:47:17 -0500 (EST)
  • References: <c0fi56$9qs$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

All,
I found the answer to my own question. There is a file ctoffix.m that
needs to be included in the init.m file. Here are its contents:




(* Here is a fix for DOS or Windows versions that are being run on a
DOS compatible OS that provides
for more than the standard DOS 8.3 file name convention.  Mathematica
for DOS and Windows relies
on the DOS operating system to "silently" truncate a filename to the
8.3 format.  On some systems, like
Novell servers, this truncation does not occur.  This is a replacement
for the standard ContextToFilename
command. 
It simply truncates every context name to eight characters, and joins
them with the DOS pathname
separator, appending a ".m" on the end to specify the package
filename.  Thus, it takes care of everything but
special cases where simple truncation would yield ambiguous names in
our packages, but those are dealt
with in our initializations already. This package could be added to
INIT.M to provide this service
every time Mathematica for DOS or Windows is run. villegas (Thu, 25
Mar 1993) modified 4/5/93
tgayley (added Protect/Unprotect) updated Thu, 9 Apr 1993 by villegas.
 Included StringReadList and
usage  message previously overlooked. *)

StringReadList::usage = "StringReadList[string, args] calls ReadList
with
the given arguments on the input string, after converting it to a
stream.
It closes the string stream after it is finished using it, so you
don't
accumulate open string streams in Streams[] when you want to analyze
lots of strings in a session."

StringReadList[str_String, args__] :=
Module[{stream, readlist},
   stream = StringToStream[str];
   readlist = ReadList[stream, args];
   Close[stream];
   readlist
]

Inscribe::usage = "Inscribe[{a, b, ..., z}, obj] alternates the
elements of the first list with the single expression 'obj'.  Thus,
it returns {a, obj, b, obj, ..., obj, z}.  It is useful to form a
full pathname out of the levels of the path, inserting the same
pathname separator (given by the value of the environmental variable
$PathnameSeparator in Mathematica) between each level."

Inscribe[list_List, loner_] :=
  Drop[#, -1]& @ Flatten[#, 1]& @ Thread[{ list, loner }] /;
    Head[loner] =!= List

Unprotect[ContextToFilename]

ContextToFilename[ctx_String] :=
Module[{parts, path, truncate},
  parts = StringReadList[ctx, Word, WordSeparators->{"`"}];
  truncate = ToLowerCase @ StringTake[#, Min[8, StringLength[#]]] &;
  path = Map[truncate, parts];
  StringJoin[##, ".m"]& @@ Inscribe[path, $PathnameSeparator]
]

Protect[ContextToFilename];





















------------------------------------------------------------------------------

NOSPAM_tdickens at worldnet.att.net (Thomas Dickens) wrote in message news:<c0fi56$9qs$1 at smc.vnet.net>...
> Forgive me for asking a question about such an old version!
> 
> I recently purchased a used Mathematica v2.2, and it seems to run fine
> on Win XP. However, I cannot get the Calculus`EllipticIntegrate`
> package to work. It seems to load without incident, but I am still
> unable to do the classic elliptic integrals like
> 
> <<Calculus`EllipticIntegrate`
> Integrate[ Sqrt[ 1 + a Cos[u]^2 ], {u,0,p}].
> 
> Any thoughts on why? All the other extension packages (e. g. DSolve)
> seem to create added functionality just like they should.
> 
> Thanks,


  • Prev by Date: RE: MultipleListPlot
  • Next by Date: Estimating parameters p and q in y'' + p y' + q y = Tide(t)
  • Previous by thread: Mathematica 2.2 and 'EllipticIntegrate' package problem
  • Next by thread: FindRoot in Version 5