close Warning: Can't synchronize with repository "(default)" (/var/svn/tolp does not appear to be a Subversion repository.). Look in the Trac log for more information.

Opened 21 years ago

Closed 21 years ago

Last modified 18 years ago

#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 danirus

Severity: trivialenhancement
Status: newassigned

comment:2 Changed 21 years ago by danirus

Resolution: fixed
Status: assignedclosed

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}

comment:3 Changed 18 years ago by Víctor de Buen Remiro

bug_file_loc: http://tol.bayesforecast.com/modules.php?op=modload&name=phpBB2&file=viewtopic&t=114http://www.tol-project.org
Note: See TracTickets for help on using tickets.