simplif10Expr(2)

ORIGIN
Cao-vlsi libraries, log package, libablmmm.a

NAME
simplif10Expr - makes simplifications on an expression including constant atomic expressions

SYNOPSIS
#include "logmmm.h"
chain_list *simplif10Expr(expr)
chain_list *expr;

PARAMETER

expr
    expression to simplify

DESCRIPTION
simplif10Expr() makes simplifications by applying the following rules :

(or 0 x1 x2 ... xn) --> (or x1 x2 ... xn)  if n>1

(or 1 x1 x2 ... xn) --> 1

(or 0 x1) --> x1

(and 0 x1 x2 ... xn) --> 0

(and 1 x1 x2 ... xn) --> (and x1 x2 ... xn)  if n>1

(and 1 x1) --> x1

(nor 0 x1 x2 ... xn) --> (nor x1 x2 ... xn)  if n>1

(nor 1 x1 x2 ... xn) --> 0

(nor 0 x1) --> (not x1)

(nand 0 x1 x2 ... xn) --> 1

(nand 1 x1 x2 ... xn) --> (nand x1 x2 ... xn)  if n>1

(nand 1 x1) --> (not x1)

(xor 0 x1 x2 ... xn) --> (xor x1 x2 ... xn)  if n>1

(xor 1 x1 x2 ... xn) --> (not (xor x1 x2 ... xn))  if n>1

(xor 1 x1) --> (not x1)

(xor 0 x1) --> x1

(not 1) --> 0

(not 0) --> 1

EXAMPLE
#include "mutnnn.h"		/* mbk utilities */
#include "logmmm.h"
chain_list *expr1,*expr2;
/* let's suppose that expr1 = (OR (OR 1 (NOT a)) (NAND 0 (NOT b))) */
expr2 = simplif10Expr(expr1);
displayExpr(expr2);
/* it will display
1
*/
freeExpr(expr1);
freeExpr(expr2);

SEE ALSO
log(1), abl(1), simplifNotExpr(2), devXorExpr(2), devXor2Expr(2), notExpr(2), flatPolarityExpr(2), flatArityExpr(2), sortExpr(2), normExpr(2).

SUPPORT STATUS
if bugs arise, please e-mail to cao-vlsi@masi.ibp.fr