#20 closed enhancement (fixed)
logical, relational and arithmetic functions behaviour.
Reported by: | manuelb | Owned by: | danirus |
---|---|---|---|
Priority: | lowest | Milestone: | |
Component: | Math | Version: | head |
Severity: | minor | Keywords: | |
Cc: |
Description
(From the old tol forums)
All logic, bitwise, relational and arithmetic functions, like sum(+), AND(&),
etc. are shown as normal procedures/functions, eventhough their use is much
more alike.
See this example:
- Function: Real Sum(Real x1 [, Real x2, ...])
- Use: Real Sum(4, 5, 1) {= 10}
- Function: Real +(Real x1, Real x2)
- Use: Real +(4, 5, 1) {= ERROR}
- Correct use: Real 4+5+1 {= 10}
I think it would be more clarifying to describe the functions as they are
used. In fact, the original doubt I had was about the logic operators '&', '|'
and '!'.
- '&' is the logical operator equivalence for 'And', but has a different
logical use.
- '|' is the logical operator equivalence for 'Or', but has a different
logical use.
- '!' is the logical operator equivalence for 'Not(And())', but has a similar
behaviour.
By the way: The operator '!' does not come in the Real functions list.
Regards.
Change History (3)
comment:1 Changed 21 years ago by
Severity: | trivial → enhancement |
---|---|
Status: | new → assigned |
comment:2 Changed 21 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
comment:3 Changed 18 years ago by
bug_file_loc: | http://tol.bayesforecast.com/modules.php?op=modload&name=phpBB2&file=viewtopic&t=114 → http://www.tol-project.org |
---|
This bug has been resolved.
If you are working with CVS, you must update your Tol and Toltcl sources.
Each Tol Type shows information for each function (also operators) with the
format they should be used. For example:
Operator Real &, before changes -> Real &(Real x1, Real x2)
Operator Real &, after changes -> x1 & x2 {Real x1, Real x2}