[英]Propositional formula for A, B, AC and BC
I am struggling trying to get a propositional formula of the following truth table: A, B, AC, BC. 我正在努力获取以下真值表的命题公式:A,B,AC,BC。
For A and B it's easy: A xor B. However, when you insert a new literal C... 对于A和B来说很简单:A xorB。但是,当您插入新的文字C时...
I tried using Wolfram by inputting the truth table (A & ~B & ~C) || 我尝试通过输入真值表(A&〜B&〜C)||使用Wolfram (~A & B & ~C) || (〜A&B&〜C)|| (A & ~B & C) || (A和〜B和C)|| (~A & B & C). (〜A&B&C)。 However, the suggested minimal forms are wrong since they do not consider C. 但是,建议的最小形式是错误的,因为它们不考虑C。
Can someone help expressing this in propositional logic using logical connectives like (A xor B) => C ? 有人可以使用(A xor B)=> C之类的逻辑连接词来帮助以命题逻辑表达这一点吗? Thanks! 谢谢!
You can perform minimization by means of using Karnaugh maps (amongst other methods - this one is the simpliest, you'll have to introduce a dummy variable D and just ignore it in the results). 您可以使用Karnaugh映射来执行最小化 (在其他方法中-这是最简单的方法,您必须引入一个虚拟变量D并在结果中忽略它)。
The solutions are right about not considering C
, though - it doesn't matter what the C
evaluates to, as long as A xor B
evaluates to true. 解决方案对于不考虑C
是正确的-只要A xor B
评估为true, C
评估的内容都没有关系。 I just did check that, to remind myself about how the Karnaugh maps are constructed. 我只是检查了一下,以提醒自己有关卡诺地图的构建方式。 Try drawing yourself a full truth table to see that. 尝试为自己绘制一个完整的真值表以查看该情况。
Take a look at the expression: 看一下表达式:
(A & ~B & ~C) || (~A & B & ~C) ||
(A & ~B & C) || (~A & B & C)
Both lines are identical except for the negation of C
, this means that C
is irrelevant : the value for C
doesn't change anything to the output of the function. 除了C
的取反外,两行都是相同的,这意味着C
无关紧要 : C
的值不会改变函数的输出。
This is also the conclusion one draws from a truth table: 这也是从真值表得出的结论:
|A|B|C||F|
+-+-+-++-+
|F|F|F||F|
|F|F|T||F|
|F|T|F||T|
|F|T|T||T|
|T|F|F||F|
|T|F|T||F|
|T|T|F||F|
|T|T|T||F|
Here F
being the outcome of the expression. 这里F
是表达式的结果。 If you for instance take the first line: |F|F|F||F|
例如,如果采用第一行: |F|F|F||F|
the result is false, which is the same for |F|F|T||F|
结果为假,与|F|F|T||F|
(with C
flipped). (将C
翻转)。 By doing this for every ( A
, B
) configuration one sees that the value of C
doesn't matter. 通过对每个( A
, B
)配置执行此操作,可以看到C
的值无关紧要。
Therefore you can simply exclude C
from the formula resulting in: 因此,您可以简单地从公式中排除C
,结果是:
(A & ~B) || (~A & B)
Which means A xor B
. 意思是A xor B
Wolfram Alpha comes to the same conclusion (see ANF expression). Wolfram Alpha得出了相同的结论(请参阅ANF表达式)。
I have the answer 我有答案
(A xor B) and (C => (A or B)) (A xor B)和(C =>(A或B))
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.