\documentclass[12pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[letterpaper]{geometry}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{mathrsfs}
\usepackage{amsthm}
\usepackage{amssymb}
\usepackage{color}
\setlength{\topmargin}{-0.3 true in}
\setlength{\headsep}{0 true in}
\setlength{\topskip}{0 true in}
\setlength{\textwidth}{6.5 true in}
\setlength{\oddsidemargin}{0 true in}
\setlength{\evensidemargin}{0 true in}
\setlength{\textheight}{9.2 true in}
\renewcommand{\arraystretch}{1.2}
\newcommand{\eps}{\varepsilon}
\newcommand{\R}{{\mathbb R}}
\newcommand{\N}{{\mathbb N}}
\newcommand{\Q}{{\mathbb Q}}
\newcommand{\Z}{{\mathbb Z}}
\theoremstyle{definition}
\newtheorem{problem}{Problem}
\definecolor{darkblue}{RGB}{0,0,150}
\definecolor{darkred}{RGB}{180,0,0}
\definecolor{darkgreen}{RGB}{0,120,0}
\newenvironment{answer}{\par\medskip\bgroup\color{darkblue}}{\egroup\par\medskip}
\newenvironment{grading}{\bgroup\color{darkred}}{\egroup}
\newenvironment{secondans}{\bgroup\color{darkgreen}}{\egroup}
\pagestyle{empty}


\begin{document}

\hbox to \hsize{\textbf{Math 331\hfill Homework 5}}
\nointerlineskip
\vskip 2pt
\hrule height 1pt

\medskip

\centerline{\textit{This homework on Metric Spaces, Section 1, is due by 11:59 PM on Saturday, October 3.}}
\centerline{\textit{Remember that there is a test on Monday, October 5.}}

\bigskip

\def\ds{\displaystyle}


\begin{problem}  % problem 1
Show that $[0,1)$ is neither open nor closed in $\R$ (with its usual metric).
\end{problem}

\begin{answer}
%You can put your answer here for problem 1, 2 points
\end{answer}




\begin{problem}
Let $(M,d)$ be a metric space, and let $x\in M.$  Show that the set
$\{x\}$ is closed in $(M,d)$ by showing that its complement, $M\smallsetminus\{x\}$,
is open.  Conclude that any finite subset of a metric space is closed.
[Hint for the second part:  use Theorem 1.3.]
\end{problem}

\begin{answer}
%You can put your answer here for problem 2, 3 points
\end{answer}




\begin{problem} % problem 3
Find an infinite collection of closed subsets in the metric space $\R$ (with its usual metric), whose
union is not closed.  (We have already seen that $\{[-1-\frac{1}{n},1+\frac{1}{n}]\,|\,n\in\N\}$ is
an infinite collection of open sets whose intersection is not open.  That showed that the 
finiteness condition is required in Theorem 1.2, part~3.  Your answer for this problem shows that the
finiteness condition is required in Theorem 1.3, part~2.)
\end{problem}

\begin{answer}
%You can put your answer here for problem 3, 2 points
\end{answer}




\begin{problem}
Let $X$ be any non-empty set, and define $\delta\colon X\times X\to \R$ by $\delta(a,b) = 
\begin{cases} 0&\text{if }a=b\\ 1&\text{if }a\not=b\end{cases}.$
Show that $\delta$ is a metric for $X.$  It is called the \textbf{discrete metric}
on $X.$  Show that \textbf{every} subset of $X$ is open in the metric space $(X,\delta).$
[Hint: What is $B_{1/2}^\delta(x)$?]
\end{problem}

\begin{answer}
%You can put your answer here for problem 4, 4 points
\end{answer}




\begin{problem}
Let $X$ be any non-empty, bounded subset of $\R$, and let $\lambda$ be the least upper bound
of $X$.  Show that $\lambda\in\overline{X}$.  That is, the least upper bound of $X$ is an
element of the closure of $X$.  [Hint:  By definition, $\overline{X}$ is the union of $X$ with
the set of all accumulation points of $X$, so consider the cases $\lambda\in X$ and
$\lambda \notin X$.]
\end{problem}

\begin{answer}
%You can put your answer here for problem 5, 3 points
\end{answer}




\begin{problem}
Consider the set $\mathscr C([a,b],\R),$ the set of continuous, real-valued 
functions on the closed, bounded interval $[a,b].$  Define a metric $\sigma$
on this set by $$\sigma(f,g) = \int_a^b|f(x)-g(x)|\,dx$$
Show that $\sigma$ is in fact a metric.  (You will need some facts from Calculus about integrals, and
you will need the  triangle inequality for the standard metric on $\R$.)
For a given $f\in \mathscr C([a,b],\R)$ and $\varepsilon>0,$
try to describe what it means for a function $g$ to be in $B_\varepsilon^\sigma(f).$
(Draw some pictures!)
\end{problem}

\begin{answer}
%You can put your answer here for problem 6, 4 points
\end{answer}



\end{document}
