private void semanticTableauxBtn_Click(object sender, EventArgs e) { selectedApp = semanticTableauxApp; try { Parse(); } catch { } if (selectedApp.Root != null) { DisplayProposition(); bool isTautology = semanticTableauxApp.IsTautology(); if (isTautology) { semanticTableauxBtn.BackColor = Color.LightGreen; semanticTableauxBtn.ForeColor = Color.Black; } else { semanticTableauxBtn.BackColor = Color.Red; semanticTableauxBtn.ForeColor = Color.White; } } }
private void ParseAbstractProposition() { selectedApp = logicApp; ResetAllControls(); try { Parse(); } catch (Exception) { } if (selectedApp.Root != null) { DisplayProposition(); if (selectedApp.Root.IsAbstractProposition()) { DisplayUniqueVariables(); DisplayTruthTableInformation(); DisplaySimplifiedTruthTable(); if (logicApp.NonConstantExpressionWasParsed()) { DisplaySimplifiedDnfExpression(); DisplayDisjunctiveNormalFormInformation(); DisplayNandifiedInformation(); } DisplayHashCodes(); DisplayIfAllCodesMatched(); } } }