Warning: this is an htmlized version!
The original is here, and
the conversion rules are here.
% (find-LATEX "2024panic-at-equalities.tex")
% (defun c () (interactive) (find-LATEXsh "lualatex -record 2024panic-at-equalities.tex" :end))
% (defun C () (interactive) (find-LATEXSH "lualatex 2024panic-at-equalities.tex" "Success!!!"))
% (defun D () (interactive) (find-pdf-page      "~/LATEX/2024panic-at-equalities.pdf"))
% (defun d () (interactive) (find-pdftools-page "~/LATEX/2024panic-at-equalities.pdf"))
% (defun e () (interactive) (find-LATEX "2024panic-at-equalities.tex"))
% (defun u () (interactive) (find-latex-upload-links "2024panic-at-equalities"))
% (defun v () (interactive) (find-2a '(e) '(d)))
% (defun cv () (interactive) (C) (ee-kill-this-buffer) (v) (g))
% (defun d0 () (interactive) (find-ebuffer "2024panic-at-equalities.pdf"))
%          (code-eec-LATEX "2024panic-at-equalities")
% (find-pdf-page   "~/LATEX/2024panic-at-equalities.pdf")
% (find-pdf-text   "~/LATEX/2024panic-at-equalities.pdf")
% (find-sh0 "cp -v  ~/LATEX/2024panic-at-equalities.pdf /tmp/")
% (find-sh0 "cp -v  ~/LATEX/2024panic-at-equalities.pdf /tmp/pen/")
%   file:///home/edrx/LATEX/2024panic-at-equalities.pdf
%               file:///tmp/2024panic-at-equalities.pdf
%           file:///tmp/pen/2024panic-at-equalities.pdf
%  http://anggtwu.net/LATEX/2024panic-at-equalities.pdf
% (find-LATEX "2019.mk")
% (find-lualatex-links "2024panic-at-equalities" "pae")

% «.title»			(to "title")
% «.abstract»			(to "abstract")
% «.first-story»		(to "first-story")
% «.second-story»		(to "second-story")
% «.third-story»		(to "third-story")
% «.the-output-of»		(to "the-output-of")
% «.shapes»			(to "shapes")
% «.underbraces»		(to "underbraces")
% «.avoiding-pathological»	(to "avoiding-pathological")
% «.maxima»			(to "maxima")
% «.formal-calculations»	(to "formal-calculations")
% «.lean»			(to "lean")
% «.several-readers»		(to "several-readers")
% «.trees»			(to "trees")
% «.here-compsci»		(to "here-compsci")
% «.subst-steps»		(to "subst-steps")
% «.debugability»		(to "debugability")
% «.names»			(to "names")
% «.set-comprehensions»		(to "set-comprehensions")
% «.a-game»			(to "a-game")
% «.colleagues»			(to "colleagues")

\documentclass[oneside,12pt]{article}
\usepackage[colorlinks,citecolor=DarkRed,urlcolor=DarkRed]{hyperref} % (find-es "tex" "hyperref")
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{pict2e}
\usepackage[x11names,svgnames]{xcolor} % (find-es "tex" "xcolor")
\usepackage{colorweb}                  % (find-es "tex" "colorweb")
%\usepackage{tikz}
%
% (find-dn6 "preamble6.lua" "preamble0")
%\usepackage{proof}   % For derivation trees ("%:" lines)
\input diagxy         % For 2D diagrams ("%D" lines)
%\xyoption{curve}     % For the ".curve=" feature in 2D diagrams
%
\usepackage{edrx21}               % (find-LATEX "edrx21.sty")
\input edrxaccents.tex            % (find-LATEX "edrxaccents.tex")
\input edrx21chars.tex            % (find-LATEX "edrx21chars.tex")
\input edrxheadfoot.tex           % (find-LATEX "edrxheadfoot.tex")
\input edrxgac2.tex               % (find-LATEX "edrxgac2.tex")
%\input 2017planar-has-defs.tex    % (find-LATEX "2017planar-has-defs.tex")
%
\usepackage[backend=biber,
   style=alphabetic]{biblatex}    % (find-es "tex" "biber")
\addbibresource{catsem-ab.bib}    % (find-LATEX "catsem-ab.bib")
%
% (find-es "tex" "geometry")
\begin{document}

\catcode`\^^J=10
\directlua{dofile "dednat6load.lua"}  % (find-LATEX "dednat6load.lua")

% %L dofile "edrxtikz.lua"  -- (find-LATEX "edrxtikz.lua")
% %L dofile "edrxpict.lua"  -- (find-LATEX "edrxpict.lua")
% \pu

% (find-angg "LUA/Verbatim3.lua" "dednat6")
% (find-Deps1-cps "Verbatim3")
%L dofile "Verbatim3.lua"            -- (find-LATEX "Verbatim3.lua")
\pu

\def\DER#1#2{\pmat{\ddx#1=\\#2}}
\def\myfparbox#1#2{\fbox{\parbox{#1}{#2}}}



%  _____ _ _   _      
% |_   _(_) |_| | ___ 
%   | | | | __| |/ _ \
%   | | | | |_| |  __/
%   |_| |_|\__|_|\___|
%                     
% «title»  (to ".title")
% (paep 1 "title")
% (paea   "title")
% (misp 1 "title")
% (misa   "title")

\title{Panic! At Equalities}

\author{%
  Eduardo Ochs%
  %{\large Eduardo Ochs}%
  \thanks{eduardoochs@gmail.com}\\
  %{\small UFF, Rio das Ostras, RJ, Brasil}\\
  }

\maketitle

% (find-LATEX "2022on-the-missing.tex" "abstract")

%     _    _         _                  _   
%    / \  | |__  ___| |_ _ __ __ _  ___| |_ 
%   / _ \ | '_ \/ __| __| '__/ _` |/ __| __|
%  / ___ \| |_) \__ \ |_| | | (_| | (__| |_ 
% /_/   \_\_.__/|___/\__|_|  \__,_|\___|\__|
%                                           
% «abstract»  (to ".abstract")
% (misp 1 "abstract")
% (misa   "abstract")

\begin{abstract}

  % I teach Calculus 2 and 3 in a place in Brazil --- a second-line
  % campus of a big federal university --- that admits many students

  These notes show how to apply some ideas from the paper ``On the
  Missing Diagrams in Category Theory'' (\cite{OchsMis1}) to
  integration.

  More precisely: a) I teach Calculus 2 and 3 in a place that admits
  students who know very little maths, b) the students are arriving in
  Calculus 2 without any of the prerequisites for understanding what
  are ``series of equalities in which each step is easy to justify'',
  3) in heavy-handed Computer Science terminology the main
  prerequisite is a substitution operator called `$[:=]$', and
  ``justifications for equalities'' are the things that appear after
  the `\textsf{by}' in calculational proofs in Lean. The students in
  items (a) and (b) are ``children'' in the sense defined in the
  introduction of \cite{OchsMis1} --- they need to start from
  motivating examples, and only then generalize --- but they have very
  little practice with variables; one of the key ideas here is that we
  can take many of these ``motivating examples'' from Maxima.

\end{abstract}



% «first-story»  (to ".first-story")
\section{A first story}
\label{first-story}

Let's start with this,
%
$$\fbox{\parbox{8cm}{

  We know that
  %
  $$a+b=b+a.$$

  If we substitute all ocurrences of $a$ by 42 in
  that equality we get:
  %
  $$42+b=b+42.$$

}}
$$

...and call it our ``First Example''. Now let's replace its last line
by a blank,
%
$$\fbox{\parbox{8cm}{

  We know that
  %
  $$a+b=b+a.$$

  If we substitute all ocurrences of $a$ by 42 in
  that equality we get:
  %
  $$\_\_\_\_\_\_\_\_\_\_$$

}}
$$

and call that our ``First Question''. One day in 2023 I asked the
First Question to my students (see sec.\ref{who-students} for who they
are) and they froze --- they knew that the answer had to be {\it
  either} `$42+b$' or
`$b+42$', but they couldn't decide which... then I said that ``no, no,
no, it's $42+b=b+42$!!!'' --- and they panicked, because

\begin{itemize}

\item for them $42+b$ and $b+42$ were just two ways of
writing the same number,

\item they thought that they couldn't write $42+b=b+42$ ``because it's
  too obvious'',

\item if for me `$42+b$', `$b+42$' and `$42+b=b+42$' were three
  different things then they were in a class in which the `$=$' sign
  would be used in a way that was totally new to the them.

\end{itemize}

I panicked, too --- all the material that I had prepared for that
course supposed that the students knew how to handle {\it
  expressions}, and `$42+b$', `$b+42$' are `$42+b=b+42$' are
``obviously'' very different when regarded as expressions... What
could I do?



% «second-story»  (to ".second-story")
\section{A second story}
\label{second-story}

% 2hT65: (c2m232tnp 2 "as-perguntas")
%        (c2m232tna   "as-perguntas")

Our Calculus 2 (``C2'') is mostly about integration, with a bit of
differential equations at the end. Our Calculus 1 (``C1'') is mostly
about limits and differentiation, and in C2 we can suppose that the
students know how to calculate derivatives very well --- because they
had to calculate lots of horrible derivatives to pass the tests in C1.

I've never taught C1.

\msk

So, I was trying to teach integration in C2, and I saw that the
students were having much more difficulty than I expected in the
exercises that involved the chain rule. I had an idea --- an
hypothesis for where the problem could be --- and I decided to test
it. I asked them to spend the last 15 minutes of that class trying to
calculate this,
%
$$\ddx \,f(\sin(x^4) + \ln x)$$
%
and to hand me all their notes; I would analyze what they wrote and
would prepare material to let us work on their difficulties.

The result was much worse than just ``no one of the students got the
right answer''... no one of them had any idea of how to handle the
`$f$', and some of them told me later that they thought that the `$f$'
was ``{\it just notation}''.


% «third-story»  (to ".third-story")
\section{A third story}
\label{third-story}

Some days later I discovered that {\sl some} of the students knew that
if $f(u)=\sin u$ and $g(x)=42x$ then we have this,
%
$$f(g(x)) = \sin 42x$$
%
but practically no one was able to substitute only one of the
functions, like this:
%
$$\begin{array}{llll}
  \text{if} & g(x)=42x    & \text{then} & f(g(x))=f(42x), \\
  \text{if} & f(u)=\sin u & \text{then} & f(g(x))=\sin g(x). \\
  \end{array}
$$




% «here-compsci»  (to ".here-compsci")
\section{Here a computer scientist}
\label{here-compsci}

Here a computer scientist could say: {\sl the problem with these
  students is that they don't know substitution well enough}. And we
would show to the students that there is a nice mathematical notation
for this,
%
\begin{quote}
  If we substitute all occurrences of $a$ by $x^2$ and all occurrences
  of $b$ by $y^3$ in the expression $a+b=b+a$ we obtain this other
  expression: $x^2+y^3=y^3+x^2$
\end{quote}
%
that is:
%
$$\def\P#1{\left(#1\right)}
  \pmat{a+b=b+a} \bmat{a:=x^2 \\ b:=y^3} = \pmat{x^2+y^3=y^3+x^2}
$$
%
note that this is:
%
$$\pmat{\text{old expression}}
  \bmat{\text{substitutions}}
  =
  \pmat{\text{new expression}}
$$
%
{\sl ...so the students already know substituition! They just need to
  learn this notation --- and then we can show them how to define
  substitution recursively, and they will understand that this is a
  purely syntactical operation, and that this is true,}
%
$$(x + 2 = 5) [x := 4] = (4 + 2 = 5)$$
%
{\sl but this is not:}
%
$$(x + 2 = 5) [x := 4] = (6 = 5)$$

{\sl With this operation we can, for example, test possible solutions
  for equations:}
%
% 2cT17: (c2m211substp 5 "testar-hipoteses")
%        (c2m211substa   "testar-hipoteses")
%
$$\begin{array}{rcl}
  (x + 2 = 5) [x := 4] &=& (4 + 2 = 5) \\
                       &=& (6 = 5) \\
                       &=& \mathsf{False} \\
  \end{array}
$$

Ok, but my students were very bad with variables and definitions --- a
recursive definition would be too much for them. How to handle that?
My current best solution uses examples from Prog 1
(sec.\ref{the-output-of}), examples from Maxima (sec.\ref{maxima}),
trees (sec.\ref{trees}), avoiding pathological cases
(sec.\ref{avoiding-pathological}), and writing for a reader who finds
the operation `$[:=]$' difficult (sec.\ref{several-readers}).


% Nederpelt
% Bound variables

% You are writing for people who don't know the [:=] very well

%  _____ _                        _               _            __ 
% |_   _| |__   ___    ___  _   _| |_ _ __  _   _| |_    ___  / _|
%   | | | '_ \ / _ \  / _ \| | | | __| '_ \| | | | __|  / _ \| |_ 
%   | | | | | |  __/ | (_) | |_| | |_| |_) | |_| | |_  | (_) |  _|
%   |_| |_| |_|\___|  \___/ \__,_|\__| .__/ \__,_|\__|  \___/|_|  
%                                    |_|                          
%
% «the-output-of»  (to ".the-output-of")
\section{The output of}
\label{the-output-of}

In theory all the students in C2 have completed Prog 1, that is a
basic course in programming, using C --- and this means that I can use
some basic examples from programming. For example:

%V #include <stdio.h>
%V int main() {
%V   printf("2+3=6\n");
%V }
%L defvbt "prog A"
\pu
%V 2+3=6
%L defvbt "prog A out"
\pu

$$\myfparbox{8cm}{
    The output of:
    $$\vbt{prog A}$$
    is:
    $$\vbt{prog A out}$$
  }
$$
%
and I can also tell them to imagine the simplest function possible
that replaces characters in a string. It should behave like this:
%
%V replace('a', 'o', "Banana");
%L defvbt "prog B"
\pu
%V Bonono
%L defvbt "prog B out"
\pu
%
$$\myfparbox{8cm}{
    The output of:
    $$\vbt{prog B}$$
    is:
    $$\vbt{prog B out}$$
  }
$$

If its definition is ``as simple as possible'' then we should have
this,
%
%V replace('a', 'o', "Binini");
%L defvbt "prog C"
\pu
%V Binini
%L defvbt "prog C out"
\pu
%
$$\myfparbox{8cm}{
    The output of:
    $$\vbt{prog C}$$
    is:
    $$\vbt{prog C out}$$
  }
$$
%
instead of an error like ``I can't replace all `a's by `o's in
``Binini'' because ``Binini'' doesn't have any `a's''.

Also,

\begin{itemize}

\item the students understand that the output of a program can be
  ``\textsf{Syntax error}'', and that compilers understand a
  predefined language --- specified in BNF in the appendix of the
  textbook that they used in Prog 1. {\sl That specification may be
    too hard for us to understand, but it exists, can be written down,
    and the compiler follows it strictly;}

\item compilers they don't try very hard to understand what the users
  ``mean'', and they don't care if a program is ``too obvious'' (see
  sec.\ref{first-story}),

\item in C2 we will have to play several roles (see
  sec.\ref{several-readers}), and in some of them we will pretend that
  we are computers, and we will sometimes answer ``\textsf{Syntax
    error}'',

\item all the programs that the students see in Prog 1 are
  deterministic. With this, and with enough examples, the students can
  understand that the output of the program that performs this
  substitution
  %
  $$(2+a=6)[a:=3]$$
  %
  is $(2+3=6)$ --- {\sl and it can't be anything else}.

\end{itemize}



%  ____  _                           
% / ___|| |__   __ _ _ __   ___  ___ 
% \___ \| '_ \ / _` | '_ \ / _ \/ __|
%  ___) | | | | (_| | |_) |  __/\__ \
% |____/|_| |_|\__,_| .__/ \___||___/
%                   |_|              
%
% «shapes»  (to ".shapes")
\section{Shapes}
\label{shapes}

% (find-books "__analysis/__analysis.el" "apex-calculus")
% (find-books "__analysis/__analysis.el" "apex-calculus" "100" "2.5 The Chain Rule")
% (find-books "__analysis/__analysis.el" "cederj")
% (find-books "__analysis/__analysis.el" "cederj" "113" "12. A regra da cadeia")
% (find-cederjc1v1page (+ 1 117)   "Exemplo 12.6")

Many students learn this style in C1 ([CEDERJ], p.117, first lines of
Example 12.6, my translation):
%
\begin{quote}
  Let $f(x)=\sin(\cos x)$ for all $x∈\R$. Then $f$ is derivable in
  $\R$ and $f'(x)=(-\sin x)\cos(\cos x)$ for all $x∈\R$.
\end{quote}

When they arrive in C2 they only remember it vaguely, and they do
things like this:
%
\begin{quote}
  Let $f(x)=\sin(42x)$ for all $x∈\R$. Then $f$ is derivable in
  $\R$ and $f'(x)=\cos(42x)$ for all $x∈\R$.
\end{quote}

That style is a nightmare to debug. It is better to convince them ---
or force them --- to use this style,
%
\sa{[CR]}{[CR]}
\sa{(CR1)}{\DER{f(g(x))}{f'(g(x))g'(x)}}
\sa{(CR2)}{\DER{\sin(42x)}{\cos(42x)·42}}
\sa{subst1}{\bsm{ f(u):=\sin u \\ g(x):=42x }}
\sa{subst2}{\bsm{ f(u):=\sin u \\ f'(u):=\cos u \\ g(x):=42x \\ g'(x)=42 }}
\sa{just1}{\text{by $\ga{[CR]}$}}
\sa{just2}{\text{i.e., by $\ga{[CR]}\ga{subst1}$}}
\sa{just3}{\text{i.e., by $\ga{[CR]}\ga{subst2}$}}
\sa{just4}{\text{i.e., by $\ga{(CR1)}\ga{subst2}$}}
\sa{just5}{\text{i.e., by $\ga{(CR2)}$}}
%
$$\begin{array}{rcll}
  \ddx(99\sin(42x)) &=& 99 \; \ddx(\sin(42x)) \\
                    &=& 99·42\cos(42x)        \\
  \end{array}
$$
%
in which the `$=$'s are aligned vertically and we can add
justifications at the right, like this:
%
$$\begin{array}{rcll}
  \ddx(99\sin(42x)) &=& 99 \; \ddx(\sin(42x)) \;\;\; & \text{by \ga{[CMR]}} \\
                    &=& 99·42\cos(42x)        \;\;\; & \text{by \ga{[CR]}} \\
  \end{array}
$$
%
where \ga{[CMR]} is the ``Constant Multiple Rule'' and \ga{[CR]} is
the Chain Rule.

When we have a single equality it is easy to take something like this,
in which we start with a justification that is very brief and then
expand it several times,
%
$$\begin{array}{rcll}
  \ddx(99\sin(42x)) &=& 99·42\cos(42x) \;\;\;
                                  & \ga{just1} \\
                                &&& \ga{just2} \\
                                &&& \ga{just3} \\
                                &&& \ga{just4} \\
                                &&& \ga{just5} \\
  \end{array}
$$
%
and represent it as a tree...

(Draw the tree)

(Mention decorations)

(Mention the rule CD and directed graphs)

% (misp 9 "the-conventions")
% (misa   "the-conventions")
% (misa   "the-conventions" "(CD)")


% «underbraces»  (to ".underbraces")
\section{Other decorations: underbraces}
\label{underbraces}

% 2hT13: (c2m232introp 12 "sobre-portugues")
%        (c2m232introa    "sobre-portugues")

  $$\def\und#1#2{\underbrace{#1}_{#2}}
    \def\setdepthto#1#2{\setbox1\hbox{$#2$}%
                        \dp1=#1%
                        \box1}
    \def\X   {\setdepthto{2pt}{x}}
    \def\Y   {\setdepthto{2pt}{y}}
    \def\X   {\mathstrut x}
    \def\Y   {\mathstrut y}
    \def\XSQ {\und{{{\und{\X}{3}}^2}}{9}}
    \def\YSQ {\und{{{\und{\Y}{4}}^2}}{16}}
    \def\XYSQ{\und{\XSQ+\YSQ}{25} \mathstrut}
    \def\LIN {\setdepthto{2pt}{\XYSQ}}
    \def\LOUT{\und{\setdepthto{50pt}{\sqrt{\LIN}}}{5}}
    \def\ROUT{\und{3+4 \mathstrut}{7}}
    \und{\LOUT \;=\; \ROUT}{\False}
  $$

% 2hT33: (c2m232carrop 10 "algumas-propriedades")
%        (c2m232carroa    "algumas-propriedades")
% 2hT74: (c2m232mvp 8 "mais-anotacoes")
%        (c2m232mva   "mais-anotacoes")

% «avoiding-pathological»  (to ".avoiding-pathological")
\section{Avoiding pathological cases}
\label{avoiding-pathological}

$$\Bigl(f(g(x))\Bigr)
  \bmat{f(x):=g(g(x)) \\ g(x):=f(f(x))}
  = \Bigl(g(g(f(f(x))))\Bigr)
$$

% «maxima»  (to ".maxima")
\section{Maxima}
\label{maxima}

% (find-es "maxima" "luatree-rd")

simplification vs evaluation

tricky to turn off simplification: see luatree-rd

Strang p.1

Pathological cases

% (c2m241introp 4 "strang-p1")
% (c2m241introa   "strang-p1")


% «formal-calculations»  (to ".formal-calculations")
\section{Formal calculations: monkey}
\label{formal-calculations}

Mathologer: video

Derivation in several steps

Continuity as decorations



% «lean»  (to ".lean")
\section{Lean}
\label{lean}

% (find-angg ".emacs.papers" "tpinlean" "42" "4.3 Calculational Proofs")
% (find-tpinleanpage (+ 6 42) "4.3 Calculational Proofs")
% (find-tpinleantext (+ 6 42)     "Calculational Proofs" "by   rw   h1")

%V theorem    T : a = e :=
%V calc
%V   a        =   b        :   by   rw   h1
%V     ...    =   c + 1    :   by   rw   h2
%V     ...    =   d + 1    :   by   rw   h3
%V     ...    =   1 + d    :   by   rw   add_comm
%V     ...    =     e      :   by   rw   h4
%L defvbt "Lean"
\pu

$$\vbt{Lean}$$


% «several-readers»  (to ".several-readers")
\section{Several readers}
\label{several-readers}

% 2hT4: (c2m232introp 3 "releia-a-dica-7")
%       (c2m232introa   "releia-a-dica-7")

Dica 7

Write for a reader who doesn't know `$[:=]$' well

(My previous approach failed miserably)

\newpage

% «trees»  (to ".trees")
% (paep 7 "trees")
% (paea   "trees")
\section{Trees}
\label{trees}

% (find-es "maxima" "luatree-rd")
% (find-es "maxima" "luatree")
% (find-es "sympy" "luatree")

% https://en.wikipedia.org/wiki/Binary_expression_tree#Algebraic_expressions
% https://commons.wikimedia.org/wiki/File:Exp-tree-ex-12.svg

$$\Intx{a}{b}{f'(g(u))g'(u)} = \Intu{g(a)}{g(b)}{f'(u)}$$

%V =___________________.
%V |                   |
%V integrate__.__.__.  integrate__.__.__.
%V |          |  |  |  |          |  |  |
%V *___.      x  a  b  fp         u  g  g
%V |   |               |             |  |
%V fp  gp              u             a  b
%V |   |
%V g   x
%V |
%V x
%L defvbt "MV2 maxima"
\pu
%
$$\vbt{MV2 maxima}$$

%V Equality_______________.
%V |                      |
%V Integral__.            Integral__.
%V |         |            |         |
%V Mul__.    Tuple__.__.  fp        Tuple__.__.
%V |    |    |      |  |  |         |      |  |
%V fp   gp   x      a  b  u         u      g  g
%V |    |                                  |  |
%V g    x                                  a  b
%V |
%V x
%L defvbt "MV2 sympy"
\pu
%
$$\vbt{MV2 sympy}$$








% (find-es "tex" "minipage")


\newpage

% «subst-steps»  (to ".subst-steps")
\section{Substitution in steps}
\label{subst-steps}

%D diagram diamond-1
%D 2Dx     100 +40 +40
%D 2D  100     A1
%D 2D
%D 2D  +30 L1      R1
%D 2D
%D 2D  +30     B1
%D 2D
%D ren L1 ==> (a+b=b+a)
%D ren A1 ==> (42+b=b+42)
%D ren B1 ==> (a+99=99+a)
%D ren R1 ==> (42+99=99+42)
%D
%D (( L1 A1 -> .plabel= a [a:=42]
%D    A1 R1 -> .plabel= a [b:=99]
%D    L1 R1 -> .plabel= a \bsm{a:=42\\b:=99}
%D    L1 B1 -> .plabel= b [b:=99]
%D    B1 R1 -> .plabel= b [a:=42]
%D ))
%D enddiagram
%D
$$\pu
  \diag{diamond-1}
$$

%D diagram diamond-2
%D 2Dx     100 +40 +40
%D 2D  100     A1
%D 2D
%D 2D  +30 L1      R1
%D 2D
%D 2D  +30     B1
%D 2D
%D ren L1 ==> f(g(x))
%D ren A1 ==> \sin(g(x))
%D ren B1 ==> f(42x)
%D ren R1 ==> \sin(42x)
%D
%D (( L1 A1 -> .plabel= a [f(u):=\sin(u)]
%D    A1 R1 -> .plabel= a [g(x):=42x]
%D    L1 R1 -> .plabel= m \bsm{f(u):=\sin(u)\\g(x):=42x}
%D    L1 B1 -> .plabel= b [g(x):=42x]
%D    B1 R1 -> .plabel= b [f(u):=\sin(u)]
%D ))
%D enddiagram
%D
$$\pu
  \diag{diamond-2}
$$


%D diagram diamond-3
%D 2Dx     100 +60 +60
%D 2D  100     A1
%D 2D
%D 2D  +50 L1      R1
%D 2D
%D 2D  +50     B1
%D 2D
%D ren L1 ==> \DER{f(g(x))}{f'(g(x))g'(x)}
%D ren A1 ==> \DER{\sin(g(x))}{\cos(g(x))g'(x)}
%D ren B1 ==> \DER{f(42x)}{f'(42x)·42}
%D ren R1 ==> \DER{\sin(42x)}{\cos(42x)·42}
%D
%D (( L1 A1 -> .plabel= a \bsm{f(u):=\sin(u)\\f'(u):=\cos(u)}
%D    A1 R1 -> .plabel= a \bsm{g(x):=42x\\g'(x):=42}
%D    L1 R1 -> .plabel= m \bsm{f(u):=\sin(u)\\g(x):=42x\\f'(u):=\cos(u)\\g'(x):=42}
%D    L1 B1 -> .plabel= b \bsm{g(x):=42x\\g'(x):=42}
%D    B1 R1 -> .plabel= b \bsm{f(u):=\sin(u)\\f'(u):=\cos(u)}
%D ))
%D enddiagram
%D
$$\pu
  \diag{diamond-3}
$$

% Fix this:
% 
% %D diagram diamond-3-minus
% %D 2Dx     100 +60 +60
% %D 2D  100     A1
% %D 2D
% %D 2D  +50 L1      R1
% %D 2D
% %D 2D  +50     B1
% %D 2D
% %D ren L1 ==> \DER{f(g(x))}{f'(g(x))g'(x)}
% %D ren A1 ==> \DER{\sin(g(x))}{f'(g(x))g'(x)}
% %D ren B1 ==> \DER{f(42x)}{f'(42x)g'(x)}
% %D ren R1 ==> \DER{\sin(42x)}{f'(42x)g'(x)}
% %D
% %D (( L1 A1 -> .plabel= a \bsm{f(u):=\sin(u)}
% %D    A1 R1 -> .plabel= a \bsm{g(x):=42x}
% %D    L1 R1 -> .plabel= m \bsm{f(u):=\sin(u)\\g(x):=42x}
% %D    L1 B1 -> .plabel= b \bsm{g(x):=42x\\g'(x):=42}
% %D    B1 R1 -> .plabel= b \bsm{f(u):=\sin(u)\\f'(u):=\cos(u)}
% %D ))
% %D enddiagram
% %D
% $$\pu
%   \diag{diamond-3-minus}
% $$


% «debugability»  (to ".debugability")
\section{Debugability}
\label{debugability}

Compare Apex Calculus with some other books



% «names»  (to ".names")
\section{A problem with names}
\label{names}

% https://groups.google.com/a/dimap.ufrn.br/g/logica-l/c/pTUm2AU4e4M/m/HA4g29e6AwAJ
% Muitos alunos daqui de Rio das Ostras têm muita dificuldade de
% entender que isto aqui é _uma_ função:
% 
%   $f(x) =
%    \begin{cases}
%      x^3 & \text{se $x<0$}, \\
%      x^2 & \text{se $x \ge 0$} \\
%    \end{cases}
%   $
% 
% Eles acham que isso é (são?) duas funções, e eles têm muita
% dificuldade pra nomes pras coisas, então eles não conseguem dizer que
% as duas funções são estas (que eu vou escrever sem domínios e
% contradomínios por motivos de correria):
% 
%   $f_1(x) = x^3$
% 
%   $f_2(x) = x^2$
% 
% Depois que a gente escreve isso fica mais ou menos claro que nós
% estamos falando de pelo menos três funções, e que se os alunos não
% derem nomes pra elas melhores do que chamar elas de "a função", "a
% função", "a função", "a função" e "a função", muita coisa pode dar
% errado...
% 
% Um modo de decidir qual definição de função é mais "elementar" é
% descobrir qual é mais acessível pra pessoas que sabem pouquíssima
% matemática - ou pra um certo grupo de pessoas que sabem pouquíssima
% matemática. E já que os alunos daqui têm muita dificuldade com nomes e
% letras isso me leva a concluir que isso aqui é uma função "bem
% elementar (pra eles)",
% 
%   {(0,0), (1,1), (2,4), (3,9)}
% 
% desde que
% 
%   1) a gente desenhe ela como pontinhos em R^2,
%   2) a gente tenha poucos pontinhos - se tiver infinitos ferrou tudo,
%   3) a gente só use números inteiros pequenos e fáceis de desenhar...
% 
% Desculpem o rant antropológico - e nos itens 2 e 3 eu tava pensando em
% como construir outras funções "bem elementares" e em como medir a
% elementaridade de funções, nesse sentido de "elementar pra esses
% alunos no início do curso"...



% «set-comprehensions»  (to ".set-comprehensions")
\section{Set comprehensions}
\label{set-comprehensions}
% Mpg8 (mpgp 8 "comprehension")
%      (mpga   "comprehension")

Mpg8


% «a-game»  (to ".a-game")
\section{A game}
\label{a-game}
% 2gT105: (c2m231srp 27 "um-jogo")
%         (c2m231sra    "um-jogo")

Translate to English; use different names; adapt to drawing the graphs
of functions; include an example of a game with several kinds of ``you
lose''


% «colleagues»  (to ".colleagues")
\section{Colleagues}
\label{colleagues}

Slapstick comedy about tenure gone wrong

Convinced some other colleagues that they would attend some of my
classes

Good practices - Riemann sums

Order: stop using your own material, use only the book -- was never
written down

Final report

Discipline, punished, fired

PIP - performance improvement program

I heard from students that they only teach the textbooks

``Isso você já deveria saber''




\cite{OchsMisB}

\printbibliography

\GenericWarning{Success:}{Success!!!}  % Used by `M-x cv'

\end{document}

% (find-LATEX "2022on-the-missing.tex" "make-arxiv")
% (find-build-for-arxiv-links "2024panic-at-equalities")


% Local Variables:
% coding: utf-8-unix
% ee-tla: "pae"
% End: