×
DON'T BE SATISFIED WITH B when you can get A+
--Your friends at LectureNotes
Close

Mathematical Foundations of Computer Science

by Jntu Heroes
Type: NoteInstitute: JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY Offline Downloads: 184Views: 6418Uploaded: 9 months agoAdd to Favourite

Touch here to read
Page-1

Mathematical Foundations of Computer Science by Jntu Heroes

Topic:
Jntu Heroes
Jntu Heroes

/ 92

Share it with your friends

Suggested Materials

Leave your Comments

Contributors

Jntu Heroes
Jntu Heroes
LECTURE NOTES ON MATHEMATICAL FOUNDATIONS OF COMPUTER SCIENCE II B. Tech I semester (JNTUH-R13) COMPUTER SCIENCE AND ENGINEERING
UNIT-I Mathematical Logic Statements and notations: A proposition or statement is a declarative sentence that is either true or false (but not both). For instance, the following are propositions: ―Paris is in France‖ (true), ―London is in Denmark‖ (false), ―2 < 4‖ (true), ―4 = 7 (false)‖. However the following are not propositions: ―what is your name?‖ (this is a question), ―do your homework‖ (this is a command), ―this sentence is false‖ (neither true nor false), ―x is an even number‖ (it depends on what x represents), ―Socrates‖ (it is not even a sentence). The truth or falsehood of a proposition is called its truth value. Connectives: Connectives are used for making compound propositions. The main ones are the following (p and q represent given propositions): Name Negation Conjunction Disjunction Exclusive Or Implication Biconditional Represented ¬p Q Q p∧ p∨ p⊕q p→q p↔q Meaning ―not p‖ ―p and q‖ ―p or q (or both)‖ ―either p or q, but not both‖ ―if p then q‖ ―p if and only if q‖ Truth Tables: Logical identity Logical identity is an operation on one logical value, typically the value of a proposition that produces a value of true if its operand is true and a value of false if its operand is false. The truth table for the logical identity operator is as follows:
Logical Identity p p T T F F Logical negation Logical negation is an operation on one logical value, typically the value of a proposition that produces a value of true if its operand is false and a value of false if its operand is true. The truth table for NOT p (also written as ¬p or ~p) is as follows: Logical Negation p ¬p T F F T Binary operations Truth table for all binary logical operators Here is a truth table giving definitions of all 16 of the possible truth functions of 2 binary variables (P,Q are thus boolean variables):
P Q 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 T T F F F F F F F F T T T T T T T T T F F F F F T T T T F F F F T T T T F T F F T T F F T T F F T T F F T T F F F T F T F T F T F T F T F T F T where T = true and F = false. Key: 0, false, Contradiction 1, NOR, Logical NOR 2, Converse nonimplication 3, ¬p, Negation 4, Material nonimplication 5, ¬q, Negation 6, XOR, Exclusive disjunction 7, NAND, Logical NAND 8, AND, Logical conjunction 9, XNOR, If and only if, Logical biconditional 10, q, Projection function 11, if/then, Logical implication

Lecture Notes