maxgacode | 29 Jul 22:20 2014
Picon

Information

I'm a new user of maxima and I use it on Windows platform. I ahve a
question related to the installation package.

Is there any reason for stopping the building of Windows installation
package at 5.31.2? I have to admit that the compilation of Maxima on
windows platform is quite difficult to me, so an updated installation
package is welcome.

Thank you and Regards

------------------------------------------------------------------------------
Infragistics Professional
Build stunning WinForms apps today!
Reboot your WinForms applications with our WinForms controls. 
Build a bridge from your legacy apps to the future.
http://pubads.g.doubleclick.net/gampad/clk?id=153845071&iu=/4140/ostg.clktrk
Richard Fateman | 27 Jul 06:11 2014
Picon

maixma.bat erased?

Dunno what I've done wrong, but my previous copy of maxima.bat

in c:/Program Files/..../bin/maxima.bat

was altered to be a zero-length file.

I downloaded the latest version, and used it for a while, and
maxima.bat again changed to zero length.

Was I doing something strange?  Maybe.  I was using emacs, opening up
a *shell* window, and executing maxima.bat .  But then that stopped.
And now wxmaxima fails because it too needs that file.
Is there some configuration program messing with this??
(I'm using Windows XP, GCL version of Maxima)

Thanks
RJF

------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
Pankaj Sejwal | 26 Jul 18:20 2014
Picon

Re: Maxima-discuss Digest, Vol 6, Issue 46

​Instead of ev I tried with eval and it seems to fix the problem of nested application of segment.
f(1,segment(4,segment(5,6))),eval;  => f(1,4,5,6)
As far as multiple assignments are concerned,
f(segment(a,segment(b,c))),eval; => f(d,e,f)
Assignment seems to jump 3 level  in a:b:c:d:e:f here.
f(segment(a)),eval => f(d)
f(segment(c)),eval => f(f)



    (%i6) f(segment(a, segment(b)));
    (%o6) f(a,segment(b))

    (%i7) ev(%,nouns);
    (%o7) f(a,b)

OK:

    (%i8) (a:b,b:c,c:d,d:e);
    (%o8) e

    (%i9) f(a,segment(b,c),d);
    (%o9) f(b,c,d,e)

Maybe unwanted:

    (%i10) f(a,segment(b,segment(c)));
    (%o10) f(b,c,segment(d))

    (%i11) ev(%,nouns);
    (%o11) f(c,d,e)

​>>>>>>>>>>>>RJF's response>>>>>>>>>>>
Maybe I'm just not going to be able to do this "right" with Maxima because
it seems to not fit with the "evaluate once" practice.   Also, by modifying
segments in place, I'm maybe changing things that should not. This
last part should be changed easily by replacing an nconc with an append
in the code...


 
Regards,
Pankaj Sejwal
_____________________________________________________________________
"The more I read, the more I acquire, the more certain I am that I know nothing.” -
Voltaire
------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
Maxima-discuss mailing list
Maxima-discuss <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/maxima-discuss
Richard Fateman | 26 Jul 17:12 2014
Picon

test suite failure

In testing segment etc, I found that
test 9 fails..  maxima 5.31.2 GCL 2.6.8 wxmaxima 13.04.02

block([a,L],a:make_array(fixnum,3),L:buildq([a],lambda([x],a[x])),print(L,L(0)))

It fails in a vanilla fresh-loaded maxima.

After loading segment stuff it still fails :).

RJF

------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
Jules Gilbert | 26 Jul 01:34 2014
Picon

about the SBCL bignum floating-point overflow bug

Yes, it got me also.
 
And changing to another lisp is a little difficult at the moment.  Does anyone has a patch or work-around??
------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
Maxima-discuss mailing list
Maxima-discuss <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/maxima-discuss
Raymond Toy | 26 Jul 07:40 2014
Picon

Fwd: might their be some declarations I can add in Maxima to solve this problem??

I'm more than happy to answer questions, but please don't email me directly.

You left out some steps because c must be some large rational number and you must be doing something like float(c) or c,numer.

​For large enough c, the floating-point error is inevitable because floating-point numbers have an upper limit. If you want to continue to use a floating-point approximation to c, you can use bigfloats via bfloat(c). Bigfloats have no limit on the size of the exponent (except  for memory).

---------- Forwarded message ----------
From: Jules Gilbert <jules_gilbert <at> mail.com>
Date: Fri, Jul 25, 2014 at 7:59 PM
Subject: might their be some declarations I can add in Maxima to solve this problem??
To: toy.raymond <at> gmail.com


Subject: help!, relating to maxima/SBCL/FreeBSD floating-point overflow bug
I said:
 
a : <large integer constant> ;
 
b : 15;
 
c : a/b;
 
and got a floating-point overflow from Maxima / SBCL under FreeBSD;  Now I have discovered that this particular architecture combination has a problem.
 
To wit, this:
 
 
 arithmetic error FLOATING-POINT-OVERFLOW signalled

Operation was SCALE-FLOAT, operands (0.3410639409623417 1323).
 
 
Maybe I need to move to the CLisp implementation.  But I am trying to finish my project and switching would be a real problem for me.
 
Is their any kind of patch?  What do you know??
 
Here's the code...
 
Maxima 5.26.0 http://maxima.sourceforge.net
using Lisp SBCL 1.0.55
Distributed under the GNU Public License. See the file COPYING.
Dedicated to the memory of William Schelter.
The function bug_report() provides bug reporting information.
(%i1) 
(%i2) 
(%i3) 
Maxima encountered a Lisp error:
 arithmetic error FLOATING-POINT-OVERFLOW signalled
Operation was SCALE-FLOAT, operands (0.3410639409623417 1323).
Automatically continuing.
To enable the Lisp debugger set *debugger-hook* to nil.
(%i4) 

------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
Maxima-discuss mailing list
Maxima-discuss <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/maxima-discuss
Richard Fateman | 26 Jul 05:08 2014
Picon

segment implementation in Maxima

If you don't want to use segments, you don't have to do anything.
If you DO, then grab the file in

http://www.cs.berkeley.edu/~fateman/lisp/segment-max.lisp  and call it, 
say c:/foo.lisp.

you can compile it on your maxima system  via

:lisp (compile-file "c:/foo.lisp")

and load it via

load("c:/foo.o")      or maybe load("c:/foo.fasl")   depending on your 
brand of lisp.

To make segments work, type

use_segment(true);

to stop them from working, and restore the speed of the system, type
use_segment(false).

Comments welcome.  Maybe someone would care to place this in share etc.
RJF

------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
David Ronis | 25 Jul 18:52 2014
Picon

Problem(?) with partfract

Consider the following example:

declare(A, real)$
declare(B, real)$
declare(C, real)$
declare(D, real)$
domain:complex$
polyfactor:true;
factorflag:true;

f(x):=1/(x^2 + (B+%i*D)*x+C);
partfrac(f(x), x);

f(x):=1/(x^2 + 1);
partfrac(f(x), x);

When run I get:

(%i99) partfrac(f(x), x);
                                       1
(%o99)                       ---------------------
                                                 2
                             x (%i D + B) + C + x

and

(%i101) partfrac(f(x), x);
                                      1
(%o101)                             ------
                                     2
                                    x  + 1

respectively.  This is obviously not correct; e.g., in the 2'nd example I should get something like:

                       %i/2/(x+%i) - %i/2/(x-%i)

Perhaps related to this is my inability to get maxima to factor the quadratic in the first example (I tried
factor and gfactor).

Thanks in advance

David

------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
Richard Fateman | 24 Jul 17:16 2014
Picon

Mathematica-style pattern-matching in Maxima

(July 24, 2014)

copy the directory http://www.cs.berkeley.edu/~fateman/lisp/mma4max

I've mucked around with the MockMMA code from years ago.  This code
does a lot more than pattern matching (e.g. symbolic integration,
rational simplification ....)   but the part that is specifically being
interfaced and described here with respect to Maxima is the pattern
matcher.  I'm assuming you know something of pattern matching in
Mathematica.  If not, the next few paragraphs will not make much sense.
............

 From the README file

This is a touch-up for Maxima, GCL in particular, allowing what
appears to be direct access to the pattern matching in MockMMA.
Actually there is some translation to and from the MockMMA representation
from Maxima.
Until someone comes up with an alternative simple Maxima
syntax for patterns like those in Mathematica, we will use the
roughly equivalent FullForm style patterns. Though we use () instead of [].

Thus Mathematica's
_       is Blank()
a_      is Pattern(a,Blank())
a__     is Pattern(a,BlankSequence())
a___    is Pattern(a,BlankNullSequence())
a_foo   is Pattern(a,Blank(foo))
a?fooq  is PatternTest(a,fooq)

Now if you don't like to write these things explicitly
you can, for example, write z:Pattern(a,BlankNullSequence())
and use z in patterns.

There are a host of uses of patterns in Mathematica that we do
not explicitly or implicitly support, e.g. member, subst,
but which could be programmed.
We can (already do) support in MockMMA the pattern-replacement
evaluation typical of Mathematica.  However, this is in conflict
with the usual Maxima evaluation process, and so the support here
implicitly is for the Maxima user to convert the data into the
mma format, mess around with it for a while with a different
model of evaluation, and convert it back.

Here's what we support "out of the box" here, as of July 24, 2014.
A program sm   (for simple match)

sm(p,e,vars)  is how it is called.
p is a pattern
e is an expression to be matched
vars is a list of variables whose binding is of interest.

  sm(Pattern(aa,BlankSequence())+x, y+z+x,[aa]);
   returns [aa=z+y]

   sm(Cos(Pattern(a,Blank()))+Pattern(a,Blank()), x+Cos(x),[a]);
   returns [a=x]

   sm(Cos(Pattern(a,Blank()))+Pattern(b,Blank()), y+Cos(x)+z,[a,b]);
   returns [a=x,b=z+y]

   sm(Cos(Blank()),43,[])
   returns false
..........
the README file continues with installation instructions etc.
I'm happy to receive comments.  However, be alerted to the possibility
that the bugs you find may be your "user  errors" in designing patterns,
rather than the pattern matching code itself. So look carefully.

Not that the code is so perfectly written etc.   Just that
in my own personal experience, I'm far more likely to write a bad
pattern than to newly discover a bug in the matching code.

There is a file  hey.batch with about 140 patterns in MockMMA syntax
testing various features.  And a whole bunch of other stuff after
that to exercise MockMMA's general programming.  None of this will
work directly in Maxima because the syntax is not Maxima syntax.

It is entirely possible to have Maxima read MockMMA syntax, e.g.
(%i54)  Convert2Maxima("a_+Cos[a_]")
   but then where do you go with that?  Also there are sticky parts
of the parsing program with respect to low-level input of characters..
it doesn't seem to work with wxmaxima but is ok in simpler modes.
Maybe switching readtables is problem??
This stuff described here sm(p,e,vars) does not use the parser.

RJF

------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
Henry Baker | 24 Jul 16:35 2014
Picon

matching non-commutative "." patterns

I'd like to match patterns for terms like

a*b*B.C.X.Y.Z

as:

a*b - product of constants and scalars
B.C - product of non-"X" nonscalars
X - the variable we're looking for
Y.Z - product of non-"X" nonscalars

Need less to say, due to noncommutativity of ".", it gets more complicated to deal with multiple instances
of non-"X" nonscalars, scalars, etc.

This is for solving quaternion algebraic equations.

Thanks for any help.

------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
Edwin Woollett | 23 Jul 22:30 2014
Picon

project 2, Structure of a White Dwarf Star, posted

Project2: the Structure of a White Dwarf Star,
 is part of Chapter 2, Initial Value Problems,
in the series Computational Physics Using R and Maxima,
and has been posted on my web page.

The code emphasizes the use of list arithmetic methods
in Maxima (vector arithmetic methods in R).

>From the web page http://www.csulb.edu/~woollett
--------------------------------------------------------------------------------
Project 2: Structure of a White Dwarf Star --NEW--7/23/2014

A pedagogical discussion of the differential equations for the
 mass profile m(r) and the mass density profile rho(r), assuming
 the cold degenerate relativistic electron gas provides the
 internal pressure, and the non-degenerate heavy nuclei provide
 the gravitational attraction. Both R and Maxima code are used
 in parallel treatments to draw plots (for a given central density)
 of m(r), rho(r), kinetic energy profile k(r), gravitational energy
 profile u(r), and to explore the total energy (including rest mass
 energy) as a function of central mass density and the stellar
 mass, and to plot the stellar radius as a function of stellar mass.

    --project2.pdf : Project 2, July 23, 2014, Maxima 5.31.2, R 3.0.2, 27 
pages
    --project2.tex : Project 2 Latex code file, July 23, 2014
    --project2.R : R code for Project 2, July 23, 2014, R 3.0.2
    --project2.mac : Maxima code for Project 2 , July 23, 2014, Maxima 5.31
    --project2.zip : zip file contains all files for Project 2, July 23, 
2014
 --------------------------------------------------------------------

Ted Woollett

------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds

Gmane