Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
2ccc02f2
Commit
2ccc02f2
authored
Sep 07, 2005
by
Jay Belanger
Browse files
(math-expand-term): Multiply out the powers when in matrix mode.
parent
104fc809
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
9 deletions
+41
-9
lisp/ChangeLog
lisp/ChangeLog
+5
-0
lisp/calc/calc-poly.el
lisp/calc/calc-poly.el
+36
-9
No files found.
lisp/ChangeLog
View file @
2ccc02f2
2005-09-07 Jay Belanger <belanger@truman.edu>
* calc/calc-poly.el (math-expand-term): Multiply out any powers
when in matrix mode.
2005-09-08 Chong Yidong <cyd@stupidchicken.com>
* buff-menu.el (Buffer-menu-sort-by-column): New function.
...
...
lisp/calc/calc-poly.el
View file @
2ccc02f2
...
...
@@ -1069,18 +1069,45 @@
(
math-add-or-sub
(
list
'/
(
nth
1
(
nth
1
expr
))
(
nth
2
expr
))
(
list
'/
(
nth
2
(
nth
1
expr
))
(
nth
2
expr
))
nil
(
eq
(
car
(
nth
1
expr
))
'-
)))
((
and
(
eq
calc-matrix-mode
'matrix
)
(
eq
(
car-safe
expr
)
'^
)
(
natnump
(
nth
2
expr
))
(
>
(
nth
2
expr
)
1
)
(
memq
(
car-safe
(
nth
1
expr
))
'
(
+
-
)))
(
if
(
=
(
nth
2
expr
)
2
)
(
math-add-or-sub
(
list
'*
(
nth
1
(
nth
1
expr
))
(
nth
1
expr
))
(
list
'*
(
nth
2
(
nth
1
expr
))
(
nth
1
expr
))
nil
(
eq
(
car
(
nth
1
expr
))
'-
))
(
math-add-or-sub
(
list
'*
(
nth
1
(
nth
1
expr
))
(
list
'^
(
nth
1
expr
)
(
1-
(
nth
2
expr
))))
(
list
'*
(
nth
2
(
nth
1
expr
))
(
list
'^
(
nth
1
expr
)
(
1-
(
nth
2
expr
))))
nil
(
eq
(
car
(
nth
1
expr
))
'-
))))
((
and
(
eq
(
car-safe
expr
)
'^
)
(
memq
(
car-safe
(
nth
1
expr
))
'
(
+
-
))
(
integerp
(
nth
2
expr
))
(
if
(
>
(
nth
2
expr
)
0
)
(
or
(
and
(
or
(
>
math-mt-many
500000
)
(
<
math-mt-many
-500000
))
(
math-expand-power
(
nth
1
expr
)
(
nth
2
expr
)
nil
t
))
(
list
'*
(
nth
1
expr
)
(
list
'^
(
nth
1
expr
)
(
1-
(
nth
2
expr
)))))
(
if
(
<
(
nth
2
expr
)
0
)
(
list
'/
1
(
list
'^
(
nth
1
expr
)
(
-
(
nth
2
expr
))))))))
(
if
(
and
(
eq
calc-matrix-mode
'matrix
)
(
>
(
nth
2
expr
)
1
))
(
if
(
=
(
nth
2
expr
)
2
)
(
math-add-or-sub
(
list
'*
(
nth
1
(
nth
1
expr
))
(
nth
1
expr
))
(
list
'*
(
nth
2
(
nth
1
expr
))
(
nth
1
expr
))
nil
(
eq
(
car
(
nth
1
expr
))
'-
))
(
math-add-or-sub
(
list
'*
(
nth
1
(
nth
1
expr
))
(
list
'^
(
nth
1
expr
)
(
1-
(
nth
2
expr
))))
(
list
'*
(
nth
2
(
nth
1
expr
))
(
list
'^
(
nth
1
expr
)
(
1-
(
nth
2
expr
))))
nil
(
eq
(
car
(
nth
1
expr
))
'-
)))
(
if
(
>
(
nth
2
expr
)
0
)
(
or
(
and
(
or
(
>
math-mt-many
500000
)
(
<
math-mt-many
-500000
))
(
math-expand-power
(
nth
1
expr
)
(
nth
2
expr
)
nil
t
))
(
list
'*
(
nth
1
expr
)
(
list
'^
(
nth
1
expr
)
(
1-
(
nth
2
expr
)))))
(
if
(
<
(
nth
2
expr
)
0
)
(
list
'/
1
(
list
'^
(
nth
1
expr
)
(
-
(
nth
2
expr
)))))))))
(
t
expr
)))
(
defun
calcFunc-expand
(
expr
&optional
many
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment