Logic CSCE 235 Fall 2008: Propositional Logic and Exercises, Study notes of Computer Science

A portion of the course materials for csce 235, fall 2008, focusing on propositional logic. It covers defining propositions, connectives, truth tables, precedence of logical operators, and their use in various fields such as bitwise operations, theoretical computer science (sat), and programming. The document also includes exercises on propositions, truth values, conditional statements, and logical equivalences.

Typology: Study notes

Pre 2010

Uploaded on 09/17/2009

koofers-user-7es
koofers-user-7es 🇺🇸

10 documents

1 / 11

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
LogicCSCE235,Fall2008 1
Overview
DefiningPropositionalLogic
Propositions
Connectives
Truthtables
PrecedenceofLogicalOperators
UsefulnessofLogic
Bitwiseoperations
LogicinTheoreticalComputerScience(SAT)
LogicinProgramming
LogicalEquivalences
Terminology
Truthtables
Equivalencerules
pf3
pf4
pf5
pf8
pf9
pfa

Partial preview of the text

Download Logic CSCE 235 Fall 2008: Propositional Logic and Exercises and more Study notes Computer Science in PDF only on Docsity!

Logic CSCE 235, Fall 2008

Overview

Defining Propositional Logic - Propositions - Connectives - Truth tables - Precedence of Logical Operators - Usefulness of Logic - Bitwise operations - Logic in Theoretical Computer Science (SAT) - Logic in Programming - Logical Equivalences - Terminology - Truth tables - Equivalence rules

Logic 235, Fall 2008

Propositions

What

is

Proposition:

A

declarative

sentence

that

is

either

true

or

false,

but

not

both.

Examples:

Logic 235, Fall 2008 Exercise1.1:

Which

of

these

sentences

are

propositions?

What

are

the

truth

values

of

those

that

are

proposition?

c)

(yes.

T)

d)

(yes.

F)

e) x+

(No.)

f) Answer this question. (No.)

Logic 235, Fall 2008 Exercise1.1:

Determine

whether

each

of

these

conditional

statements

is

true

or

false.

If

then

(F)

If

then

(T)

If

then

(T)

If monkeys can fly, then

(T)

Logic 235, Fall 2008 Exercise1.1: Construct a truth table for each of these compound propositions.

a) p ∧ ¬ q^ p q p ∧ ¬ q

Logic 235, Fall 2008 Exercise1.1: Construct a truth table for each of these compound propositions.

a) p ∧ ¬ q^ p q p ∧ ¬ q 0 1 0 1 0 0

Logic 235, Fall 2008 Exercise1.1: Construct a truth table for each of these compound propositions.

c) (p ∨ ¬ q ) → q p q ¬ q p ∨ ¬ q (p ∨ ¬ q)q 1 1 0 1 1 1 0 1 1 0 0 1 0 0 1 0 0 1 1 0

Logic 235, Fall 2008

Logical

Equivalences:

Ex1.2:

Use

truth

tables

to

verify

the

commutative

laws.

a) p

q

q

p^ p q pq qp 0 0 0 0 0 1 1 1 1 0 1 1 1 1 1 1 The two columns in the truth table are identical, thus we conclude that pqqp