---
tags: mth225, weekly-challenge
---
# MTH 225: Weekly Challenge 3
**Due on Blackboard by 11:59pm Eastern on Saturday 9/25.** See "Submission Instructions" at the end of this document for details.
:::warning
**Instructions**:
* Your work on Weekly Challenges should consist of **complete solution attempts for all the Application/Extension Problems and complete and thoughtful responses to all the Feedback and Reflection prompts**. Before submitting your work, make sure you've reviewed the [Specifications for Satisfactory Work in MTH 225](/Cy6P0rGZQzuOM3NwZ3ZuMw) document to make sure your work meets the standards to the best of your knowledge.
* **Practice Exercises are optional.** You do not need to turn any part of these in. But if you want feedback on any of them, turn those in with the rest of your work and I'll look at it.
* You may type up your work or write it by hand on paper, whiteboard, or in a notes app. **Typewritten work is preferred** because it makes revisions easier for you.
* If you handwrite your work on paper or a whiteboard, your work needs to be **scanned to a legible, black-and-white PDF**.
* All your work is to be submitted as a **single PDF** at the appropriate assignment area on Blackboard in the *Weekly Challenges* folder. Please do not submit multiple PDFs, or files that are not in PDF format.
:::
## Practice Exercises
**Practice Exercises are optional and for your benefit only.** You do not need to turn in work or answers unless you want feedback on your work.
**Predicates and quantifiers:**
1. Let $P(x)$ be the statement, $x^2 = x$. The domain is the set of all integers. State the truth values of the following:
- $P(0)$
- $P(1)$
- $P(2)$
- $P(-1)$
- $\exists x P(x)$
- $\forall x P(x)$
2. Let $M(x)$ be the predicate "$x$ has visited Michigan's Adventure" where the domain is the set of all students at GVSU. State each of the following in English, then give their truth values (or at least, what you *think* their truth values are):
- $\exists x M(x)$
- $\forall x M(x)$
- $\neg \exists x M(x)$
- $\neg \forall x M(x)$
**Sets and set notation:**
1. Use set-builder notation to give a description of each of these sets. There's more than one way to do each one.
- $\{0, 3, 6, 9, 12\}$
- $\{-3, -2, -1, 0, 1, 2, 3\}$
2. Write each of these sets in roster notation:
- $\{ x \in \mathbb{R} \, : \, x^2 = 1\}$
- $\{ x \in \mathbb{N} \, : \, x < 12\}$
- $\{ x \, \% \, 10 \, : \, x \in \mathbb{N}\}$
3. Determine whether the number $2$ is an element of each of the following sets:
- $\{x \in \mathbb{R} \, : \, x > 1\}$
- $\{x \in \mathbb{R} \, : \, x^2 \ \text{is an integer}\}$
- $\{2 ,\{2\}\}$
- $\{\{2\}, \{2, \{2\}\}\}$
5. Determine whether these statements are true, or whether they are false:
- $0 \in \emptyset$
- $\emptyset \in \{0\}$
- $\{0\} \subseteq \emptyset$
- $\emptyset \subseteq \{0\}$
- $\{0\} \subseteq \{0\}$
## Application/Extension Problems
1. We mentioned in the videos and in class that a predicate can be thought of as a tiny computer program, that accepts input of a certain type from the user and outputs only Boolean values --- that is, only `TRUE` or `FALSE`. That means we can use Python to study predicates and quantifiers, by writing them as Python functions. Some examples were given in the videos. Here are some more. Each one is called `P`, and the domain of each is the set of all integers (positive, negative, and zero). For each, determine if $\exists x P(x)$ is true or whether it is false; then give a valid explanation why. Then, do the same for $\forall x P(x)$. **Remember that the main focus of your work is the explanation.** Give an explanation on each answer that fully explains your reasoning.
```python=
# Refer to this as Problem 1(a).
def P(x):
return x**2 >= 0
```
```python=
# Refer to this as Problem 1(b).
def P(x):
return x**2 = 2
```
```python=
# Refer to this as Problem 1(c).
def P(x):
return (x**2 + 2) > 1
```
2. Now it's your turn to **write** some Python. Write Python code for predicates, like the ones above, that do the following.
- A predicate `P` that accepts integers as input and returns `TRUE` for all odd integers but `FALSE` for evens.
- A predicate `Q` that accepts integers as input returns `TRUE` if the input is an integer that is equal to 0 mod 2 but not equal to 0 mod 8; and returns `FALSE` otherwise.
- A predicate `R` that accepts strings as input and returns `TRUE` if the string has an odd number of characters.
3. Write a predicate `S`, as a Python function, that accepts a string as input, and then returns a Boolean based on some condition of your choice that involves the string. The predicate `R` in the previous question is an example; it looks at the length of the string and returns a Boolean based on the results. You can create any similar condition you want; but *you may not use the length of the string* this time because the previous question already did something like that. [This website](https://www.w3schools.com/python/python_ref_string.asp) contains a huge list of Python string methods that you can select from. Play with them, then write a predicate that involves one or more of them. **Then**: determine which of the following are true statements and give an explanation:
- $\forall x S(x)$
- $\exists x S(x)$
- $\forall x \neg S(x)$
- $\exists x \neg S(x)$
:::warning
**Rule for Python:** Whenever you submit Python code for grading, **it must execute without syntax errors. Code that throws a syntax error upon evaluation will result in an "Incomplete" mark *for the entire assignment.* It is your responsibility to run your code before submitting it and catch/debug all syntax errors.**
For example this code would produce a syntax error. Why?
```python=
def P(x)
return x = x**2
```
---
**How to submit Python code:** You can do this in several different ways for now. Eventually we'll narrow these down, but this time you can do any of these:
- Write up your code in a Jupyter notebook and submit it on Blackboard. *This is the preferred method* since the Jupyter notebook actually allows me to execute your code right in the document to check for errors. Some instructions for accessing Jupyter notebooks will be posted to Campuswire this week.
- Write up your code in a Jupyter notebook on Google Colab and submit the link to it, as you would a Google Doc. Instructions on this will be in the aforementioned Campuswire post.
- Write up your code in a text file and submit it on Blackboard.
- Write up your code in a single [GitHub Gist](https://gist.github.com/) and submit the link on Blackboard.
:::
## Feedback and Reflection
**From now on, you'll be getting the same questions every week for Weekly Challenges.** So you can be collecting your thoughts on these, all week.
1. What's at least one thing you did as a learner this week --- a study hack, a habit you started to build, a decision about when/where/how to study, etc. --- that you felt was particularly effective in helping you learn? (This doesn't have to be specifically for MTH 225 --- any example will do.)
2. What's at least one thing that happened this week, either something you did or something that happened to you, that kept you from learning as well as you could have? And, how will you try to remove or deal with that "blocker" this week?
3. State at least one particularly interesting thing you learned in the class this week, or one particularly sticky question you have from the class this week.

:::info Welcome to MTH 201! I'm Dr. Robert Talbert, Professor of Mathematics, and I am grateful that you are signed up for the course and am looking forward to working with you this semester. ::: What's MTH 201 all about? MTH 201 is a first course in Calculus, which is all about modeling and understanding change. Change is maybe the most important facet of the world around us, and we care about it more than we realize. For example, we care a lot about the number of Covid-19 cases in our community, but we might care even more about how fast the number of cases is changing (either up or down). In MTH 201, you'll learn the mathematical language of change and apply it to models that you build to draw conclusions, make predictions, and give meaningful answers to real problems. MTH 201 goes beyond just computation. In MTH 201, you'll build skills with understanding complex concepts, communicating those concepts and the meaning of your results to appropriate audiences, using professional tools to help you in your work, and practice working with others to improve your learning (and theirs). These are valuable skills no matter where you go next. Success in this course doesn't come easy, and you can expect to be pushed and stretched intellectually. But the struggle you experience is normal and healthy, a sign of growth and that you are doing things the right way. And you will receive tireless support from me and your classmates in the process. Above all, my top priority is to support you in your work and help you succeed.

11/11/2023Initial due date: Sunday, April 9 at 11:59pm ET Overview Our final miniproject reaches back into linear algebra to look at diagonalizable matrices and their uses in solving systems of differential equations. Prerequisites: You'll need to be able to solve basic systems of differential equations and find the eigenvalues and eigenvectors for a small matrix. You'll also need a basic comfort level with concepts of linear independence and matrix arithmetic from earlier in the course. Background This entire problem comes from Section 3.9.1 in your textbook. Here is a rephrased version of the introduction to that section.

3/29/2023Initial due date: Sunday, April 9 at 11:59pm ET Overview This miniproject will teach you about the Runge-Kutta method, a standard numerical solution technique for differential equations. Prerequisites: A strong grasp of Euler's Method for single DE's is needed. You will also need to be comfortable using a spreadsheet. Miniproject 6 (Euler's Method for systems) is also recommended. Background A description of the Runge-Kutta method along with an example is given in this tutorial. Read it carefully and make sure you can work along with the example before proceeding.

3/29/2023Initial due date: Sunday, April 9 at 11:59pm ET Overview This miniproject introduces a version of Euler's Method as a numerical solution technique for systems. Prerequisites: You will need to be comfortable with using Euler's method for single differential equations. You'll also benefit from some familiarity with spreadsheets or Python in order to automate the calculations. Background This tutorial gives you the background you need for this assignment. Please read it and make sure you understand the concepts and the example: https://github.com/RobertTalbert/linalg-diffeq/blob/main/assignments/Euler's_Method_for_Systems.ipynb

3/22/2023
Published on ** HackMD**

or

By clicking below, you agree to our terms of service.

Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet

Wallet
(
)

Connect another wallet
New to HackMD? Sign up