TruthTable.ToAndOr
Back to table
/*
Logic-Function-Analysis
TruthTable.ToAndOr
[AndOr() g]=TruthTable.ToAndOr(TruthTable f);
f : a logic function in the TruthTable form
g : a list of logic function in the AndOr form
Convert a TruthTable to a list of the AndOr logic functions.
*/
//-------------------------------------------------------------------
// examples
[table]=TruthTable()
{
2'b00 => 4'b1000;
2'b01 => 4'b0100;
2'b10 => 4'b0010;
2'b11 => 4'b0001;
}
[flist]=TruthTable.ToAndOr(table);
f1=List.Get(flist,1);
f2=List.Get(flist,2);
[f3,f4]=TruthTable.ToAndOr(table);
[glist]=Convert.ToAndOr(table);
Print(flist,f1,f2,f3,f4,glist);
//-------------------------------------------------------------------
// result
Advanced PermuteLogicFunction IsBiUnateFunctionTo IsCovering IsSymmetricFunction AndOr MaxValue binary ToSOP DigitalSystem Eq long() minterm() Nand PositiveIntegerToMantissa PositiveNumberToMantissa object Or To2LayerAndXor ToFullAnd Solve CreateCompactTable CreateCompactTableWithFullSimplification Compatibility Balanced BestVariableOrder Fast SimpleCover Normalization Zero