Please help me with my assignment in latex form, all the requirement are in the pdf.COMPSCI/SFWRENG 2FA3

Discrete Mathematics with Applications II

Winter 2021

Assignment 3

Dr. William M. Farmer and Dr. Mehrnoosh Askarpour

McMaster University

Revised: February 7, 2021

Assignment 1 consists of some background definitions, two sample problems, and two required problems. You must write your solutions to the

required problems using LaTeX. Use the solutions of the sample problems

as a guide.

Please submit Assignment 1 as two files, Assignment 1 YourMacID.tex

and Assignment 1 YourMacID.pdf, to the Assignment 1 folder on Avenue

under Assessments/Assignments. YourMacID must be your personal MacID

(written without capitalization). The Assignment 1 YourMacID.tex file is

a copy of the LaTeX source file for this assignment (Assignment 1.tex

found on Avenue under Contents/Assignments) with your solution entered

after each required problem. The Assignment 1 YourMacID.pdf is the PDF

output produced by executing

pdflatex Assignment 1 YourMacID

This assignment is due Sunday, February 12, 2021 before midnight. You are allow to submit the assignment multiple times, but only

the last submission will be marked. Late submissions and files that are

not named exactly as specified above will not be accepted! It is

suggested that you submit your preliminary Assignment 1 YourMacID.tex

and Assignment 1 YourMacID.pdf files well before the deadline so that your

mark is not zero if, e.g., your computer fails at 11:50 PM on February 12.

Although you are allowed to receive help from the instructional

staff and other students, your submission must be your own work.

Copying will be treated as academic dishonesty! If any of the

ideas used in your submission were obtained from other students

or sources outside of the lectures and tutorials, you must acknowledge where or from whom these ideas were obtained.

Background

A word over an alphabet Σ of symbols is a string

a1 a2 a3 · · ·an

1

of symbols from Σ. For example, if Σ = {a, b, c}, then the following are

words over Σ among many others:

• cbaca.

• ba.

• acbbca.

• a

• (which denotes the empty word).

Let Σ∗ be the set of all words over Σ (which includes , the empty word).

Associated with each word w ∈ Σ∗ is a set of positions. For example, {1, 2, 3}

is set of positions of the word abc with the symbol a occupying position 1,

b occupying position 2, and c occupying position 3. If u, v ∈ Σ∗ , uv is the

word in Σ∗ that results from concatenating u and v. For example, if u = aba

and v = bba, then uv = ababba.

A language L over Σ is a subset of Σ∗ . A language can be specified by

a first-order formula in which the quantifiers range over the set of positions

in a word. In order to write such formulas we need some predicates on

positions. last(x) asserts that position x is the last position in a word. For

a ∈ Σ, a(x) asserts that the symbol a occupies position x. For example, the

formula

∀ x . last(x) → a(x)

says the symbol a occupies the last position of a word. This formula is true,

e.g., for the words aaa, a, and bca.

The language over Σ specified by a formula is the set of words in Σ∗ for

which the formula is true. For example, if a ∈ Σ, then ∀ x . last(x) → a(x)

specifies the language {ua | u ∈ Σ∗ }.

Problems

1. [12 points] Let Σ be a finite alphabet and Σ∗ be the set of words over

Σ. Define u ≤ v to be mean there are x, y ∈ Σ∗ such that xuy = v.

That is, u ≤ v holds iff u is a subword of v.

a. Prove that (Σ∗ , ≤) is a weak partial order.

b. Prove that (Σ∗ , ≤) is not a weak total order.

c. Does (Σ∗ , ≤) have a minimum element? Justify your answer.

d. Does (Σ∗ , ≤) have a maximum element? Justify your answer.

2. [8 points] Let Σ = {a, b, c} be a finite alphabet. Construct formulas

that specify the following languages over Σ.

2

a. {awa | w ∈ Σ∗ }.

b. {dwd | d ∈ Σ and w ∈ Σ∗ }.

c. {uaav | u, v ∈ Σ∗ }.

d. {uavbw | u, v, w ∈ Σ∗ }.

e. Σ∗ .

f. Σ∗ { }.

g. { }.

h. ∅.

3

Purchase answer to see full

attachment

#### Why Choose Us

- 100% non-plagiarized Papers
- 24/7 /365 Service Available
- Affordable Prices
- Any Paper, Urgency, and Subject
- Will complete your papers in 6 hours
- On-time Delivery
- Money-back and Privacy guarantees
- Unlimited Amendments upon request
- Satisfaction guarantee

#### How it Works

- Click on the “Place Order” tab at the top menu or “Order Now” icon at the bottom and a new page will appear with an order form to be filled.
- Fill in your paper’s requirements in the "
**PAPER DETAILS**" section. - Fill in your paper’s academic level, deadline, and the required number of pages from the drop-down menus.
- Click “
**CREATE ACCOUNT & SIGN IN**” to enter your registration details and get an account with us for record-keeping and then, click on “PROCEED TO CHECKOUT” at the bottom of the page. - From there, the payment sections will show, follow the guided payment process and your order will be available for our writing team to work on it.