Re: ((a&&b)||c)==((a||c)&&(b||c))
- To: mathgroup at smc.vnet.net
- Subject: [mg62054] Re: ((a&&b)||c)==((a||c)&&(b||c))
- From: "Steven T. Hatton" <hattons at globalsymmetry.com>
- Date: Thu, 10 Nov 2005 02:50:36 -0500 (EST)
- References: <dksdln$h87$1@smc.vnet.net> <dkshui$jki$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
Peter Pein wrote: > But Mathematica does: > > In[1]:= expr = ((a && b) || c) == ((a || c) && (b || c)) > Out[1]= ((a && b) || c) == ((a || c) && (b || c)) > In[2]:= LogicalExpand /@ expr > Out[2]= True However: In[1]:= expr = ((a && b) || c) == (a || c) && (b || c); LogicalExpand /@ expr Out[1]:= ((a && b) || c) == (a || c) && (b || c) I believe the reason Mathematica is having a hard time with this is because the rules of combining logical operators cannot be expressed in terms of a strict precedence hierarchy. I particular the distributive laws: (P && (Q || R)) <=> ((P && Q) || (P && R)) (P || (Q && R)) <=> ((P || Q) && (P || R)) -- The Mathematica Wiki: http://www.mathematica-users.org/ Math for Comp Sci http://www.ifi.unizh.ch/math/bmwcs/master.html Math for the WWW: http://www.w3.org/Math/
- Follow-Ups:
- Re: Re: ((a&&b)||c)==((a||c)&&(b||c))
- From: Daniel Lichtblau <danl@wolfram.com>
- Re: Re: ((a&&b)||c)==((a||c)&&(b||c))