all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Bug in the org spreadsheet?
@ 2008-04-13  6:19 Nikos Apostolakis
  0 siblings, 0 replies; only message in thread
From: Nikos Apostolakis @ 2008-04-13  6:19 UTC (permalink / raw)
  To: emacs-orgmode

Hello group,

it seems that algebraic entries on tables are not always parsed
correctly by org mode, or is it calc's fault?  For example in the
following table the the entry @2$4 should be -a^4 - a^2 b^2


| Term | Components | vac        | Contribution                  |
|------+------------+------------+-------------------------------|
| a a  |          2 | -a^2 - b^2 | -a^4 - b^2                    |
| a b  |          1 | 1          | a b                           |
| b a  |          1 | 1          | b a                           |
| b b  |          2 | -a^2 -b^2  | -(b^2 a^2) - b^2              |
|------+------------+------------+-------------------------------|
|      |            |            | 2 a b - a^4 - a^2 b^2 - 2 b^2 |
#+TBLFM: $4=$1*$3::@6$4=simplify(expand(vsum(@-I..@-II)))

I can get the spreadsheet to do what I mean by using parentheses as 
in the following table, but IMHO it shouldn't be necessary.

| Term | Components | vac          | Contribution                  |
|------+------------+--------------+-------------------------------|
| a a  |          2 | (-a^2 - b^2) | -(a^2 (b^2 + a^2))            |
| a b  |          1 | 1            | a b                           |
| b a  |          1 | 1            | b a                           |
| b b  |          2 | (-a^2 -b^2)  | -(b^2 (b^2 + a^2))            |
|------+------------+--------------+-------------------------------|
|      |            |              | 2 a b - a^4 - b^4 - 2 a^2 b^2 |
#+TBLFM: $4=$1*$3::@6$4=simplify(expand(vsum(@-I..@-II)))

,----[ M-x version ]
| GNU Emacs 23.0.60.1 (i486-pc-linux-gnu, GTK+ Version 2.12.9) of
| 2008-04-07 on elegiac, modified by Debian
`----

,----[ M-x org-version ]
| Org-mode version 5.23a
`----


Thanks, Nikos

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-04-13  6:20 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-04-13  6:19 Bug in the org spreadsheet? Nikos Apostolakis

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.