Page 1 of 1

Boolean Algebra in DFSort and Icetool

PostPosted: Thu Mar 10, 2011 12:14 pm
by olivermf
Hello,

I have a question regarding use of boolean algebra in DFSort an Icetool.

I know that I can use "and"- and "or"-Statements in INCLUDE COND and OMIT COND.
But if I try to write more complex statements I have the problem that I am not sure if DFSort is associative with "AND" and if I can use paranthesis.

Example:

Can I program INCLUDE CONDs for something like

(a or b) and c or d and e

INCLUDE COND ((a,or,b),and,c,or,d,and,e)


a to e could be some conditions like
"10,2,CH,EQ,C'10'"


Is this possible and does DFSort interprete the statement as (a or b) and c or (d and e) ?

Thank you all in advance,

regards

Oliver

Re: Boolean Algebra in DFSort and Icetool

PostPosted: Thu Mar 10, 2011 3:30 pm
by NicC
Well, the documentation for INCLUDE COND mentions AND and OR in the syntax diagrams - did you look?

Re: Boolean Algebra in DFSort and Icetool

PostPosted: Thu Mar 10, 2011 4:04 pm
by olivermf
I finally found it in the Application and Programming Guide. Unfortunately the Reference Documentation was not helping there.

INCLUDE COND=((5,1,CH,EQ,8,1,CH),&,
((20,1,CH,EQ,C'A',&,30,1,FI,GT,10),|,
(20,1,CH,EQ,C'B',&,30,1,FI,LT,100),|,
(20,1,CH,NE,C'A',&,20,1,CH,NE,C'B')))


Thanks for the hint,

Regards

Oliver

Re: Boolean Algebra in DFSort and Icetool

PostPosted: Thu Mar 10, 2011 11:01 pm
by skolusu
olivermf wrote:I finally found it in the Application and Programming Guide. Unfortunately the Reference Documentation was not helping there.


Oliver,

I guess you haven't looked in the right place. The Relational Condition section under INCLUDE Control Statement clearly mentions about the rules of using Relational conditions with AND or OR