Exemple #1
0
        /**
         * Returns the specified sentence in its logically equivalent conjunctive
         * normal form.
         *
         * @param s
         *            a propositional logic sentence
         *
         * @return the input sentence converted to it logically equivalent
         *         conjunctive normal form.
         */
        public static Sentence convert(Sentence s)
        {
            Sentence result = null;

            Sentence nnfSentence = ConvertToNNF.convert(s);
            Sentence cnfSentence = DistributeOrOverAnd.distribute(nnfSentence);

            result = cnfSentence;

            return(result);
        }