Skip to content

Latest commit

 

History

4 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 

Repository files navigation

CNF-DNF-Convertor

Java code to convert every logical formula to conjunctive normal form and disjunctive normal form

Java code

Use simple names for variables like p, q, r.

Use the following characters for operators

  • and: &
  • or: |
  • negation: ~
  • implication: ->
  • equivalence: <->

Remember to put parentheses around each formula

Correct samples: ((p->q)&p) - (~(p->q))|(p&(~q))

Wrong samples: (p->q)&p - ~(p->q) - p&(~q) - (p&~q)

About

Java code to convert every logical formula to conjunctive normal form and disjunctive normal form

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages