|
From: | Matt Price |
Subject: | Re: Multiple calc commands with orgbabel |
Date: | Wed, 5 May 2021 11:11:19 -0400 |
On Wednesday, 5 May 2021 at 07:46, pietru@caramail.com wrote:
> Have been trying to execute multiple calc commands, but when I
> evaluate the calc expressions, I get just one result.
ob-calc returns the top element of the stack when finished and this will
be the result of the last operation in the src block. I don't think
there's any way around this.
I use embedded Calc for this reason. You could rewrite your equations
as simple lines (separated by empty lines from the surroundings) and
evaluate each in turn with "C-x * u":
fsolve(x 2 + x = 4, x) => x = 1.33333333333
fsolve([x + y = a, x - y = b], [x, y]) => [x = a + (b - a) / 2, y = (a - b) / 2]
I added the "=>" at the end of each _expression_ so that the result is
shown to the right instead of replacing the _expression_ itself (default
embedded Calc behaviour).
--
: Eric S Fraga via Emacs 28.0.50, Org release_9.4.5-395-g82fbdd
[Prev in Thread] | Current Thread | [Next in Thread] |