CONTENTS

LogiCal, the Logi(c) Cal(culator)


INTRODUCTION

LogiCal is an easy-to-use Logic Calculator that functions in a manner analogous to math calculators. When you use a math calculator, you typically enter a series of numbers and ask the machine to find the number to which they "add up." When you use LogiCal, you enter a series of premises and a conclusion, and you ask the program whether or not the premises "add up" to the conclusion. The program is available at no charge here.

The premises and conclusion can be entered using the language of propositional calculus, the language of predicate calculus (with predicates of one argument only), the language of elementary set theory, or even certain basic English sentences. Since some of the symbols in the languages of logic and set theory are not available on standard keyboards, LogiCal allows the user to type their English equivalents and translates what was entered into symbolic notation.


USES FOR THE PROGRAM

The primary use of LogiCal is to confirm that the conclusion of a valid argument really follows from its premises. Of course, if the premises are wrong, the conclusion may still be untrue. On the other hand, the very discipline of translating each premise into strict logical language may sometimes bring to our attention a deficiency in a particular premise.

If the argument is invalid, LogiCal points out specific cases in which the premises could be true but the conclusion would be false. Sometimes, we may then find that the argument can be remedied by supplying some additional premise that was not made explicit previously.

In addition, we can use LogiCal to analyze "what if" scenarios, exploring just what conclusions would be entailed by particular premises.

Finally, LogiCal can serve as an introduction to the precision and symbolic language of logic. In particular, when premises are entered using the program's English-based Natural Language mode, the user can see exactly how each sentence is translated into a precise statement in predicate calculus.


PROGRAM OPERATION

When LogiCal is started, the program displays an area on the left side of the window to enter up to eight premises and a conclusion to be tested. A quick-reference syntax guide is displayed on the right. At the top of the screen, the user can choose Propositional Calculus mode, Predicate Calculus mode, Set Theory mode, or Natural Language mode (the default), and the syntax display changes accordingly. The syntax for these four modes is also described in the Syntax section of this document. In general, Propositional Calculus mode can be used when we are concerned only with how propositions relate to one another and not with how they break down into subjects and predicates. Predicate Calculus mode allows us to break down propositions further, by specifying predicates and the objects to which the predicates are to be applied. Set Theory mode can be used to describe relationships among sets and their members. Natural Language mode is used when we wish to state an argument using basic English syntactical structures, which are then translated into predicate calculus statements.

The first-time user can see immediately how the program works in each mode by clicking one of the four examples in the Help menu. When an example is clicked, an argument is described and translated into premises and a conclusion on the screen and then evaluated.

When the user enters a premise or conclusion into a text box and clicks elsewhere, any errors are flagged. (In Natural Language mode, the parsing for errors begins at the moment the user types the period that terminates a sentence.) If there are no errors, the entered statement is translated into symbolic notation beneath the text box. If desired, the user can then click Show Truth Table to view the conditions under which the statement is true or false.

After entering all the premises and the conclusion, the user clicks Evaluate Conclusion, and the program evaluates whether or not the conclusion follows from the premises. One of the following four messages is returned:

If the premises or conclusion are complex, the program may take a few moments or even a few minutes to carry out its calculations. The process can be interrupted by the user at any time by clicking Cancel.

After reviewing the results, the user can modify the argument and reevaluate it, or click Clear/Restart in order to enter a new argument.

In Natural Language mode, the terms used in an argument are determined by an interactive process described in the Natural Language Syntax section of this document. In particular, the user can predefine terms through the Language Terms screen, invoked either by clicking the Add/Correct Terms button or by choosing Show/Update Terms from the Natural Language menu.


SYNTAX

This section provides both informal and formal descriptions of the proper syntax for entering the premises and conclusion in the Propositional Calculus, Predicate Calculus, Set Theory, and Natural Language modes.
Propositional Calculus Syntax

In Propositional Calculus mode, the basic propositions are represented by single letters, which may be either lowercase or uppercase. (If both X and x are used, the program will treat them as independent propositions.) Such propositions can be modified or interconnected by the operators not (or ~), and, or, iff, and implies. All of these operators are interpreted by LogiCal in the same manner as in traditional logic courses.

For example, if x and y are propositions, then not x (or ~ x) represents the proposition that x is false. The expression x and y represents the proposition that both x and y are true. Similarly, x or y means that either x or y is true, possibly even both.

In the expression x iff y, the operator iff is short for "if and only if." This expression is true if x and y are both true, or if they are both false; otherwise, the expression is false.

The expression x implies y is true in all but one case, namely, when x is true but y is false. Note that if x represents "the moon is made of green cheese" and y represents "2 is greater than 3," x implies y is considered true, since x (the "antecedent") is false. In common English, we usually express the notion x implies y using a sentence of the form: "If x, then y."

Expressions may be nested to any level of complexity, at least within the size limit of the text box. For example, x, y, z, and w can be combined in an expression such as:

x or not x and y implies z iff not w

Just as in the expressions of standard algebra, some operators take default precedence over others. Specifically, the not operator is applied first, followed by the and operator, followed by or, followed by implies and iff. (Operators at the same precedence level are applied in left-to-right order.) Therefore the above expression is interpreted as follows:

((x or ((not x) and y)) implies z) iff (not w)

If a different meaning is intended, then the grouping can be overridden by parentheses, just as in basic algebra. Thus not (x and y) has an entirely different meaning from not x and y. It is always a good idea to include parentheses in cases of doubt or simply to provide clarity.

Operator Precedence Level
not4
~4
and3
or2
implies1
iff1

Propositional Calculus Syntax: Formal Description

<statement> ::= a | b | c | ... | z | A | B | C | ... | Z

<statement> ::= not <statement> | ~ <statement> 
                | <statement> and <statement> | <statement> or <statement>
                | <statement> implies <statement> |  <statement> iff <statement>
                | (<statement>)

NOTE: The operators not, and, or, implies, and iff are not case-sensitive.


Predicate Calculus Syntax

In Predicate Calculus mode, the most basic statements consist of a predicate followed by an object to which the predicate applies. Predicates are indicated by single uppercase letters, and objects by single lowercase letters. For example, D might represent the predicate "is eating dinner" and j might represent the object "Johnny"; Dj then represents "Johnny is eating dinner." In ordinary English, of course, the subject usually precedes the predicate, but by the conventions of predicate calculus, the predicate comes first.

In more advanced predicate logic, predicates can also be applied to two or more objects simultaneously. It has been proven mathematically, however, that there does not exist any general algorithm by which the validity of an argument in such a system can always and consistently be determined. For that reason, LogiCal is restricted to monadic predicate calculus, in which each predicate takes just one object.

The statements of predicate calculus can be modified or interconnected by the operators not (or ~), and, or, iff, and implies, as well as by "quantifiers" to be discussed below. All of these operators are interpreted by LogiCal in the same manner as in traditional logic courses.

Building on our previous example, for instance, not Dj (or ~Dj) represents "Johnny is not eating dinner." Similarly, if Dm represents "Mary is eating dinner," then Dm and not Dj represents "Mary is eating dinner and Johnny is not eating dinner." Also, Dm or Dj means that either Mary or Johnny is eating dinner (possibly even both).

In the expression Dm iff Dj, the operator iff is short for "if and only if." This expression is true if Dm and Dj are both true, or if they are both false; otherwise, the expression is false. Thus Dm iff Dj would be true if Mary and Johnny can only eat simultaneously.

The expression Dm implies Dj is true in all but one case, namely, when Dm is true but Dj is false. Note that if Mary is not eating dinner, then Dm implies Dj must necessarily be true, since Dm (the "antecedent") is false. In common English, we usually express the implies operator using a sentence of the form "if x, then y." For instance, Dj implies not Sj might signify: "If Johnny is eating dinner, then he is not sleeping."

Predicate calculus also includes a "universal quantifier" and an "existential quantifier," represented in LogiCal by the operators forall (written as one word) and exists respectively. Each of these quantifiers must be followed by a variable (optionally enclosed in parentheses) and an expression. For example:

forall x (Sx implies not Dx)

The expression is true if and only if for all x, whenever Sx is true, Dx is false. In English, it might be rendered as: "If anyone is sleeping, then he/she is not eating dinner." Note that the forall expression makes an assertion not just about one x, but about a whole universe of possible objects. An expression using exists, in contrast, asserts only that some one object exists that satisfies the condition. For example:

exists y (not Sy and not Dy)

This expression asserts that there exists at least one y such that Sy is false and Dy is also false. In English, it might be rendered: "Someone is neither sleeping nor eating dinner."

The variable in an exists or forall expression is represented by any lowercase letter, optionally enclosed in parentheses. The variable applies only within the scope of that expression, and the same letter may in fact have a different meaning outside the expression. Consider, for instance, this expression:

Dj and exists (j) Sj

Here the j in Dj is a constant that might represent "Johnny," while the j in the exists expression is a variable that could represent anyone at all. The entire idea might be rendered in English as "Johnny is eating dinner and someone is sleeping," and there is no implication that Johnny himself is sleeping. If desired, such situations can be avoided simply by choosing different letters for the variables associated with quantifiers.

Expressions may be nested to any level of complexity, at least within the size limit of the text box. For example, Dm, Dj, Sm, and Sj can be combined in an expression such as:

Dm or not Dm and Dj implies Sj iff not Sm

Just as in the expressions of standard algebra, some operators take default precedence over others. Specifically, forall, exists, and not are applied first, followed by the and operator, followed by or, followed by implies and iff. (Operators at the same precedence level are applied in left-to-right order.) Therefore the above expression is interpreted as follows:

((Dm or ((not Dm) and Dj)) implies Sj) iff (not Sm)

If a different meaning is intended, then the grouping can be overridden by parentheses, just as in basic algebra. Thus not (Dj and Dm) has an entirely different meaning from not Dj and Dm. It is always a good idea to include parentheses in cases of doubt or simply to provide clarity.

Because the operators forall and exists are applied first, the following two expressions do not have the same meaning:

  1. forall z (Dz and Sz)
  2. forall z Dz and Sz

Here (1) asserts that both Dz and Sz are true for all z. Expression (2), in contrast, states that Dz is true for all z, and in addition that Sz is true. In the Sz portion of expression (2), z falls outside the scope of the forall quantifier and refers to some constant object. In general, if a forall or exists quantifier is intended to apply to more than one predicate or more than one occurrence of a predicate, parentheses will be needed.

Operator Precedence Level
forall4
exists4
not4
~4
and3
or2
implies1
iff1

Predicate Calculus Syntax: Formal Description

<statement> ::= <predicate-expression>
                | not <statement> | ~ <statement> 
                | <statement> and <statement> | <statement> or <statement>
                | <statement> implies <statement> |  <statement> iff <statement>
                | forall <variable> <statement>
                | exists <variable> <statement>
                | (<statement>)

<predicate-expression> ::= <predicate><object>

<variable> ::= <object> | (<variable>)

<predicate> ::= A | B | C | ... | Z

<object> ::= a | b | c | ... | z

NOTE 1: The operators not, and, or, implies, iff, forall, and exists are not case-sensitive.

NOTE 2: In a <predicate-expression>, no intervening spaces are permitted between the <predicate> and the <object>.


Set Theory Syntax

Set Theory mode is used to express relationships among sets and the objects (elements) belonging to those sets. Objects are indicated by single lowercase letters. Sets are indicated by single uppercase letters, with the letter U reserved for the universal set--that is, the set of all objects relevant to the problem being analyzed. In addition, the null set (empty set) is represented either by nullset (written as one word) or the numeral 0.

New sets can also be specified by applying the ', union (or +), intersection (or .), and - operators to existing sets. The ' operator is appended to a set to indicate its complement; thus S' is the set of all objects that are not included in S. The union of sets S and T is represented either by S union T or by S + T and contains all elements that are included either in set S or in set T. The intersection of sets S and T is represented by S intersection T or by S.T and contains all elements that are included either in set S or in set T. The difference set S - T is the set of all elements that are included in S but not in T.

When sets are combined using the above operators, by default complement operators (') are applied first, followed by intersection operators (intersection or .) and difference operators (-), followed by union operators (union or +). (Operators at the same precedence level are applied in left-to-right order.) This order of precedence can be overridden by parentheses. Thus A + B' has a different meaning from (A + B)', and A union B intersection C has a different meaning from (A union B) intersection C.

Set Operator Precedence Level
'3
intersection2
.2
-2
union1
+1

Set membership is indicated by statements of the form x belongs S, where x is an object and S is a set. The other basic statements in Set Theory mode express relationships between sets. The statement S subset T (or S < T) is true if and only if all objects that belong to S also belong to T. The statement S = T is true if and only if the two sets comprise exactly the same objects. Thus S = T is equivalent to the following: S < T and T < S.

The statements of Set Theory mode can be modified or interconnected by the operators not (or ~), and, or, iff, and implies, as well as by the quantifiers forall and exists (discussed below). All of these operators are interpreted by LogiCal in the same manner as in traditional logic courses.

For example, not a belongs S is true if and only if a belongs S is false. The statement a belongs S and S subset T is true if both of its two constituent parts is true, and the statement S subset T or T subset S is true when either set is a subset of the other. In the last case, it is possible in particular that S and T might contain exactly the same elements, i. e., that S = T.

The expression x belongs A implies x belongs B is true in all but one case, namely, when the "antecedent" x belongs A is true but the "consequent" x belongs B is false. In common English, we might say: "If x is a member of set A, then x is a member of set B."

In the expression A=0 iff B=0, the operator iff is short for "if and only if." The expression is true if A and B are both the null set or if neither of them is the null set; otherwise it is false.

Set Theory mode also includes a "universal quantifier" and an "existential quantifier," represented in LogiCal by the operators forall (written as one word) and exists respectively. Each of these quantifiers must be followed by a variable, representing an object and optionally enclosed in parentheses, and an expression. For example:

forall x (x belongs S implies x belongs T)

The expression is true if and only if for all x, whenever x belongs to S, it must also belong to T. The same idea can be conveyed more succinctly as S subset T. Note that the forall expression makes an assertion not just about one x, but about a whole universe of possible objects. An expression using exists, in contrast, asserts only that some one object exists that satisfies the condition. For example:

exists y (not y belongs P and not y belongs Q)

This expression asserts that there exists at least one y such that y does not belong to set P and does not belong to set Q. Equivalently, we could write not (P union Q) = U, i. e., the union of P and Q is not the universal set.

The variable in an exists or forall expression is represented by any lowercase letter, optionally enclosed in parentheses. The variable applies only within the scope of that expression, and the same letter may in fact have a different meaning outside the expression. Consider, for instance, this expression:

a belongs S and exists (a) a belongs T

Here the first a (in a belongs S) refers to some constant object, while the a in the exists expression is a variable that could represent any object that happens to belong to T. The entire statement is equivalent to a belongs S and not T = nullset. Note that there is no implication that the constant object a necessarily belongs to T.

Such statements may be nested to any level of complexity, at least within the size limit of the text box. For example, x belongs A, x belongs B, y belongs A, and y belongs B can be combined in an expression such as:

x belongs A or ~ x belongs A and x belongs B implies y belongs A iff ~ y belongs B

Just as in the expressions of standard algebra, some operators take precedence over others. Specifically, forall, exists, and not (or ~) are applied first, followed by the and operator, followed by or, followed by implies and iff. (Operators at the same precedence level are applied in left-to-right order.) Therefore the above expression is interpreted as follows:

((x belongs A or ((~ x belongs A) and x belongs B)) implies y belongs A) iff (~ y belongs B)

If a different meaning is intended, then the grouping can be overridden by parentheses, just as in basic algebra. Thus not (p belongs M and q belongs N) has an entirely different meaning from not p belongs M and q belongs N. It is always a good idea to include parentheses in cases of doubt or simply to provide clarity.

Because the operators forall and exists are applied first, the following two expressions do not have the same meaning:

  1. forall z (z belongs D and z belongs S)
  2. forall z z belongs D and z belongs S

Here (1) asserts that both z belongs D and z belongs S are true for all z. Expression (2), in contrast, states that z belongs D is true for all z, and in addition that z belongs S is true. Without the parentheses, the last z falls outside the scope of the forall quantifier and refers to some constant object. In general, if a forall or exists quantifier is intended to apply to more than basic statement, parentheses will be needed.

Logical Operator Precedence Level
forall4
exists4
not4
~4
and3
or2
implies1
iff1

Set Theory Syntax: Formal Description

<statement> ::= <basic-statement>
                | not <statement> | ~ <statement> 
                | <statement> and <statement> | <statement> or <statement>
                | <statement> implies <statement> |  <statement> iff <statement>
                | forall <variable> <statement>
                | exists <variable> <statement>
                | (<statement>)

<basic-statement> ::= <object> belongs <set>
                      | <set> subset <set> | <set> < <set>
                      | <set> = <set>

<variable> ::= <object> | (<variable>)

<set> ::= A | B | C | ... | Z | nullset | 0
          | <set>'
          | <set> union <set> | <set> + <set>
          | <set> intersection <set> | <set>.<set>
          | <set> - <set>
          | (<set>)

<object> ::= a | b | c | ... | z

NOTE: The operators not, and, or, implies, iff, forall, exists, belongs, subset, intersection, and union are not case-sensitive.


Natural Language Syntax

In Natural Language mode, the premises and conclusion are entered as English-language sentences, using a variety of syntactical patterns commonly encountered in formal logical arguments and syllogisms and described in this section. These patterns are assigned logical interpretations consistent with those of a competent English speaker. Although LogiCal allows for a great deal of linguistic freedom and flexibility, the syntactical patterns it recognizes are subject to the following limitations:

Natural Language Syntax: Terms

Sentences in Natural Language mode are constructed from certain core English words, punctuation symbols (commas and period), and additional language terms that are introduced by the user. The user's language terms can be either single words or multi-word phrases, and they can either be predefined through the Language Terms screen or else will be inferred by LogiCal where possible. Any inferred terms are displayed, along with their variant forms (plural, etc.) on the right side of the screen, and they can always be modified through the Language Terms screen. Even if the user clicks Clear/Restart and enters a subsequent argument, these language terms will continue to be recognized as long as the program is running, unless they are cleared by clicking Clear All Terms on the Natural Language menu.

Multi-word terms must be predefined, and grammatically irregular terms may need to be predefined. As an example of the latter, consider the following argument:

Dolly is a sheep.
All sheep are woolly.
Therefore Dolly is woolly.

Because the word "sheep" is the same in its singular and plural variants (contrary to usual English patterns), these need to be predefined on the Language Terms screen before the argument is entered; otherwise, LogiCal will assume that the plural of "sheep" is "sheeps" and will flag an error when the second premise is entered.

There are four kinds of language terms: adjectives, specific nouns, class nouns, and predicates. In the argument above, "woolly" is an adjective. "Dolly" is a specific noun because it refers to one specific animal. "Sheep" is a class noun because it refers to any member(s) of the class of all sheep. In the sentence "Dolly grazes," "grazes" is a predicate. The four kinds of terms are shown, along with their variants, in four separate columns on the Language Terms screen.

Often, as in the above example, a specific noun is a proper noun. It might, however, be a common noun, such as "hydrogen" in the statement "hydrogen is an element." It might also be a phrase, e. g., "the agora" in "the agora is crowded and noisy." In some cases, the same word might be used as either a specific noun or a class noun, depending on the context of a particular argument. For example, in the statement "man is a bipedal primate," the word "man" refers to the species as a whole and is therefore a specific noun. In the statement "Socrates is a man," in contrast, "man" refers to a member of a class and is a class noun. In order to avoid ambiguity, LogiCal does not permit these two usages to be intermixed within the same argument, and the term "man" cannot be defined as both a specific noun and a class noun on the Language Terms screen.

Adjectives, class nouns, and predicates all have variant forms as follows:

Natural Language Syntax: Using the Language Terms Screen

The Language Terms screen can be reached either by choosing Show/Update Terms from the Natural Language menu or by clicking the Add/Correct Terms button. The screen is also displayed automatically by LogiCal if some terms in a statement cannot be categorized by inference or if some variants cannot be determined; in that case, a prompting message asks for the needed terms/variants. The screen's operation is straightforward and intuitive. In order to add the predicate "is grazing" to the screen, the user clicks Add Predicate and then types "is grazing" into the text box for the affirmative singular form. (Natural Language mode is not case-sensitive, and entries typed onto the screen appear in uppercase.) If the user then clicks anywhere outside the text box, LogiCal automatically fills in defaults for the predicate's other three variants, which can then be modified if necessary. Any terms that are already present can also be modified, or a term can be deleted by clearing out all of its variants. Finally, the user clicks Update to apply all additions and modifications before returning to the main screen. If any of the modified/deleted terms are used in statements that have already been entered, those statements are automatically re-parsed by LogiCal.

The following rules apply to all terms and variants:

If any of the above rules are violated, an error message will be displayed when Update is clicked.

Natural Language Syntax: Sentences

The simplest sentences in Natural Language mode consist of a single clause, followed by a period. (Clauses will be discussed in the next subsection.)

Socrates is a philosopher.

A sentence can also be formed from two or three clauses linked by and:

Aristotle is a philosopher, and Alexander is a conqueror.
Hydrogen is an element, and oxygen is an element, and water is a compound.

Here the commas are required, since they are used by LogiCal to determine the boundaries between clauses. Two or three clauses can also be linked by or:

Every man is a strong swimmer, or some men drown.
Hydrogen is an element, or hydrogen is a compound, or hydrogen is a mixture.

Note, however, that the following is not a valid sentence, because it mixes the conjunctions or and and, and it is unclear which conjunction takes precedence:

INVALID: All men are Greeks, or some men are barbarians, and no barbarians are Greeks.

A valid sentence can be formed by joining two clauses using "if and only if" (with no comma):

Athens is secure if and only if some Athenians are fine warriors.

The above sentence asserts that the statements "Athens is secure" and "some Athenians are fine warriors" are logically equivalent; that is, each implies the other. A one-way implication can be conveyed by the familiar "if/then" sentence:

If some Athenians are fine warriors, then Athens is secure.

The "if" condition can also consist of two clauses joined by or or and:

If some Athenians are fine warriors, or there is no attack, then Athens is secure.
If no Athenians are fine warriors, and there is an attack, then Athens is defeated.

The "if/then" structures presented above can also be modified by replacing the clause following then with two clauses linked by either and or:

If n is an integer greater than one, then either n is prime, or n is composite.
If z is a real number, and z is nonzero, then either z is positive, or z is negative.
If n is a positive integer, or n is a negative integer, then either n is even, or n is odd.

In the first example above, the adjective "greater than one" must be predefined on the Language Terms screen, since it contains more than one word.

The "then" clause can also contain a pronoun referring to the subject of the preceding "if" clause, as in the following examples:

If Socrates is a man, then he is a rational animal.
If some number is real, then it is complex.
If any person is wise, then he or she is honest.
If some persons are liars, then they are untrustworthy.
If any enemies are left, then they are slain.
If some woman is unmarried, then either she is single, or she is divorced.
If any warriors falter, then either they die, or they are lucky.

The pronoun must agree in number (singular or plural) both with the corresponding predicate and with the antecedent to which it refers. LogiCal classifies the pronoun they as plural, while he, she, he or she, and it are singular.

LogiCal also recognizes "if/then" sentences in which the "if" clause is the indefinite pronoun something, someone, or somebody, and in which the "then" clause refers to that indefinite subject through a personal pronoun:

If something is an animal or a plant, then it is living.
If somebody errs, then he or she is fallible.
If someone is a parent, then either he is a father, or she is a mother.

In an "if and only if" sentence, the subject of the second clause can be a pronoun pointing back to the first clause:

A king is wise if and only if he is a philosopher.
Real numbers are divisible if and only if they are nonzero.
Something is a man if and only if it is a rational animal.

The first sentence above is a statement only about kings, not about people or entities in general; it does not imply that all philosophers are wise kings. Similarly, the second sentence pertains only to real numbers, although it may happen to be true of other entities as well.

In a sentence consisting of two clauses joined by and, where the subject of the first clause is singular, it can be referenced by a pronoun in the second clause:

Socrates is a wise man, and he is a fine thinker.
Some Athenian is a thief, and he is hiding.

In a sentence consisting of two clauses joined by or, where the subject of the first clause is singular, it can be referenced by a pronoun in the second clause:

Helium is an element, or it is a compound.

LogiCal also accepts sentences in which certain variations in wording are converted internally so that the sentences conform to the types described above. These variations and the corresponding conversions are listed in Appendix 2. The repertoire of recognized sentences therefore includes variations such as the following:

Either helium is an element, or it is a compound.
Helium is an element unless it is a compound.
Any person is wise only if he or she is honest.
Athens is secure if some Athenians are fine warriors.
Aristotle is a philosopher; however, Alexander is a conqueror.
All Greeks are persons, but not all persons are Greeks.
If an organism is not a man, then either it isn't rational, or else it isn't an animal.

Natural Language Syntax: Clauses

A clause can consist a singular noun phrase followed by a singular predicate:

Some Spartan spy is eavesdropping.
Aristotle is a peripatetic philosopher.

The clause can also consist of a singular class phrase preceded by every, with an affirmative singular predicate:

Every good boy is successful.

A clause with every and a negative predicate, however, is ambiguous and is therefore not allowed:

INVALID: Every good boy is not successful.

LogiCal rejects the last statement because it is unclear whether it is intended to apply to all good boys or only to some of them. If it is intended to apply only to some of them, then the following clause can be used instead:

Not every good boy is successful.

On the other hand, if the statement is intended to apply to the entire set of good boys, then the following clause can be used:

No good boy is successful.

If the complement of "successful" has been defined on the Language Terms screen as "unsuccessful," then the following clause would be equivalent:

Every good boy is unsuccessful.

A clause can consist of all, a plural phrase designating some class, and an affirmative plural predicate:

All great men are wise.

Clauses with all and a negative predicate are disallowed, since they are ambiguous:

INVALID: All great men are not wise.

The last statement has two possible meanings. If the intended meaning is that wisdom is not universal among great men, then either of the following forms could be used instead:

Not all great men are wise.
Some great men are not wise.

On the other hand, if the intended meaning is that wisdom is never present in great men, then the following clause could be used:

No great men are wise.

In a clause beginning with all/some/every/no followed by a class phrase, the class phrase can be modified by the relative pronoun that or who along with a predicate that agrees in number (singular or plural):

Some animal that is not a fish swims.
Every man who is Cretan is a liar.
No chemical element that oxidizes is inert.
All Athenian heros who die are honored.
Not all philosophical beliefs that are accepted are valid.
Some scientific assumptions that are popular and plausible are invalid.

A clause can consist simply of the indefinite pronoun something, someone, or somebody, followed by a singular predicate:

Someone is listening and taking notes.
Somebody objects.
Something is rotten in the state of Denmark.

Here the phrases "taking notes" and "rotten in the state of Denmark" need to be predefined as adjectives on the Language Terms screen.

The last three examples asserted the existence of something with certain adjective attributes. A clause can also assert the existence of a member of some class, and LogiCal recognizes several clause structures to accomplish this purpose. The following clauses are all logically equivalent:

There exists an even prime number.
There is an even prime number.
There exists some even prime number.
An even prime number exists.
Some even prime number exists.
There are even prime numbers.
There exist even prime numbers.
There are some even prime numbers.
Even prime numbers exist.
Some even prime numbers exist.

Note that from the logician's viewpoint, "there are even prime numbers" is considered true even though there may only be one such number. The statement asserts merely that the class of even prime numbers is nonempty.

The scope of an existential clause can also be limited by the relative pronoun that or who followed by a predicate that agrees in number:

There exists an integer that is both even and prime.
There is some animal that is rational.
There are birds that are featherless.
There exist some wise men who disagree.
Some real numbers that are not rational exist.
There is a party that is not Democratic or Republican.

An existential clause can also use an indefinite pronoun followed by a relative pronoun and a predicate that agrees in number:

There exists something that is intelligent and powerful and inscrutable.
There is something that is alive and unconscious.

LogiCal recognizes a variety of clause patterns that assert nonexistence:

There is not an imaginary real number.
There does not exist a feathered fish.
There is not any good solution.
There is no human bird.
No irrational integers exist.
A moral dictatorship does not exist.
There are no irresistible forces.
There are not any immovable objects.
There do not exist any non-aquatic fishes.
Two-sided polygons do not exist.
No necessary evils exist.

Just as with existential clauses, in clauses that assert nonexistence the class phrase can be modified by a relative pronoun followed by a predicate that agrees in number:

There does not exist a halogen that is an inert gas.
There is no integer that is both even and odd.
There is not any wise man who is a fool.
No human being who is perfect exists.
There are no questions that are stupid.
There are not any imaginary numbers that are real.
There do not exist any people who are infallible.
No pigs that fly exist.

The negative pronouns nothing, nobody, and no one can also be used to assert nonexistence, with or without a restriction introduced by a relative pronoun:

No one is indispensable.
Nothing that is true is impossible.
There is nobody who objects.

Clauses asserting nonexistence can use the pronouns anything, anybody, or anyone, followed by a relative pronoun and a singular predicate:

There is not anything that is both living and dead.
There is not anybody who cares.
There does not exist anyone who disagrees.

The indefinite pronoun somebody, someone, or something can be used in the same context:

There does not exist something that is both animal and inorganic.

A clause can take the universal pronoun everything, everybody, or everyone as a subject, along with an affirmative singular predicate. A modifying relative pronoun and predicate may or may not be included:

Everything is an animal or a plant or a non-organism.
Everyone who is human is male or female.
Everybody who enrolled is studious.
Everyone who is an atheist disbelieves.

The predicate corresponding to the universal pronoun cannot be negative, since the statement would then become ambiguous. The meaning of the clause can be reversed, however, by preceding the universal pronoun with not:

Not everyone swims.
Not everything that is asserted is believable.
Not everybody who dissents is unpatriotic.

More generally, the meaning of any clause can be reversed by prefacing it with "it is not true that":

It is not true that there exists something that is omnipotent and omniscient and omnibenevolent.

A clause can also be prefaced by "it is true that," but its meaning is not thereby affected:

It is true that Socrates is a wise thinker.

Natural Language Syntax: Subjects

The subject of a singular clause can be a specific noun such as "Socrates," or it can be a class phrase preceded by some, no, or every. In the latter case, the class phrase consists of a singular class noun, such as "man," which may be modified by one or more adjectives (including complementary forms). If the adjectives consist of a single word, then they precede the noun they modify:

Some philosopher is Greek.
Every wise Greek philosopher is thoughtful.
Every non-thoughtful Greek philosopher is non-wise.

If the adjective is a multi-word phrase, it can either precede or follow the noun. In the following examples, the underlined multi-word adjectives must be predefined on the Language Terms screen:

Every regular polygon with three sides is an equilateral triangle.
Every clearly defined statement is either true or false.
Every ably defended fort in the territory survived.

The subject of a plural clause is a class phrase preceded by some, no, or all, but in the plural case the class phrase must be built around a plural class noun. The adjective patterns are similar to the singular case:

All right-angled equal-sided polygons with four sides are squares.
No American citizens born outside the United States are presidents.

LogiCal does not permit clauses with compound subjects such as "John and Betty," because they can create ambiguities, resulting in fallacies such as the following:

INVALID: John and Betty are married.
INVALID: Mark and Susan are married.
INVALID: Therefore Betty and Susan are married.

Because Natural Language statements in LogiCal must be reducible to a monadic predicate calculus (see also Question 1 in the FAQ), they cannot express relationships between multiple objects, such as John and Betty. On the other hand, if it is desired simply to convey that John and Betty both belong to the class of married individuals, then the following sentence is accepted by LogiCal:

John is married, and Betty is married.

Natural Language Syntax: Predicates

A singular predicate can be a predicate that has been introduced by the user and which is defined as singular on the Language Terms screen, such as two underlined predicates in this sentence:

Everyone swims, or somebody will not survive.

Alternatively, a singular predicate consists of the singular copula is or is not followed by either an adjectival descriptor or a singular class descriptor. An adjectival descriptor can consist of a single adjective, a series of adjectives connected by and, or a series of adjectives connected by or:

Socrates is Greek.
Pheidippides is swift and tireless.
Zero is not positive or negative or imaginary.

If and and or are intermixed within a series, the results can be ambiguous, and ambiguous statements are not permitted in LogiCal:

INVALID: Every nonzero real number is positive or negative and irrational or rational.

Here it is not clear how the adjectives should be grouped; there are several possible interpretations. Three conflicting interpretations are shown below, using parentheses as in mathematics:

INTERPRETATION 1: Every nonzero real number is (positive or (negative and irrational) or rational).
INTERPRETATION 2: Every nonzero real number is ((positive or negative) and irrational) or rational).
INTERPRETATION 3: Every nonzero real number is ((positive or negative) and (irrational or rational)).

Since Natural Language mode is English-based, it does not recognize parentheses for this purpose, but it does recognize "both/and" and "either/or" constructs. If the last interpretation is intended, it can be expressed as follows in LogiCal:

Every nonzero real number is both positive or negative and either irrational or rational.

Upon examination, it will be found that only one possible grouping can now be assigned to the adjectives while preserving the "both/and" and "either/or" units of the sentence.

In a negative predicate using a copula and an adjectival descriptor (or a class descriptor), the word not is part of the copula and not part of the descriptor. It therefore negates the predicate as a whole, and consequently negates the whole clause. The following two statements are logically equivalent, both in common English and in Natural Language mode:

Pheidippides is not tired or weak.
It is not true that Pheidippides is tired or weak.

Natural Language mode does not permit not to be used within an adjectival descriptor, but the complementary form of an an adjective can be used for the same purpose:

Achilles is bold and non-weak.

A singular class descriptor can consist of the indefinite article a or an followed by a singular class phrase. (Class phrases were discussed in the preceding Subjects section.) The combination of the indefinite article and singular class phrase can also be repeated several times, joined by and, or it can be repeated several times, joined by or:

Pericles is a wise cultured leader.
Archimedes is a physicist and an engineer and a brilliant mathematician.
Athens is not an island or a continent or an archipelago.

Within class descriptors, just as within adjectival descriptors, and and or cannot be intermixed, unless their scope is clearly defined through the use of "both/and" or "either/or" units:

Every human child is a non-adult and either a boy or a girl.
Every complex number is non-real or both real and non-imaginary.

A plural predicate is either a predicate that was introduced by the user and which is defined as plural on the Language Terms screen, or else it consists of the plural copula are or are not followed by either an adjectival descriptor or a plural class descriptor. An adjectival descriptor in a plural predicate is similar in form to the same descriptor in a singular predicate:

All Athenian warriors are brave and strong.
All nonzero real numbers are both positive or negative and either irrational or rational.
Some numbers are not imaginary or irrational.

Plural class descriptors are similar in form to singular class descriptors, except that the indefinite articles (a and an) are omitted and the component noun terms must be plural:

No human beings are islands.
All Greek city-states are non-islands and either democracies or oligarchies.
Some Greek citizens are wise philosophers or brilliant orators.

Natural Language Syntax: Formal Description

NOTE: Certain variations to the basic forms shown below are permitted, as indicated in Appendix 2.

User-Provided Terms: The following terms are provided by the user and appear on the Language Terms screen; they may entered directly onto that screen or inferred by LogiCal from the premises and conclusion entered by the user.


TRUTH TABLES

This section describes the contents of the truth tables, viewed by clicking the Show Truth Table buttons, in Propositional Calculus, Predicate Calculus, Set Theory, and Natural Language modes.
Truth Tables in Propositional Calculus Mode

A truth table describes the conditions under which a premise or conclusion is true or false. For a truth table in Propositional Calculus mode, each column heading on the left represents one of the basic operands (a, b, c, etc.), while the rightmost column heading is the symbolic logic string corresponding to the premise or conclusion being evaluated. Each row in the table corresponds to a particular combination of possible values for the basic operands, where each operand is either true (T) or false (F). The value in the rightmost column of the row indicates whether the premise or conclusion is true or false for that combination of values.

By default, only those operands that affect the value of the premise or conclusion are shown in the table. (This default can be overridden through the Truth Table Options menu.) Consider, for example, the following premise:

(a or b) and (c or not c)

This premise is true if either a or b is true, and the truth value of proposition c is ultimately irrelevant to it. Therefore the truth table for this premise is simplified by omitting the c column entirely. In some cases this process of simplification results in the elimination of all the columns (except the rightmost, which is associated with the premise itself), because the premise is either always true or always false, regardless of the values of the operands. When the happens, the normal tabular format of the truth table is replaced by the text "TRUE IN ALL CASES" or "FALSE IN ALL CASES." For example:

(a and b) implies a

This statement is always true, regardless of whether a is true or false and regardless of whether b is true or false. Such a statement is called a "tautology" by logicians. The statement a and not a, on the other hand, is always false.


Truth Tables in Predicate Calculus Mode

A truth table describes the conditions under which a premise or conclusion is true or false. Traditionally, truth tables are associated with propositional calculus, but tables that fulfill that same basic function are also possible in (monadic) predicate calculus, as illustrated here.

Each predicate in predicate calculus can also be thought of as a set. Specifically, predicate A is also the set of all objects x for which Ax is true. In the truth tables produced by LogiCal in Predicate Calculus mode, the rightmost column represents the premise or conclusion being evaluated, just as in Propositional Calculus mode. The columns on the left are either set columns or location columns. Depending on the premise or conclusion, either one or more set columns, one or more location columns, or columns of both kinds may be present.

Consider, for example, the following premise:

Am and not exists x (Ax and Bx)

For this premise, LogiCal produces a set column with heading A∩B and a location column with heading m. Each value in the set column is either 1 or 0, depending on whether the set is nonempty or empty. Each value in the location column is the name of a set to which m can belong (either A or A' in this example). The first row in the table corresponds to the condition in which A∩B is nonempty and m belongs to set A. Under this condition, the premise is false, as shown by the F in the rightmost column (headed by a symbolic logic string corresponding to the premise being evaluated). As the truth table shows, the premise is true only in the condition described by the third row, i. e., when A∩B is empty and m belongs to set A.

For some premises or conclusions, certain combinations of values for the various columns may be logically impossible, and these combinations are eliminated by LogiCal since the truth tables would otherwise be unreliable for purposes of logical inference. Consider, for example, the truth table generated by the following premise:

(Am or Bm) and forall x not Ax

This truth table contains a set column for A, which may be either nonempty (1) or empty (0), and a location column for m, which belongs to A∩B, A∩B', A'∩B, or A'∩B'. At first glance, therefore, it might seem that there are 2 x 4 = 8 possible combinations and that the table should have 8 rows. Two of these combinations, however, are inherently impossible and have therefore been excluded by LogiCal. If set A is empty (0), then m cannot possibly belong to either A∩B or A∩B'. Thus there are really only six cases to consider in evaluating the truth of the premise, and hence the table has only six rows.

By default, columns are generated only for sets and locations that affect the value of the premise or conclusion being evaluated. (This default can be overridden through the Truth Table Options menu.) Consider, for example, the following premise:

Am and forall x (Bx or not Bx)

The forall portion of this premise, it will be noted, is necessarily true regardless of the objects for which predicate B may be true or false, so predicate B is effectively irrelevant in evaluating the premise. Therefore the truth table for the premise is simplified by omitting all set columns involving B, leaving just one location column for m.

In some cases this simplification process results in the elimination of all the columns (except the rightmost, which is associated with the premise itself), because the premise is either always true or always false, regardless of the objects for which the various predicates may be true or false. When the happens, the normal tabular format of the truth table is replaced by the text "TRUE IN ALL CASES" or "FALSE IN ALL CASES." For example:

(forall x Ax) implies not exists z not Az

This statement is always true, regardless of the objects for which predicate A may be true or false. (If predicate A is true of all objects, then there cannot exist an object for which it is not true.) Such a statement is called a "tautology" by logicians. The statement Ax and not Ax, on the other hand, is always false.


Truth Tables in Set Theory Mode

The premises and conclusion in Set Theory mode are translated internally into the language of predicate calculus, with all sets being reinterpreted as predicates. For example, the statement x belongs S translates into Sx. Therefore the truth tables in Set Theory mode are identical in form to the Truth Tables in Predicate Calculus Mode.


Truth Tables in Natural Language Mode

The premises and conclusion in Natural Language mode are translated internally into the language of predicate calculus. All specific nouns are reinterpreted as objects, and all adjectives, class nouns, and predicates are reinterpreted as predicates in the predicate calculus. Therefore the truth tables in Natural Language mode are identical in form to the Truth Tables in Predicate Calculus Mode.


Truth Table Options

The options discussed in this section appear under "Truth Table Options" in the menu bar.

Eliminate Unneeded Columns

By default, any columns in a truth table that do not ultimately affect whether the premise or conclusion is true or false are omitted. This default procedure tends to reduce the size of tables dramatically, thereby enabling LogiCal to carry out its computations more efficiently. The user can choose to have those columns included by deselecting this option. It should be cautioned, however, that when this option is deselected, LogiCal may take considerably longer to complete its calculations. Also, selecting or deselecting this option does not modify the columns in any table that has already been built.

Show False Only

By default, all rows in a truth table are displayed, including those for which the premise or conclusion is true and those for which it is false. When Show False Only is selected, however, only those rows for which the premise or conclusion is false are shown, and it can be inferred that the premise or conclusion would be true under any other conditions not shown. This option is particularly useful in cases where the total number of rows is too large to display, but the number of rows for which the statement is false is relatively small.

The Show False Only and Show True Only options are mutually exclusive. When Show False Only is selected, Show True Only is turned off automatically.

Show True Only

By default, all rows in a truth table are displayed, including those for which the premise or conclusion is true and those for which it is false. When Show True Only is selected, however, only those rows for which the premise or conclusion is true are shown, and it can be inferred that the premise or conclusion would be false under any other conditions not shown. This option is particularly useful in cases where the total number of rows is too large to display, but the number of rows for which the statement is true is relatively small.

The Show True Only and Show False Only options are mutually exclusive. When Show True Only is selected, Show False Only is turned off automatically.

Allow Multi-Table Display

By display, only one truth table window is viewed at a time, and the table must be closed before any other action can be taken. Selecting the Allow Multi-Table Display option allows the truth table windows to be left open, thereby making it possible to have multiple truth table windows open simultaneously in order to compare them side by side.


Appendix 1: NATURAL LANGUAGE CORE ENGLISH WORDS

The following common English words and phrases are recognized by LogiCal and cannot be defined as terms on the Language Terms screen. (A core word or phrase can be contained within a longer defined term, however.)


Appendix 2: PERMISSIBLE VARIATIONS IN NATURAL LANGUAGE SYNTAX

Natural Language mode seeks to allow the premises and conclusion to be entered in a style approaching the freedom and flexibility of normal English. Toward that end, certain common variations in wording are permitted and will be translated internally or ignored where appropriate:

The following examples illustrate the variations above and are recognized as valid sentences by LogiCal:

Diogenes is satisfied only if there's an honest man.
Athens is weak if no Athenian warriors are strong.
Aristotle isn't satisfied unless Alexander is studious and attentive.
Socrates is fallible, but nobody's perfect.
If an animal is rational, then it's a man.
Either everyone eats, or else someone does not eat.
Whenever any triangle is equilateral, it is therefore isosceles.
Whatever is certain is possible; however, not everything that's possible is certain.


Appendix 3: FREQUENTLY ASKED QUESTIONS

Question 1. Why does LogiCal not accept predicates with multiple arguments, such as Tmb to represent "Mary is taller than Bob"?

A. In more advanced predicate logic, predicates can indeed be applied to two or more objects simultaneously. It has been proven mathematically, however, that there does not exist any general algorithm by which the validity of an argument in such a system can consistently be determined in all possible cases. For that reason, LogiCal is restricted to monadic predicate calculus, in which each predicate takes just one object.

Question 2. Why does LogiCal flag an error when I enter a simple statement such as Ax and Bx?

A. Such a statement will be flagged as an error if the user forgets to click the Predicate Calculus mode at the top of the screen before entering it.

Question 3. When I set up a complex series of premises and a conclusion and then click Evaluate Conclusion, LogiCal sometimes takes significant time to do its calculations. What is the program doing, and how can I gauge its progress in order to decide whether to wait or to click Cancel?

A. The program first takes the truth tables for the various premises and combines them together; it displays the message "Combining premises..." during this stage. It then compares that combined truth table against the truth table for the conclusion. The longest part of the comparison process is typically the determination of the various combinations of conditions; the message "Building combinations," followed by an estimated completion percentage, is displayed during that process. Finally, the program evaluates whether the conclusion is true for each combination; during this last stage the message "Evaluating combinations" is displayed, followed again by a completion percentage.