% If you are working from this template to just write up your own
% solutions, I'm trying to keep it simple for you and there are only a
% few places you need to edit. On line 43 there's a place where the
% phrase "YOUR NAME HERE" appears; change it to your actual
% name. Several places below there are places where the phrase "YOUR
% ANSWER HERE" appears, and directly below (or replacing) those lines
% are good places to put your answers.
%
% One important thing you need to do, however (due to the complicated
% way I use a single form to automatically produce both the question
% sheets and solution writeups) is to make sure that you keep the word
% 'solution' in your filename, or else your answers won't be printed
% at all.
\documentclass[12pt]{article}

\usepackage[margin=0.7in,dvips]{geometry}
\usepackage{fancyhdr,lastpage}
\usepackage{amsmath,amsfonts}
\usepackage{tikz}
\usepackage{substr}

\IfSubStringInString{\detokenize{solution}}{\jobname}{%
  % Solutions
  \newcommand\qfill{}
  \newcommand\qpage{}
  \newcommand\qonly[1]{}
  \newcommand\answer[1]{#1}
  \newcommand\question[1]{{\em #1}}
  \newcommand\rubric[1]{}
}
{%
  % Question sheets
  \newcommand\qfill{\vfill}
  \newcommand\qpage{\newpage}
  \newcommand\qonly[1]{#1}
  \newcommand\answer[1]{}
  \newcommand\question[1]{#1}
  \newcommand\rubric[1]{}
}

\pagestyle{fancy}
\lhead{MATH 311-02}
\chead{Problem Set \#1\answer{ solutions}}
\rhead{\answer{YOUR NAME HERE}}
\lfoot{}
\cfoot{Page \thepage\ of \pageref{LastPage}}
\rfoot{{\bf due January 26, 2017}}

\begin{document}
\begin{enumerate}
\item \question{The following questions build towards a future proof
    technique.}
  \begin{enumerate}
  \item \question{Write a complete proof of the following statement:
      if $n$ is an even integer, then $3n^2+n-5$ is odd.}
    
    \answer{
    }
    
  \item \question{Write a complete proof of the following statement:
      if $n$ is an odd integer, then $3n^2+n-5$ is odd.}
    
    \answer{
      YOUR ANSWER HERE
    }
    
  \item \question{What true statement would adequately combine the two
      results above?}
    
    \answer{
      YOUR ANSWER HERE
    }
    
  \end{enumerate}

\item \question{In preparation for the next few questions, recall that
    the logical implication operator can be defined entirely in terms
    of disjunctions and negations: $P\rightarrow Q\equiv\neg P\vee
    Q$. In fact, \emph{any} logical expression you might wish can be
    built using conjunctions, disjunctions, and negations. For
    instance, consider the mysterious function of P, Q, and R with the truth
    table given below:
    \begin{center}
      \begin{tabular}{|c|c|c||c|}\hline
        $P$&$Q$&$R$&$f(P,Q,R)$\\\hline\hline
        F&F&F&F\\\hline
        F&F&T&F\\\hline
        F&T&F&T\\\hline
        F&T&T&F\\\hline
        T&F&F&T\\\hline
        T&F&T&T\\\hline
        T&T&F&F\\\hline
        T&T&T&F\\\hline
      \end{tabular}
    \end{center}
    We could write that simply as a disjunction of 3 conjunctions
    corresponding to each of the places where it's true, so
    \[f(P,Q,R)\equiv(\neg P\wedge Q\wedge \neg R)\vee(P\wedge\neg
      Q\wedge\neg R)\vee(P\wedge\neg Q\wedge R)\] This is not the most
    efficient way to do this, but it's an easy way to demonstrate that
    conjunctions, disjunctions, and negations are all you will ever
    truly need to write a logical expression. The following questions
    address the possibility that you might not even need all three of
    these operations.}

  \begin{enumerate}
  \item \question{Is it possible to write the conjunction operation
      ($P\wedge Q$) entirely in terms of disjunctions and negations?
      Either show how or explain why not.}

    \answer{
      YOUR ANSWER HERE
    }
    
  \item \question{Is it possible to write the disjunction operation
      ($P\vee Q$) entirely in terms of conjunctions and negations?
      Either show how or explain why not.}

    \answer{
      YOUR ANSWER HERE
    }
    
  \item \question{Is it possible to write the negation operation
      ($\neg P$) entirely in terms of conjunctions and disjunctions?
      Either show how or explain why not.}

    \answer{
      YOUR ANSWER HERE
    }

  \item \question{\textbf{BONUS:} It is impossible to write every
      single possible logical statement in terms of only \emph{one} of
      the standard operations (negations, conjunctions, disjunctions,
      or implications). However, if we consider nonstandard binary
      operations, there are 16 different possible ways to fill in a
      truth table, and maybe one of them will suffice. Note that these
      16 ways include some pretty silly operations like ``always
      result in true'' or ``negate the left operand and ignore the
      right'', but maybe some of the others will work. Below, show a
      truth table for some nonstandard operation $\otimes$, and show
      how conjunction, disjunction, and negation could all be
      rewritten in terms of $\otimes$.}

    \answer{
      % In the truth table below, replace each "?" with a "T" or "F"
      % to describe whatever novel operation you choose.
      \begin{tabular}{|c|c||c|}\hline
        $P$&$Q$&$P\otimes Q$\\\hline\hline
        F&F&?\\\hline
        F&T&?\\\hline
        T&F&?\\\hline
        T&T&?\\\hline
      \end{tabular}

      YOUR ANSWER HERE
    }
  \end{enumerate}
  
\end{enumerate}

\end{document}
