AngouriMath

Navigation

← Back to list of members

BuildTruthTable​(AngouriMath.​Entity,​AngouriMath.​Entity.​Variable[])

 Method (no overloads)

Summary

Combines all possible values of variables and has the last column as the result of the function

Example

using AngouriMath;
using System;
using static AngouriMath.MathS;

var (x, y) = Var("x", "y");
var myXor = Disjunction(Conjunction(x, Negation(y)), Conjunction(y, Negation(x)));
Console.WriteLine(myXor);
Console.WriteLine(MathS.Boolean.BuildTruthTable(myXor, x, y).ToString(multilineFormat: true));

Prints
x and not y or y and not x
Matrix[4 x 3]
False   False   False   
False   True    True    
True    False   True    
True    True    False   

























Angouri © 2019-2023 · Project's repo · Site's repo · Octicons · Transparency · 1534 pages online