应用截图


详细介绍
Calculate values of mathematical expressions
# calc-extension
(C) Martin Väth
This project is under the GNU Public License 2.0.
A WebExtension: Calculate values of mathematical expressions
The extension strives to be useful for everybody quickly needing
brief or mid-long calculations: in daily “browser” life, as a
mathematician, or as a programmer - there is support for all needs.
Formulas can be entered in the typical mathematician's or
programmer's syntax - both is understood.
There is also support for lengthy sessions
(saving/restoring, exporting to clipboard, etc).
The original motivation was to experiment with a Pratt parser.
There is already a much richer expression syntax than in most languages
(implicit multiplication signs, no braces necessary for function calls),
and it would be simple to extend the syntax to a more full-blown “language”.
(In fact, earlier versions of __calc-extension__ had a simpler syntax.
Readers interested in the parser implementation can check `data/js/parser.js`).
After installing __calc-extension__, it can be used as follows.
Click the __calc-extension__ symbol `1+2` or the link on the options page.
Then a page opens where you can enter a formula (see below) which will be
calculated when you press the solver button (`~>`).
(There is an option to use the enter key instead if you prefer.)
The result is then shown and you can enter the next formula.
You can also go back to an earlier entered formula and “recalculate” it
(e.g. after you modified some variables).
To remove a formula from your list, simply remove the main formula text
and press the solver button.
A simple formula is a usual mathematical expression which consists of numbers,
the usual operators `+` `-` `*` `/` and braces `(` `)`.
As usual in mathematics (though not in most computer languages),
it is possible to omit the multiplication sign `*`.
However:
__Be aware that `x` means the variable x and not a multiplication sign__!
For
# calc-extension
(C) Martin Väth
This project is under the GNU Public License 2.0.
A WebExtension: Calculate values of mathematical expressions
The extension strives to be useful for everybody quickly needing
brief or mid-long calculations: in daily “browser” life, as a
mathematician, or as a programmer - there is support for all needs.
Formulas can be entered in the typical mathematician's or
programmer's syntax - both is understood.
There is also support for lengthy sessions
(saving/restoring, exporting to clipboard, etc).
The original motivation was to experiment with a Pratt parser.
There is already a much richer expression syntax than in most languages
(implicit multiplication signs, no braces necessary for function calls),
and it would be simple to extend the syntax to a more full-blown “language”.
(In fact, earlier versions of __calc-extension__ had a simpler syntax.
Readers interested in the parser implementation can check `data/js/parser.js`).
After installing __calc-extension__, it can be used as follows.
Click the __calc-extension__ symbol `1+2` or the link on the options page.
Then a page opens where you can enter a formula (see below) which will be
calculated when you press the solver button (`~>`).
(There is an option to use the enter key instead if you prefer.)
The result is then shown and you can enter the next formula.
You can also go back to an earlier entered formula and “recalculate” it
(e.g. after you modified some variables).
To remove a formula from your list, simply remove the main formula text
and press the solver button.
A simple formula is a usual mathematical expression which consists of numbers,
the usual operators `+` `-` `*` `/` and braces `(` `)`.
As usual in mathematics (though not in most computer languages),
it is possible to omit the multiplication sign `*`.
However:
__Be aware that `x` means the variable x and not a multiplication sign__!
For