Hello community, here is the log from the commit of package mathomatic for openSUSE:Factory checked in at 2012-03-29 07:44:53 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/mathomatic (Old) and /work/SRC/openSUSE:Factory/.mathomatic.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "mathomatic", Maintainer is "" Changes: -------- --- /work/SRC/openSUSE:Factory/mathomatic/mathomatic.changes 2012-03-16 13:19:02.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.mathomatic.new/mathomatic.changes 2012-03-29 07:44:54.000000000 +0200 @@ -1,0 +2,7 @@ +Sat Mar 24 20:32:36 UTC 2012 - georgegessl...@gmail.com + +- Updated to Mathomatic version 15.8.2 + This release fixes regressions and other bugs. + All changes are listed at http://mathomatic.org/NEWS + +------------------------------------------------------------------- Old: ---- mathomatic-15.8.1.tar.bz2 New: ---- mathomatic-15.8.2.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ mathomatic.spec ++++++ --- /var/tmp/diff_new_pack.9USUfN/_old 2012-03-29 07:44:55.000000000 +0200 +++ /var/tmp/diff_new_pack.9USUfN/_new 2012-03-29 07:44:55.000000000 +0200 @@ -16,7 +16,7 @@ # George Gesslein II <gessl...@mathomatic.org> Name: mathomatic -Version: 15.8.1 +Version: 15.8.2 Release: 1 Summary: Computer algebra system ++++++ mathomatic-15.8.1.tar.bz2 -> mathomatic-15.8.2.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/AUTHORS new/mathomatic-15.8.2/AUTHORS --- old/mathomatic-15.8.1/AUTHORS 2011-12-24 01:39:34.000000000 +0100 +++ new/mathomatic-15.8.2/AUTHORS 2012-03-18 17:52:32.000000000 +0100 @@ -6,11 +6,13 @@ for creating, supporting, and sponsoring the Mathomatic ports for all these years. -Thanks to all people who have contributed code to the Mathomatic project: +Thanks to all people who have contributed code and time to the Mathomatic +project: 2010 Simon Geard for better and more readable code command code. :-) 2010 Michael Pogue of Sun Microsystems for help on compiling under Solaris. 2010 Jonathan Stark for the original cmake file "CMakeLists.txt". 2011 Doug Snead for the MinGW color mode code for cmd.exe and command.com. + 2012 Doug Snead creates and sells a fancy Android version with a GUI. Thanks to all the wonderful people that have been testing, contributing, and donating to the Mathomatic project and encouraging me on; many are not listed diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/NEWS new/mathomatic-15.8.2/NEWS --- old/mathomatic-15.8.1/NEWS 2012-03-09 18:29:08.000000000 +0100 +++ new/mathomatic-15.8.2/NEWS 2012-03-24 21:01:44.000000000 +0100 @@ -1,6 +1,27 @@ +CHANGES MADE TO MATHOMATIC 15.8.1 TO BRING IT UP TO THE NEXT VERSION: + +Change of 12/18/11 partially undone. Preventing power collecting +of absolute values doesn't seem necessary anymore, some other +change done recently must have fixed it. +Now power collecting is always done when requested, +fixing a substantial simplification regression that began on 12/18/11. + +03/13/12 - Small fix to main makefile. "mandir" and "docdir" no longer depend + on "datadir". + +03/14/12 - Small fix to simplification. Any absolute value (such as + |x*y| = ((x*y)^2)^.5) is now not ever power expanded + (to (x^2)^.5*(y^2)^.5 or (x*x*y*y)^.5), so some results are + simpler, like simplifying |x^2-x|. + +03/23/12 - A change to the matho script makes GNU m4 no longer quiet + about any warnings or errors, when running m4 Mathomatic. + +Mathomatic version 15.8.2 released Saturday 03/24/12. + CHANGES MADE TO MATHOMATIC 15.8.0 TO BRING IT UP TO THE NEXT VERSION: Added some important missing documentation, and the makefiles were fixed. @@ -1309,7 +1330,7 @@ ---------------------------------------------------------------------- End of this version history of the Mathomatic computer algebra system. -Current as of 03/09/12 (2012-03-09). +Current as of 03/24/12 (2012-03-24). The latest changes are at the beginning of this file. This file is available at http://mathomatic.org/NEWS Written and maintained by George Gesslein II. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/README.txt new/mathomatic-15.8.2/README.txt --- old/mathomatic-15.8.1/README.txt 2012-03-02 20:24:04.000000000 +0100 +++ new/mathomatic-15.8.2/README.txt 2012-03-23 16:40:48.000000000 +0100 @@ -16,10 +16,10 @@ Mathomatic is a free, portable, general-purpose Computer Algebra System (CAS) and calculator software that can symbolically solve, simplify, combine, and -compare algebraic equations, simultaneously performing standard, complex -number, modular, and polynomial arithmetic, as needed. It does some calculus -and is very easy to compile/install, learn, and use. Plotting expressions -with gnuplot is also supported. +compare algebraic equations, simultaneously performing generalized standard, +complex number, modular, and polynomial arithmetic, as needed. It does some +calculus and is very easy to compile/install, learn, and use. Plotting +expressions with gnuplot is also supported. Licenses diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/VERSION new/mathomatic-15.8.2/VERSION --- old/mathomatic-15.8.1/VERSION 2012-03-09 18:19:10.000000000 +0100 +++ new/mathomatic-15.8.2/VERSION 2012-03-24 21:01:16.000000000 +0100 @@ -1 +1 @@ -15.8.1 +15.8.2 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/changes.txt new/mathomatic-15.8.2/changes.txt --- old/mathomatic-15.8.1/changes.txt 2012-03-09 18:19:12.000000000 +0100 +++ new/mathomatic-15.8.2/changes.txt 2012-03-24 21:01:22.000000000 +0100 @@ -1314,3 +1314,24 @@ on any version of Mathomatic without the new bug fix. Mathomatic version 15.8.1 released Friday 03/09/12. + +CHANGES MADE TO MATHOMATIC 15.8.1 TO BRING IT UP TO THE NEXT VERSION: + +Change of 12/18/11 partially undone. Preventing power collecting +of absolute values doesn't seem necessary anymore, some other +change done recently must have fixed it. +Now power collecting is always done when requested, +fixing a substantial simplification regression that began on 12/18/11. + +03/13/12 - Small fix to main makefile. "mandir" and "docdir" no longer depend + on "datadir". + +03/14/12 - Small fix to simplification. Any absolute value (such as + |x*y| = ((x*y)^2)^.5) is now not ever power expanded + (to (x^2)^.5*(y^2)^.5 or (x*x*y*y)^.5), so some results are + simpler, like simplifying |x^2-x|. + +03/23/12 - A change to the matho script makes GNU m4 no longer quiet + about any warnings or errors, when running m4 Mathomatic. + +Mathomatic version 15.8.2 released Saturday 03/24/12. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/compile.mingw new/mathomatic-15.8.2/compile.mingw --- old/mathomatic-15.8.1/compile.mingw 2011-10-04 13:34:56.000000000 +0200 +++ new/mathomatic-15.8.2/compile.mingw 2012-03-11 16:34:02.000000000 +0100 @@ -9,23 +9,24 @@ # Abort on any errors: set -e -set -u -# Define the C cross-compiler we are using here: + +# Define the C cross-compiler and flags we are using here: export CC=i586-mingw32msvc-cc +export CFLAGS="-O3 -Wall -Wno-unused-variable -DMINGW -DWIN32_CONSOLE_COLORS -DBOLD_COLOR $CFLAGS" echo Compiling Windows 32-bit Mathomatic... make clean cd icons i586-mingw32msvc-windres icon.rc icon.o cd .. -AOUT=mathomatic.exe CFLAGS="-O3 -Wall -Wno-unused-variable -DMINGW -DWIN32_CONSOLE_COLORS -DBOLD_COLOR" MATHOMATIC_OBJECTS="icons/icon.o" make -j +AOUT=mathomatic.exe MATHOMATIC_OBJECTS="icons/icon.o" make -j make clean echo echo Compiling the Prime Number Tools... cd primes make flush -CFLAGS="-DUSE_DOUBLES -DMINGW -O3 -Wall" make -j +CFLAGS="-DUSE_DOUBLES $CFLAGS" make -j make clean echo echo Prime Number Tools executables will need .exe appended to the filename. @@ -40,5 +41,5 @@ cd icons amd64-mingw32msvc-windres icon.rc icon.o cd .. -AOUT=mathomatic64.exe CFLAGS="-O3 -Wall -Wno-unused-variable -DMINGW -DWIN32_CONSOLE_COLORS -DBOLD_COLOR" MATHOMATIC_OBJECTS="icons/icon.o" make -j +AOUT=mathomatic64.exe MATHOMATIC_OBJECTS="icons/icon.o" make -j make clean diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/doc/am.html new/mathomatic-15.8.2/doc/am.html --- old/mathomatic-15.8.1/doc/am.html 2012-02-26 04:54:34.000000000 +0100 +++ new/mathomatic-15.8.2/doc/am.html 2012-03-24 01:34:18.000000000 +0100 @@ -2088,7 +2088,8 @@ meaning that all of the solutions are correct. Otherwise "Solution may be incorrect" is displayed, meaning at least one of the solutions is incorrect or unverifiable. -The "verify" option only works when solving for a single variable. +The "verify" option only works when solving for a single variable, +and indicates if the solve result can be trusted. <p> The "<b>for</b>" option has no additional effect and is to make entering this solve command more natural. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/doc/quickrefcard.html new/mathomatic-15.8.2/doc/quickrefcard.html --- old/mathomatic-15.8.1/doc/quickrefcard.html 2012-03-07 22:52:06.000000000 +0100 +++ new/mathomatic-15.8.2/doc/quickrefcard.html 2012-03-24 01:39:26.000000000 +0100 @@ -5,7 +5,7 @@ </head> <body> <table cellpadding="4" border="3" summary="Mathomatic Quick Reference Card"> -<tr bgcolor="#2648fe"><th colspan="3"><font color="white">Mathomatic version 15.8.0 Quick Reference Card</font></th></tr> +<tr bgcolor="#2648fe"><th colspan="3"><font color="white">Mathomatic version 15.8.1 Quick Reference Card</font></th></tr> <tr> <th>Command</th> <th>Usage</th> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/factor.c new/mathomatic-15.8.2/factor.c --- old/mathomatic-15.8.1/factor.c 2012-01-05 01:28:36.000000000 +0100 +++ new/mathomatic-15.8.2/factor.c 2012-03-23 14:41:44.000000000 +0100 @@ -24,6 +24,8 @@ #include "includes.h" +#define ALWAYS_FACTOR_POWER 1 + static int fplus_recurse(token_type *equation, int *np, int loc, int level, long v, double d, int whole_flag, int div_only); static int fplus_sub(token_type *equation, int *np, int loc, int i1, int n1, int i2, int n2, int level, long v, double d, int whole_flag, int div_only); static int big_fplus(token_type *equation, int level, int diff_sign, int sop1, int op1, int op2, int i1, int i2, int b1, int b2, int ai, int aj, int i, int j, int e1, int e2); @@ -976,6 +978,9 @@ int len; int diff_sign; int all_divide; +#if !ALWAYS_FACTOR_POWER + int abs1_flag = false, abs2_flag = false; +#endif e1 = i1 + n1; e2 = i2 + n2; @@ -989,12 +994,22 @@ if (i >= e1) return false; if (equation[i].level == level && equation[i].token.operatr == POWER) { -#if 1 +#if !ALWAYS_FACTOR_POWER /* avoid absolute values: */ - if (i > (i1 + 2) && equation[i+1].level == level && equation[i-1].level == (level + 1) - && equation[i+1].kind == CONSTANT && equation[i-1].kind == CONSTANT + if (i > (i1 + 2) + && ((equation[i+1].level == level && (i + 2) == e1) + || (equation[i+1].level == (level + 1) + && (i + 4) == e1 + && equation[i+2].level == (level + 1) + && equation[i+2].token.operatr == DIVIDE + && equation[i+3].level == (level + 1) + && equation[i+3].kind == CONSTANT)) + && equation[i-1].level == (level + 1) + && equation[i+1].kind == CONSTANT + && equation[i-1].kind == CONSTANT && equation[i-2].level == (level + 1) && equation[i-2].token.operatr == POWER) { - return false; + abs1_flag = true; +/* return false; */ } #endif break; @@ -1004,17 +1019,31 @@ if (j >= e2) return false; if (equation[j].level == level && equation[j].token.operatr == POWER) { -#if 1 +#if !ALWAYS_FACTOR_POWER /* avoid absolute values: */ - if (j > (i2 + 2) && equation[j+1].level == level && equation[j-1].level == (level + 1) - && equation[j+1].kind == CONSTANT && equation[j-1].kind == CONSTANT + if (j > (i2 + 2) + && ((equation[j+1].level == level && (j + 2) == e2) + || (equation[j+1].level == (level + 1) + && (j + 4) == e2 + && equation[j+2].level == (level + 1) + && equation[j+2].token.operatr == DIVIDE + && equation[j+3].level == (level + 1) + && equation[j+3].kind == CONSTANT)) + && equation[j-1].level == (level + 1) + && equation[j+1].kind == CONSTANT + && equation[j-1].kind == CONSTANT && equation[j-2].level == (level + 1) && equation[j-2].token.operatr == POWER) { - return false; + abs2_flag = true; +/* return false; */ } #endif break; } } +#if !ALWAYS_FACTOR_POWER + if (abs1_flag && abs2_flag) + return false; +#endif start2 = j; #if 1 if (se_compare(&equation[i+1], e1 - (i + 1), &one_token, 1, &diff_sign)) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/help.c new/mathomatic-15.8.2/help.c --- old/mathomatic-15.8.1/help.c 2012-03-07 20:44:32.000000000 +0100 +++ new/mathomatic-15.8.2/help.c 2012-03-11 23:44:40.000000000 +0100 @@ -351,12 +351,18 @@ process(cp) char *cp; { + int rv; + if (cp && cp[0] == ':') { input_column++; process_rv(cp + 1); return true; } else { - return process_rv(cp); + rv = process_rv(cp); + if (!rv) { + debug_string(1, "Error return."); + } + return rv; } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/list.c new/mathomatic-15.8.2/list.c --- old/mathomatic-15.8.1/list.c 2012-02-14 04:16:14.000000000 +0100 +++ new/mathomatic-15.8.2/list.c 2012-03-24 01:23:52.000000000 +0100 @@ -795,20 +795,20 @@ * Return string, or NULL if error. */ char * -string_code_equation(n, language, int_flag) -int n; /* equation space number */ +string_code_equation(en, language, int_flag) +int en; /* equation space number */ enum language_list language; int int_flag; /* integer arithmetic flag */ { int len; char *cp; - if (empty_equation_space(n)) + if (empty_equation_space(en)) return NULL; - len = list_code(lhs[n], &n_lhs[n], false, NULL, language, int_flag); - if (n_rhs[n]) { + len = list_code(lhs[en], &n_lhs[en], false, NULL, language, int_flag); + if (n_rhs[en]) { len += strlen(EQUATE_STRING); - len += list_code(rhs[n], &n_rhs[n], false, NULL, language, int_flag); + len += list_code(rhs[en], &n_rhs[en], false, NULL, language, int_flag); } len += 2; /* for possible semicolon and terminating null character */ cp = (char *) malloc(len); @@ -816,10 +816,10 @@ error(_("Out of memory (can't malloc(3)).")); return NULL; } - list_code(lhs[n], &n_lhs[n], false, cp, language, int_flag); - if (n_rhs[n]) { + list_code(lhs[en], &n_lhs[en], false, cp, language, int_flag); + if (n_rhs[en]) { strcat(cp, EQUATE_STRING); - list_code(rhs[n], &n_rhs[n], false, &cp[strlen(cp)], language, int_flag); + list_code(rhs[en], &n_rhs[en], false, &cp[strlen(cp)], language, int_flag); } switch (language) { case C: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/m4/matho new/mathomatic-15.8.2/m4/matho --- old/mathomatic-15.8.1/m4/matho 2011-04-26 23:45:20.000000000 +0200 +++ new/mathomatic-15.8.2/m4/matho 2012-03-23 14:49:48.000000000 +0100 @@ -20,7 +20,7 @@ if [ -x "$MATHOMATIC" ] then - m4 -eP -- "$MFUNCTIONS" "$@" - 2>/dev/null | "$MATHOMATIC" $MOPTIONS + m4 -eP -- "$MFUNCTIONS" "$@" - | "$MATHOMATIC" $MOPTIONS else - m4 -eP -- "$MFUNCTIONS" "$@" - 2>/dev/null | mathomatic $MOPTIONS + m4 -eP -- "$MFUNCTIONS" "$@" - | mathomatic $MOPTIONS fi diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/makefile new/mathomatic-15.8.2/makefile --- old/mathomatic-15.8.1/makefile 2012-03-09 18:26:52.000000000 +0100 +++ new/mathomatic-15.8.2/makefile 2012-03-23 14:51:30.000000000 +0100 @@ -68,8 +68,8 @@ prefix ?= /usr/local bindir ?= $(prefix)/bin datadir ?= $(prefix)/share -mandir ?= $(datadir)/man -docdir ?= $(datadir)/doc +mandir ?= $(prefix)/share/man +docdir ?= $(prefix)/share/doc mathdocdir ?= $(docdir)/mathomatic mathdatadir ?= $(datadir)/mathomatic @@ -172,7 +172,7 @@ # "make pdfman" creates a PDF of all the Mathomatic Man pages, if desired. # Requires the very latest version of the txt2man package. bookman pdfman $(PDFMAN): $(MAN1) primes/*.1 lib/*.3 - bookman -p -t "Mathomatic Man Pages" -a "George Gesslein II" -d `date +%F` $+ >$(PDFMAN) </dev/null + bookman -p -t "Mathomatic version $(VERSION) Man Pages" -a "George Gesslein II" -d `date +%F` $+ >$(PDFMAN) </dev/null @echo PDF man pages book created in $(PDFMAN) # Here we convert the man pages to HTML docs with rman: @@ -214,7 +214,7 @@ echo ' exit 1' >>$(M4SCRIPTPATH) echo 'fi' >>$(M4SCRIPTPATH) echo >>$(M4SCRIPTPATH) - echo '$(M4) -eP -- $(mathdatadir)/m4/functions.m4 "$$@" - 2>/dev/null | mathomatic -ru -s-1' >>$(M4SCRIPTPATH) + echo '$(M4) -eP -- $(mathdatadir)/m4/functions.m4 "$$@" - | mathomatic -ru -s-1' >>$(M4SCRIPTPATH) chmod 0755 $(M4SCRIPTPATH) $(INSTALL_PROGRAM) m4/rmath $(DESTDIR)$(bindir) $(INSTALL_DATA) rmath.1 $(DESTDIR)$(mandir)/man1 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/misc/known_bugs.txt new/mathomatic-15.8.2/misc/known_bugs.txt --- old/mathomatic-15.8.1/misc/known_bugs.txt 2012-03-06 22:28:54.000000000 +0100 +++ new/mathomatic-15.8.2/misc/known_bugs.txt 2012-03-24 01:29:24.000000000 +0100 @@ -25,5 +25,5 @@ Solving modulus equations: May result in garbage, due to incomplete modulus operator solving code. I could just disable it, but I choose to research it at a later time, because -it does sometimes work nicely. Again, the "solve verify" option tells the -truth. +it does sometimes work nicely. Again, the "solve verify" option tells if you +should trust the results. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/proto.h new/mathomatic-15.8.2/proto.h --- old/mathomatic-15.8.1/proto.h 2012-03-04 14:48:24.000000000 +0100 +++ new/mathomatic-15.8.2/proto.h 2012-03-24 21:01:28.000000000 +0100 @@ -189,7 +189,7 @@ int list_string_sub(token_type *p1, int n, int outflag, char *string, int export_flag); int int_expr(token_type *p1, int n); int list_code_equation(int en, enum language_list language, int int_flag); -char *string_code_equation(int n, enum language_list language, int int_flag); +char *string_code_equation(int en, enum language_list language, int int_flag); int list_code(token_type *equation, int *np, int outflag, char *string, enum language_list language, int int_flag); char *flist_equation_string(int n); int flist_equation(int n); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/tests/all.out new/mathomatic-15.8.2/tests/all.out --- old/mathomatic-15.8.1/tests/all.out 2012-02-28 00:22:08.000000000 +0100 +++ new/mathomatic-15.8.2/tests/all.out 2012-03-24 02:18:44.000000000 +0100 @@ -1804,13 +1804,13 @@ 1-> simplify - 10*pi^2*r^3 1 - 4*((------------- - d^2)^-) - (g*m*epsilon) 2 -#1: y = 0.6666 - --------------------------- - 1 - (15*((d^2)^-)) - 2 + pi + 10*(--^2)*r^3 + d 1 + 4*((------------- - 1)^-) + (g*m*epsilon) 2 +#1: y = 0.6666 - ------------------------- + 15 1-> simplify symbolic @@ -2063,11 +2063,11 @@ 6-> simplify - 1 1 - ((((mass1^2)^-)*(((velocity1_old - velocity2_old)^2)^-)*sign0) + (mass1*velocity1_old) + (mass2*velocity2_old)) - 2 2 -#6: velocity2_new = --------------------------------------------------------------------------------------------------------------- - (mass1 + mass2) + 1 + (((((mass1*(velocity1_old - velocity2_old))^2)^-)*sign0) + (mass1*velocity1_old) + (mass2*velocity2_old)) + 2 +#6: velocity2_new = --------------------------------------------------------------------------------------------------------- + (mass1 + mass2) 6-> velocity2_new = ((sign*((mass1*(velocity1_old-velocity2_old))^2)^.5)+(mass1*velocity1_old)+(mass2*velocity2_old))/(mass1+mass2) @@ -2079,7 +2079,6 @@ 7-> compare 6 Comparing #6 with #7... -Completely simplifying both equations... Equations are identical. Successfully finished reading file "test6.in". 7-> clear all @@ -2414,8 +2413,30 @@ (((2*((a^2*(b^2 + c^2)) + ((b*c)^2))) - a^4 - b^4 - c^4)^-) 2 +3-> #s ; Search backwards for the s variable; "/" searches forwards. + + (a + b + c) +#1: s = ----------- + 2 + +1-> clear ; No longer needed. +1-> display all + + 8*((b^2*c) + (b*c^2)) 1 + (((b*((2*a) - (6*c))) + (2*a*c) - a^2 + --------------------- - b^2 - c^2)^-) + (a + b + c) 2 +#2: inradius = ----------------------------------------------------------------------------- + 2 + + + a*b*c +#3: radius = ----------------------------------------------------------- + 1 + (((2*((a^2*(b^2 + c^2)) + ((b*c)^2))) - a^4 - b^4 - c^4)^-) + 2 + Successfully finished reading file "radius.in". -3-> clear all +1-> clear all 1-> read pyth3d 1-> 1-> ; This arrives at the distance between two points in 3D space from the @@ -2489,14 +2510,11 @@ 2-> simplify ; The beautiful answer is: - 1 - ((((a*x0) + c + (b*y0))^2)^-) - 2 -#2: distance = ----------------------------- - 1 - ((a^2 + b^2)^-) - 2 + (((a*x0) + c + (b*y0))^2) 1 +#2: distance = -------------------------^- + (a^2 + b^2) 2 +2-> ; Replacing a with -m, b with 1, and c with -b results in the shortest distance from the line y=m*x+b. Successfully finished reading file "distance.in". 2-> clear all 1-> read circles @@ -2536,11 +2554,11 @@ 2-> repeat simplify - 1 4*r^2 1 - (y2 + y1 + ((((x1 - x2)^2)^-)*((----------------------------------------------------- - 1)^-)*sign0)) - 2 (y2^2 - (2*((y2*y1) + (x1*x2))) + x1^2 + y1^2 + x2^2) 2 -#2: y = ----------------------------------------------------------------------------------------------------- - 2 + 4*r^2 1 + (y2 + y1 + (((((x1 - x2)^2)*(----------------------------------------------------- - 1))^-)*sign0)) + (y2^2 - (2*((y2*y1) + (x2*x1))) + x2^2 + y1^2 + x1^2) 2 +#2: y = --------------------------------------------------------------------------------------------------- + 2 Successfully finished reading file "circles.in". 2-> clear all @@ -2602,13 +2620,9 @@ 2 (y1^2 - (2*y1*y2) - k^2 + y2^2) - 1 - ((radius1^2 - x^2)^-)*sign0*radius2 - 2 -#2: y = ----------------------------------- - 1 - ((radius1^2)^-) - 2 + x 1 +#2: y = ((1 - (-------^2))^-)*sign0*radius2 + radius1 2 2-> quit ByeBye!! from Mathomatic. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/tests/distance.in new/mathomatic-15.8.2/tests/distance.in --- old/mathomatic-15.8.1/tests/distance.in 2011-11-13 18:40:48.000000000 +0100 +++ new/mathomatic-15.8.2/tests/distance.in 2012-03-24 02:17:06.000000000 +0100 @@ -9,3 +9,4 @@ distance=|a*(x-x0)+b*(y-y0)|/(a^2+b^2)^.5 eliminate y ; Combine the above two equations to eliminate x and y. simplify ; The beautiful answer is: +; Replacing a with -m, b with 1, and c with -b results in the shortest distance from the line y=m*x+b. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/tests/quartic.in new/mathomatic-15.8.2/tests/quartic.in --- old/mathomatic-15.8.1/tests/quartic.in 2011-11-13 18:39:52.000000000 +0100 +++ new/mathomatic-15.8.2/tests/quartic.in 2012-03-18 00:17:40.000000000 +0100 @@ -12,3 +12,4 @@ x = ((-a)/4 + sign * 1/2(((a^2)/4 - (2b)/3 + (2^(1/3)(b^2 - 3a*c + 12d))/(3((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d + ((-4((b^2 - 3a*c + 12d))^3 + ((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d))^2)^.5)))^(1/3)) + (((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d + ((-4 ((b^2 - 3a*c + 12d))^3 + ((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d))^2)^.5)))/54)^(1/3))^.5) + sign1 * 1/2(((a^2)/2 - (4b)/3 - (2^(1/3)(b^2 - 3a*c + 12d))/(3((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d + ((-4((b^2 - 3a*c + 12d))^3 + ((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d))^2)^.5)))^(1/3)) - (((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d + ((-4 ((b^2 - 3a*c + 12d))^3 + ((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d))^2)^.5)))/54)^(1/3) + sign (-a^3 + 4a*b - 8c)/(4(((a^2)/4 - (2b)/3 + (2^(1/3) (b^2 - 3a*c + 12d))/(3 ((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d + ((-4 ((b^2 - 3a*c + 12d))^3 + ((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d))^2)^.5)))^(1/3)) + (((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d + ((-4 ((b^2 - 3a*c + 12d))^3 + ((2b^3 - 9a*b*c + 27c^2 + 27a^2d - 72b*d))^2)^.5)))/54)^(1/3))^.5)))^.5)) ; Use the calculate command to temporarily plug in coefficients. +; Use "repeat simplify quick" to simplify this, plain old simplify does a terrible job. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/tests/radius.in new/mathomatic-15.8.2/tests/radius.in --- old/mathomatic-15.8.1/tests/radius.in 2011-11-13 18:44:28.000000000 +0100 +++ new/mathomatic-15.8.2/tests/radius.in 2012-03-18 00:40:52.000000000 +0100 @@ -15,3 +15,6 @@ radius=a*b*c/(4*(s*(s-a)*(s-b)*(s-c))^.5) eliminate s simplify +#s ; Search backwards for the s variable; "/" searches forwards. +clear ; No longer needed. +display all diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mathomatic-15.8.1/unfactor.c new/mathomatic-15.8.2/unfactor.c --- old/mathomatic-15.8.1/unfactor.c 2012-01-01 14:40:46.000000000 +0100 +++ new/mathomatic-15.8.2/unfactor.c 2012-03-23 16:27:02.000000000 +0100 @@ -370,6 +370,18 @@ } break; case POWER: +#if !ALWAYS_UNFACTOR_POWER +/* avoid absolute values: */ + if ((loc + 3) < *np && equation[loc+1].level == level && equation[loc+1].kind == CONSTANT + && equation[loc+2].level == (level - 1) && equation[loc+2].token.operatr == POWER + && equation[loc+3].kind == CONSTANT && ((equation[loc+3].level == (level - 1)) + || ((loc + 5) < *np && equation[loc+3].level == level + && equation[loc+4].level == level && equation[loc+4].token.operatr == DIVIDE + && equation[loc+5].level == level && equation[loc+5].kind == CONSTANT + && ((loc + 6) >= *np || equation[loc+6].level < level)))) { + return false; + } +#endif if (ii == 2 || ii == 0) { for (i = b1 + 1; i < loc; i += 2) { if (equation[i].level != level + 1) -- To unsubscribe, e-mail: opensuse-commit+unsubscr...@opensuse.org For additional commands, e-mail: opensuse-commit+h...@opensuse.org