Parenthesization bug

Roberto Bagnara bagnara at cs.unipr.it
Fri Jan 25 14:40:13 CET 2002


Dear all,

there is a bug somewhere in GiNaC whereby some non-redundant parentheses
are not output.  The problem is shown below by means of simple `ginsh'
session, but it can be reproduced equally well with C++ code.

$ ginsh
ginsh - GiNaC Interactive Shell (GiNaC V1.0.4)
  __,  _______  Copyright (C) 1999-2002 Johannes Gutenberg University Mainz,
 (__) *       | Germany.  This is free software with ABSOLUTELY NO WARRANTY.
  ._) i N a C | You are welcome to redistribute it under certain conditions.
<-------------' For details type `warranty;'.

Type ?? for a list of help topics.
> 2*I^(1/3);
2*I^(1/3)
> (2*I)^(1/3);
2*I^(1/3)
> 2*(I^(1/3));
2*I^(1/3)
> 

If this is confirmed to be a bug, we would need to develop a fix or
a workaround quite urgently.
Thanks a lot

       Roberto

-- 
Prof. Roberto Bagnara
Computer Science Group
Department of Mathematics, University of Parma, Italy
http://www.cs.unipr.it/~bagnara/
mailto:bagnara at cs.unipr.it



More information about the GiNaC-devel mailing list