% STEM content samples for LaTeX-to-HTML accessibility testing
\ifdefined\HCode
  \documentclass[10pt,letterpaper]{article}
\else
  \documentclass[10pt,letterpaper,twocolumn]{article}
\fi

\usepackage{fontspec}
\setmainfont{DejaVu Serif}
\setsansfont{DejaVu Sans}
\setmonofont{DejaVu Sans Mono}
\usepackage[english]{babel}
\usepackage[
  letterpaper,
  top=0.68in,
  bottom=0.72in,
  left=0.70in,
  right=0.70in
]{geometry}
\usepackage{microtype}

\usepackage{amsmath,amssymb,amsfonts,mathtools}
\usepackage{booktabs,array,tabularx,makecell}
\usepackage{graphicx}
\usepackage{xcolor}
\usepackage{ragged2e}
\usepackage{enumitem}
\usepackage{needspace}
\usepackage{listings}
\usepackage{caption}
\usepackage{float}
\usepackage{tikz}
\usetikzlibrary{arrows.meta,positioning,calc}
\usepackage{pgfplots}
\pgfplotsset{compat=1.18}
\usepackage[hidelinks]{hyperref}

% -------------------------------------------------
% Two-column layout controls
% -------------------------------------------------
\setlength{\columnsep}{0.26in}
\setlength{\columnseprule}{0pt}
\setlength{\textfloatsep}{8pt plus 2pt minus 2pt}
\setlength{\floatsep}{7pt plus 2pt minus 2pt}
\setlength{\intextsep}{7pt plus 2pt minus 2pt}
\setlength{\dbltextfloatsep}{9pt plus 2pt minus 2pt}
\setlength{\dblfloatsep}{8pt plus 2pt minus 2pt}
\raggedbottom
\setlength{\abovedisplayskip}{5pt plus 2pt minus 2pt}
\setlength{\belowdisplayskip}{5pt plus 2pt minus 2pt}
\setlength{\abovedisplayshortskip}{3pt plus 1pt minus 1pt}
\setlength{\belowdisplayshortskip}{3pt plus 1pt minus 1pt}

\captionsetup{
  font=small,
  labelfont=bf,
  justification=raggedright,
  singlelinecheck=false,
  skip=4pt
}

\setlist[itemize]{leftmargin=1.45em,itemsep=2pt,topsep=3pt}
\setlist[enumerate]{leftmargin=1.75em,itemsep=2pt,topsep=3pt}

\newcolumntype{Y}{>{\RaggedRight\arraybackslash}X}
\newcolumntype{C}{>{\Centering\arraybackslash}X}

% -------------------------------------------------
% Compact code style for research-paper columns
% -------------------------------------------------
\definecolor{codegray}{gray}{0.42}
\lstdefinestyle{researchcode}{
  basicstyle=\ttfamily\fontsize{7pt}{8pt}\selectfont,
  keywordstyle=\bfseries,
  commentstyle=\itshape,
  stringstyle=\ttfamily,
  numbers=left,
  numberstyle=\ttfamily\tiny\color{codegray},
  stepnumber=1,
  numbersep=4pt,
  frame=tb,
  framerule=0.35pt,
  framesep=3pt,
  breaklines=true,
  breakatwhitespace=false,
  columns=fullflexible,
  keepspaces=true,
  showstringspaces=false,
  tabsize=4,
  xleftmargin=1.35em,
  framexleftmargin=1.05em,
  xrightmargin=0pt,
  linewidth=\linewidth,
  aboveskip=5pt,
  belowskip=5pt,
  captionpos=t,
  abovecaptionskip=0pt,
  belowcaptionskip=4pt
}
\lstset{style=researchcode}

\hypersetup{
  pdftitle={STEM Accessibility Test Document},
  pdfauthor={Sohan Reddy Ganampeta},
  pdfsubject={LaTeX-to-HTML accessibility testing with NVDA},
  pdfkeywords={LaTeX, HTML5, MathML, MathJax, NVDA, MathCAT, accessibility}
}

\title{STEM Accessibility Test Document}
\author{Sohan Reddy Ganampeta}
\date{July 2026}
\begin{document}

\maketitle

\begin{abstract}
This document collects representative STEM content for testing LaTeX-to-HTML
conversion with NVDA. It includes mathematics, code, tables, charts, diagrams,
captions, and text alternatives from several academic disciplines.
\end{abstract}

\setcounter{tocdepth}{3}
\tableofcontents
\clearpage

% -------------------------------------------------

% -------------------------------------------------
\section{Inline and Display Mathematics}

The Pythagorean relationship is \(a^{2}+b^{2}=c^{2}\), and Newton's
second law is \(F=ma\).

A simple displayed equation is

\begin{equation}
E=mc^{2}.
\end{equation}


% -------------------------------------------------
\section{Fractions, Roots, Exponents, and Subscripts}

The solutions of the quadratic equation \(ax^{2}+bx+c=0\), where \(a\neq0\),
are

\begin{equation}
x=\frac{-b\pm\sqrt{b^{2}-4ac}}{2a}.
\end{equation}

For a damped second-order system, the natural frequency and damping ratio may
be written as

\begin{align}
\omega_{n} &= \sqrt{\frac{k}{m}},\\
\zeta &= \frac{c}{2\sqrt{mk}}.
\end{align}


% -------------------------------------------------
\section{Calculus}

The derivative of a polynomial may be shown line by line:

\begin{align}
f(x) &= x^{3}-4x^{2}+2x-7,\\
f'(x) &= 3x^{2}-8x+2.
\end{align}

The definite integral of \(2x\) from zero to three is

\begin{align}
\int_{0}^{3}2x\,\mathrm{d}x
    &= \left[x^{2}\right]_{0}^{3}\\
    &= 3^{2}-0^{2}\\
    &= 9.
\end{align}

For a multivariable function \(g(x,y)\), the gradient is

\begin{equation}
\nabla g(x,y)=
\begin{bmatrix}
\dfrac{\partial g}{\partial x}\\[3pt]
\dfrac{\partial g}{\partial y}
\end{bmatrix}.
\end{equation}


% -------------------------------------------------
\section{Aligned Equations and Multi-Step Derivations}

Consider the first-order differential equation

\begin{equation}
\dot{x}(t)+2x(t)=4,
\qquad x(0)=1.
\end{equation}

Multiplying by the integrating factor \(e^{2t}\) gives

\begin{align}
e^{2t}\dot{x}(t)+2e^{2t}x(t)
    &=4e^{2t},\\
\frac{\mathrm{d}}{\mathrm{d}t}
\left(e^{2t}x(t)\right)
    &=4e^{2t},\\
e^{2t}x(t)-x(0)
    &=2\left(e^{2t}-1\right),\\
x(t) &=2-e^{-2t}.
\end{align}


% -------------------------------------------------
\section{Vectors and Matrices}

Let

\begin{equation}
\mathbf{x}=
\begin{bmatrix}
x_{1}\\
x_{2}
\end{bmatrix},
\qquad
A=
\begin{bmatrix}
0 & 1\\
-\dfrac{k}{m} & -\dfrac{c}{m}
\end{bmatrix},
\qquad
B=
\begin{bmatrix}
0\\
\dfrac{1}{m}
\end{bmatrix}.
\end{equation}

The state equation is

\begin{equation}
\dot{\mathbf{x}}=A\mathbf{x}+B u.
\end{equation}


% -------------------------------------------------
\section{Piecewise Functions and Cases}

Piecewise definitions are important in control, optimization, and signal
processing. A saturation function may be written as

\begin{equation}
\operatorname{sat}(u)=
\begin{cases}
u_{\max}, & u>u_{\max},\\
u, & -u_{\max}\leq u\leq u_{\max},\\
-u_{\max}, & u<-u_{\max}.
\end{cases}
\end{equation}


% -------------------------------------------------
\section{Greek Symbols and Control Notation}

Consider the Lyapunov candidate

\begin{equation}
V(e,\widetilde{\theta})
=\frac{1}{2}e^{\mathsf{T}}Pe
+\frac{1}{2}\widetilde{\theta}^{\mathsf{T}}
\Gamma^{-1}\widetilde{\theta},
\end{equation}

with the derivative condition

\begin{equation}
\dot{V}
\leq
-\lambda_{\min}(Q)\lVert e\rVert^{2}.
\end{equation}


% -------------------------------------------------
\section{Math Inside Lists}

\begin{enumerate}
    \item The sampling period is \(T_{s}=0.01\,\mathrm{s}\).
    \item The estimation error is \(e_{k}=x_{k}-\hat{x}_{k}\).
    \item The control command is \(u_{k}=-Kx_{k}+r_{k}\).
    \item The error magnitude is \(\lVert e_{k}\rVert\).
\end{enumerate}


% -------------------------------------------------
\section{Mathematics in a Data Table}

\ifdefined\HCode\else\onecolumn\fi

\noindent\begin{minipage}{\textwidth}
\centering
\captionsetup{width=0.84\textwidth}
\captionof{table}{System parameters for a second-order example.}
\label{tab:system-parameters}
\small
\begin{tabularx}{0.84\textwidth}{@{}Y c c@{}}
\toprule
\textbf{Parameter and meaning} &
\textbf{Symbol} &
\textbf{Value}\\
\midrule
Mass (object inertia) & \(m\) & \(1.0\,\mathrm{kg}\)\\
Damping coefficient (velocity resistance) & \(c\) & \(0.4\,\mathrm{N\,s/m}\)\\
Spring constant (position-restoring coefficient) & \(k\) & \(2.0\,\mathrm{N/m}\)\\
Natural frequency (undamped oscillation frequency) & \(\omega_{n}\) & \(\sqrt{k/m}\)\\
Damping ratio (normalized damping measure) & \(\zeta\) & \(c/(2\sqrt{mk})\)\\
\bottomrule
\end{tabularx}
\end{minipage}


% -------------------------------------------------
% Keep the heading and introduction with the nonfloating chart block.  If the
% remaining space is too small, the complete section starts on the next page.
\Needspace{4.2in}
\section{Chart with a Text Equivalent}

\noindent\begin{minipage}{\textwidth}
\noindent
\begin{minipage}[t]{0.66\textwidth}
\vspace{0pt}
\centering
\IfFileExists{figures/stability_plot.png}{%
  \includegraphics[
    width=\linewidth,
    height=1.68in,
    keepaspectratio
  ]{figures/stability_plot.png}%
}{%
  \begin{tikzpicture}
  \begin{axis}[
    width=\linewidth,
    height=1.68in,
    xmin=0,xmax=10,
    ymin=0,ymax=1.1,
    xlabel={Time (seconds)},
    ylabel={Tracking error magnitude},
    grid=major,
    tick label style={font=\small},
    label style={font=\small}
  ]
  \addplot[blue,thick,smooth] coordinates {
    (0,1.00) (0.5,0.60) (1,0.48) (1.5,0.55)
    (2,0.38) (2.5,0.25) (3,0.29) (3.5,0.20)
    (4,0.13) (4.5,0.15) (5,0.11) (5.5,0.07)
    (6,0.08) (7,0.045) (8,0.028) (9,0.017) (10,0.010)
  };
  \end{axis}
  \end{tikzpicture}%
}
\end{minipage}\hfill
\begin{minipage}[t]{0.30\textwidth}
\vspace{0pt}
\footnotesize
\textbf{Text equivalent.}
From zero to ten seconds, the tracking error starts near \(1.00\), decreases
rapidly, oscillates with progressively smaller peaks, and approaches zero. This
downward trend is consistent with a stable response.

\medskip
The visual shape is not the only source of information: selected numerical
values are also provided in Table~\ref{tab:stability-data}.
\end{minipage}
\captionof{figure}{Tracking error decreases over time in a stable system.}
\label{fig:stability-chart}

\smallskip
\centering
\captionsetup{width=0.56\textwidth}
\captionof{table}{Selected data points from the stability chart.}
\label{tab:stability-data}
\begin{tabular}{@{}cccccc@{}}
\toprule
\textbf{Time (s)} & 0 & 2 & 4 & 6 & 10\\
\textbf{Error magnitude} & 1.00 & 0.38 & 0.13 & 0.08 & 0.01\\
\bottomrule
\end{tabular}
\end{minipage}

% -------------------------------------------------
% Prevent the block-diagram heading from being left at the bottom of a page.
\Needspace{2.2in}
\section{Block Diagram with a Text Equivalent}

\noindent\begin{minipage}{\textwidth}
\noindent
\begin{minipage}[t]{0.64\textwidth}
\vspace{0pt}
\centering
\resizebox{\linewidth}{!}{%
\begin{tikzpicture}[
  >={Latex},
  node distance=1.25cm,
  block/.style={draw,minimum height=0.85cm,minimum width=2.1cm,align=center},
  sum/.style={draw,circle,inner sep=1.5pt,minimum size=0.62cm},
  every node/.style={font=\small}
]
\node[block] (reference) {Reference};
\node[sum,right=of reference] (sum) {$\sum$};
\node[block,right=of sum] (controller) {Controller};
\node[block,right=of controller] (plant) {Plant};
\node[block,right=of plant] (output) {Output};

\draw[->,thick] (reference) -- (sum);
\draw[->,thick] (sum) -- node[above]{error} (controller);
\draw[->,thick] (controller) -- node[above]{control input} (plant);
\draw[->,thick] (plant) -- node[above]{response} (output);
\draw[->,thick]
  (output.south) -- ++(0,-1.0)
  -| node[pos=0.35,below]{feedback path} (sum.south);
\node[left=2pt of sum.south,yshift=-7pt] {$-$};
\end{tikzpicture}%
}
\end{minipage}\hfill
\begin{minipage}[t]{0.32\textwidth}
\vspace{0pt}
\footnotesize
\textbf{Text equivalent.}
The reference signal enters a summing junction. The measured output is returned
through a feedback path and subtracted from the reference. The resulting error
enters the controller. The controller sends a control input to the plant, and
the plant produces the system output.
\end{minipage}
\captionof{figure}{Closed-loop control diagram with reference input, controller, plant,
output, and feedback.}
\label{fig:closed-loop}
\end{minipage}

% Resume the standard two-column research-paper layout.
\ifdefined\HCode\else\twocolumn\fi

% -------------------------------------------------
\section{Algorithm as Structured Text}

\begin{enumerate}
    \item Initialize the state estimate \(\hat{\mathbf{x}}_{0}\), parameter
    estimate \(\hat{\theta}_{0}\), and sampling period \(T_{s}\).

    \item At sample \(k\), obtain the measurement \(y_{k}\).

    \item Compute the estimation error
    \[
    e_{k}=y_{k}-\hat{y}_{k}.
    \]

    \item Update the state estimate using the system model and correction term.

    \item Update the parameter estimate according to the specified adaptive law.

    \item Increase \(k\) by one and repeat until the stopping condition is met.
\end{enumerate}


% -------------------------------------------------
\section{Mathematics and Statistics}

\subsection{Linear Equation With Explicit Steps}

Solve \(3x+5=20\):

\begin{align}
3x+5 &=20,\\
3x &=15,\\
x &=5.
\end{align}

Each row performs one operation on both sides of the equality.

\subsection{Quadratic Equation by Completing the Square}

For \(x^{2}-6x+5=0\),

\begin{align}
x^{2}-6x &=-5,\\
x^{2}-6x+9 &=4,\\
(x-3)^{2} &=4,\\
x-3 &=\pm2,\\
x &=1\quad\text{or}\quad x=5.
\end{align}

\subsection{Derivative With Separate Left and Right Sides}

Verify that

\begin{equation}
\frac{\mathrm{d}}{\mathrm{d}x}(x^{2}+3x)=2x+3.
\end{equation}

\textbf{Left-hand side:}

\begin{align}
\frac{\mathrm{d}}{\mathrm{d}x}(x^{2}+3x)
&=\frac{\mathrm{d}}{\mathrm{d}x}(x^{2})
 +\frac{\mathrm{d}}{\mathrm{d}x}(3x)\\
&=2x+3.
\end{align}

\textbf{Right-hand side:}

\begin{equation}
2x+3.
\end{equation}

Therefore, the independently interpreted left- and right-hand sides agree.

\subsection{Matrix Multiplication}

Let

\begin{equation}
A=\begin{bmatrix}1&2\\3&4\end{bmatrix},
\qquad
\mathbf{x}=\begin{bmatrix}5\\6\end{bmatrix}.
\end{equation}

Then

\begin{align}
A\mathbf{x}
&=
\begin{bmatrix}
1(5)+2(6)\\
3(5)+4(6)
\end{bmatrix}\\
&=
\begin{bmatrix}
17\\
39
\end{bmatrix}.
\end{align}

\subsection{Proof by Mathematical Induction}

Prove that

\begin{equation}
1+2+\cdots+n=\frac{n(n+1)}{2}
\end{equation}

for every positive integer \(n\).

\textbf{Base case.} For \(n=1\),

\begin{equation}
1=\frac{1(1+1)}{2}=1.
\end{equation}

\textbf{Inductive hypothesis.} Assume

\begin{equation}
1+2+\cdots+k=\frac{k(k+1)}{2}.
\end{equation}

\textbf{Inductive step.} Then

\begin{align}
1+2+\cdots+k+(k+1)
&=\frac{k(k+1)}{2}+(k+1)\\
&=(k+1)\left(\frac{k}{2}+1\right)\\
&=\frac{(k+1)(k+2)}{2}.
\end{align}

This is the required formula with \(n=k+1\); therefore, the statement holds
for all positive integers.

\subsection{Separate LHS and RHS Trigonometric Derivations}

Verify the identity

\begin{equation}
\frac{1-\cos(2x)}{\sin(2x)}=\tan(x).
\end{equation}

\textbf{Left-hand side derivation:}

\begin{align}
\frac{1-\cos(2x)}{\sin(2x)}
&=\frac{2\sin^{2}(x)}{2\sin(x)\cos(x)}\\
&=\frac{\sin(x)}{\cos(x)}\\
&=\tan(x).
\end{align}

\textbf{Right-hand side derivation:}

\begin{align}
\tan(x)&=\frac{\sin(x)}{\cos(x)}.
\end{align}

Both sides reduce to \(\sin(x)/\cos(x)\), so the identity is verified wherever
the original expressions are defined.

\subsection{LHS Derived to a Constant RHS}

For the infinite geometric series,

\begin{equation}
1+\frac{1}{2}+\frac{1}{4}+\frac{1}{8}+\cdots=2.
\end{equation}

Let

\begin{equation}
S=1+\frac{1}{2}+\frac{1}{4}+\frac{1}{8}+\cdots.
\end{equation}

Multiply both sides by \(2\):

\begin{equation}
2S=2+1+\frac{1}{2}+\frac{1}{4}+\cdots.
\end{equation}

Subtract the original series from the doubled series:

\begin{align}
2S-S
&=\left(2+1+\frac{1}{2}+\frac{1}{4}+\cdots\right)
 -\left(1+\frac{1}{2}+\frac{1}{4}+\cdots\right),\\
S&=2.
\end{align}

Therefore,

\begin{equation}
1+\frac{1}{2}+\frac{1}{4}+\frac{1}{8}+\cdots=2.
\end{equation}

Here the left-hand side is derived, while the right-hand side remains the
constant \(2\).

\section{Computer Science}

\subsection{Cross-Language Number-Analysis Program}

The four listings implement the same number-analysis task in Python, R,
MATLAB, and C++.

\subsubsection{Python Example}


\begin{lstlisting}[language=Python,caption={Python palindrome and number-analysis program},label={lst:python-palindrome}]
def normalize_number(value: int) -> int:
    """Return the nonnegative form of an integer."""
    return abs(value)


def reverse_number(value: int) -> int:
    number = normalize_number(value)
    reversed_value = 0

    while number > 0:
        digit = number % 10
        reversed_value = (reversed_value * 10) + digit
        number //= 10

    return reversed_value


def digit_sum(value: int) -> int:
    number = normalize_number(value)
    total = 0

    while number > 0:
        total += number % 10
        number //= 10

    return total


def is_palindrome(value: int) -> bool:
    number = normalize_number(value)
    return number == reverse_number(number)


def is_prime(value: int) -> bool:
    number = normalize_number(value)

    if number < 2:
        return False

    divisor = 2
    while divisor * divisor <= number:
        if number % divisor == 0:
            return False
        divisor += 1

    return True


def analyze_numbers(values: list[int]) -> list[dict[str, object]]:
    results = []

    for index, value in enumerate(values, start=1):
        result = {
            "item": index,
            "original": value,
            "reverse": reverse_number(value),
            "digit_sum": digit_sum(value),
            "palindrome": is_palindrome(value),
            "prime": is_prime(value),
        }
        results.append(result)

    return results


def print_report(results: list[dict[str, object]]) -> None:
    print("\nNUMBER ANALYSIS REPORT")
    print("-" * 76)
    print(
        f"{'Item':>4} | {'Number':>10} | {'Reverse':>10} | "
        f"{'Digit sum':>9} | {'Palindrome':>10} | {'Prime':>5}"
    )
    print("-" * 76)

    for result in results:
        palindrome_text = "yes" if result["palindrome"] else "no"
        prime_text = "yes" if result["prime"] else "no"
        print(
            f"{result['item']:>4} | {result['original']:>10} | "
            f"{result['reverse']:>10} | {result['digit_sum']:>9} | "
            f"{palindrome_text:>10} | {prime_text:>5}"
        )


def main() -> None:
    default_data = "121, 1331, 42, 97, -44, 1001"
    prompt = f"Enter integers separated by commas [{default_data}]: "
    raw_text = input(prompt).strip()

    if raw_text == "":
        raw_text = default_data

    try:
        values = [int(part.strip()) for part in raw_text.split(",")]
    except ValueError as error:
        print(f"Input error: {error}. The default list will be used.")
        values = [121, 1331, 42, 97, -44, 1001]

    results = analyze_numbers(values)
    print_report(results)

    palindrome_count = 0; prime_count = 0
    for result in results:
        palindrome_count += int(result["palindrome"])
        prime_count += int(result["prime"])

    summary = {
        "total": len(results),
        "palindromes": palindrome_count,
        "primes": prime_count,
    }
    print(
        f"\nSummary: total={summary['total']}, "
        f"palindromes={summary['palindromes']}, "
        f"primes={summary['primes']}."
    )


if __name__ == "__main__":
    main()
\end{lstlisting}


\subsubsection{R Example}

The R version performs the same task so that code navigation and punctuation pronunciation can be compared across languages.

\begin{lstlisting}[language=R,caption={R palindrome and number-analysis program},label={lst:r-palindrome}]
normalize_number <- function(value) {
  return(abs(as.integer(value)))
}

reverse_number <- function(value) {
  number <- normalize_number(value)
  reversed_value <- 0L

  while (number > 0L) {
    digit <- number %% 10L
    reversed_value <- (reversed_value * 10L) + digit
    number <- number %/% 10L
  }

  return(reversed_value)
}

digit_sum <- function(value) {
  number <- normalize_number(value)
  total <- 0L

  while (number > 0L) {
    total <- total + (number %% 10L)
    number <- number %/% 10L
  }

  return(total)
}

is_palindrome <- function(value) {
  number <- normalize_number(value)
  return(number == reverse_number(number))
}

is_prime_number <- function(value) {
  number <- normalize_number(value)

  if (number < 2L) {
    return(FALSE)
  }

  limit <- floor(sqrt(number))
  if (limit >= 2L) {
    for (divisor in 2L:limit) {
      if ((number %% divisor) == 0L) {
        return(FALSE)
      }
    }
  }

  return(TRUE)
}

analyze_numbers <- function(values) {
  rows <- lapply(seq_along(values), function(index) {
    value <- values[index]

    data.frame(
      Item = index,
      Number = value,
      Reverse = reverse_number(value),
      Digit.Sum = digit_sum(value),
      Palindrome = is_palindrome(value),
      Prime = is_prime_number(value),
      stringsAsFactors = FALSE
    )
  })

  return(do.call(rbind, rows))
}

main <- function() {
  default_data <- "121, 1331, 42, 97, -44, 1001"
  prompt_text <- paste0(
    "Enter integers separated by commas [",
    default_data,
    "]: "
  )
  raw_text <- trimws(readline(prompt = prompt_text))

  if (identical(raw_text, "")) {
    raw_text <- default_data
  }

  pieces <- trimws(unlist(strsplit(raw_text, ",")))
  values <- suppressWarnings(as.integer(pieces))

  if (length(values) == 0L || any(is.na(values))) {
    cat("Input error: the default list will be used.\n")
    values <- c(121L, 1331L, 42L, 97L, -44L, 1001L)
  }

  results <- analyze_numbers(values)
  cat("\nNUMBER ANALYSIS REPORT\n")
  print(results, row.names = FALSE)

  palindrome_count <- sum(results$Palindrome); prime_count <- sum(results$Prime)
  summary <- list(
    total = nrow(results),
    palindromes = palindrome_count,
    primes = prime_count
  )

  cat(sprintf(
    "\nSummary: total=%d, palindromes=%d, primes=%d.\n",
    summary$total,
    summary$palindromes,
    summary$primes
  ))
}

main()
\end{lstlisting}


\subsubsection{MATLAB Example}

The MATLAB version uses a script followed by local functions. It tests array notation, structure fields, colon-based ranges, formatted output, and function boundaries.

\begin{lstlisting}[language=Matlab,caption={MATLAB palindrome and number-analysis program},label={lst:matlab-palindrome}]
% Palindrome and number-analysis program
clear; clc;

defaultData = [121, 1331, 42, 97, -44, 1001];
promptText = ['Enter integers separated by commas ', ...
              '[121, 1331, 42, 97, -44, 1001]: '];
rawText = strtrim(input(promptText, 's'));

if isempty(rawText)
    values = defaultData;
else
    pieces = split(rawText, ',');
    values = str2double(strtrim(pieces));
    values = values(:).';

    if isempty(values) || any(isnan(values))
        fprintf('Input error: the default list will be used.\n');
        values = defaultData;
    end
end

template = struct( ...
    'Item', 0, ...
    'Number', 0, ...
    'Reverse', 0, ...
    'DigitSum', 0, ...
    'Palindrome', false, ...
    'Prime', false);
results = repmat(template, 1, numel(values));

for index = 1:numel(values)
    value = values(index);
    results(index).Item = index;
    results(index).Number = value;
    results(index).Reverse = reverseNumber(value);
    results(index).DigitSum = digitSum(value);
    results(index).Palindrome = isPalindrome(value);
    results(index).Prime = isPrimeNumber(value);
end

fprintf('\nNUMBER ANALYSIS REPORT\n');
fprintf('%s\n', repmat('-', 1, 76));
fprintf('%4s | %10s | %10s | %9s | %10s | %5s\n', ...
    'Item', 'Number', 'Reverse', 'Digit sum', 'Palindrome', 'Prime');
fprintf('%s\n', repmat('-', 1, 76));

for index = 1:numel(results)
    palindromeText = yesOrNo(results(index).Palindrome);
    primeText = yesOrNo(results(index).Prime);
    fprintf('%4d | %10d | %10d | %9d | %10s | %5s\n', ...
        results(index).Item, ...
        results(index).Number, ...
        results(index).Reverse, ...
        results(index).DigitSum, ...
        palindromeText, primeText);
end

summary.total = numel(results);
summary.palindromes = sum([results.Palindrome]);
summary.primes = sum([results.Prime]);
fprintf('\nSummary: total=%d, palindromes=%d, primes=%d.\n', ...
    summary.total, summary.palindromes, summary.primes);

function output = normalizeNumber(value)
    output = abs(fix(value));
end

function output = reverseNumber(value)
    number = normalizeNumber(value);
    output = 0;

    while number > 0
        digit = mod(number, 10);
        output = (output * 10) + digit;
        number = floor(number / 10);
    end
end

function output = digitSum(value)
    number = normalizeNumber(value);
    output = 0;

    while number > 0
        output = output + mod(number, 10);
        number = floor(number / 10);
    end
end

function answer = isPalindrome(value)
    number = normalizeNumber(value);
    answer = (number == reverseNumber(number));
end

function answer = isPrimeNumber(value)
    number = normalizeNumber(value);

    if number < 2
        answer = false;
        return;
    end

    answer = true;
    limit = floor(sqrt(number));

    for divisor = 2:limit
        if mod(number, divisor) == 0
            answer = false;
            break;
        end
    end
end

function text = yesOrNo(condition)
    if condition
        text = 'yes';
    else
        text = 'no';
    end
end
\end{lstlisting}


\subsubsection{C++ Example}

The C++ version uses a structure, vectors, functions, exception handling, stream input, formatted output, and the conditional operator. It provides dense punctuation that is useful when evaluating screen-reader code settings.

\begin{lstlisting}[language=C++,caption={C++ palindrome and number-analysis program},label={lst:cpp-palindrome}]
#include <cstdlib>
#include <iomanip>
#include <iostream>
#include <sstream>
#include <stdexcept>
#include <string>
#include <vector>

struct Result {
    std::size_t item;
    long long original;
    long long reversed;
    int digitSum;
    bool palindrome;
    bool prime;
};

long long normalizeNumber(long long value) {
    return std::llabs(value);
}

long long reverseNumber(long long value) {
    long long number = normalizeNumber(value);
    long long reversedValue = 0;

    while (number > 0) {
        const int digit = static_cast<int>(number % 10);
        reversedValue = (reversedValue * 10) + digit;
        number /= 10;
    }

    return reversedValue;
}

int calculateDigitSum(long long value) {
    long long number = normalizeNumber(value);
    int total = 0;

    while (number > 0) {
        total += static_cast<int>(number % 10);
        number /= 10;
    }

    return total;
}

bool isPalindrome(long long value) {
    const long long number = normalizeNumber(value);
    return number == reverseNumber(number);
}

bool isPrimeNumber(long long value) {
    const long long number = normalizeNumber(value);

    if (number < 2) {
        return false;
    }

    for (long long divisor = 2; divisor * divisor <= number; ++divisor) {
        if (number % divisor == 0) {
            return false;
        }
    }

    return true;
}

std::string trim(const std::string& text) {
    const std::string spaces = " \t\n\r";
    const std::size_t first = text.find_first_not_of(spaces);

    if (first == std::string::npos) {
        return "";
    }

    const std::size_t last = text.find_last_not_of(spaces);
    return text.substr(first, last - first + 1);
}

std::vector<long long> parseInput(const std::string& text) {
    std::vector<long long> values;
    std::stringstream stream(text);
    std::string token;

    while (std::getline(stream, token, ',')) {
        token = trim(token);
        std::size_t usedCharacters = 0;
        const long long value = std::stoll(token, &usedCharacters);

        if (usedCharacters != token.size()) {
            throw std::invalid_argument("Unexpected characters in: " + token);
        }

        values.push_back(value);
    }

    if (values.empty()) {
        throw std::invalid_argument("No integers were entered.");
    }

    return values;
}

std::vector<Result> analyzeNumbers(const std::vector<long long>& values) {
    std::vector<Result> results;

    for (std::size_t index = 0; index < values.size(); ++index) {
        const long long value = values[index];
        results.push_back(Result{
            index + 1,
            value,
            reverseNumber(value),
            calculateDigitSum(value),
            isPalindrome(value),
            isPrimeNumber(value)
        });
    }

    return results;
}

void printReport(const std::vector<Result>& results) {
    std::cout << "\nNUMBER ANALYSIS REPORT\n";
    std::cout << std::string(76, '-') << '\n';
    std::cout << std::setw(4) << "Item" << " | "
              << std::setw(10) << "Number" << " | "
              << std::setw(10) << "Reverse" << " | "
              << std::setw(9) << "Digit sum" << " | "
              << std::setw(10) << "Palindrome" << " | "
              << std::setw(5) << "Prime" << '\n';
    std::cout << std::string(76, '-') << '\n';

    for (const Result& result : results) {
        const char* palindromeText = result.palindrome ? "yes" : "no";
        const char* primeText = result.prime ? "yes" : "no";

        std::cout << std::setw(4) << result.item << " | "
                  << std::setw(10) << result.original << " | "
                  << std::setw(10) << result.reversed << " | "
                  << std::setw(9) << result.digitSum << " | "
                  << std::setw(10) << palindromeText << " | "
                  << std::setw(5) << primeText << '\n';
    }
}

int main() {
    const std::string defaultData = "121, 1331, 42, 97, -44, 1001";
    std::cout << "Enter integers separated by commas ["
              << defaultData << "]: ";

    std::string inputText;
    std::getline(std::cin, inputText);
    inputText = trim(inputText);

    if (inputText.empty()) {
        inputText = defaultData;
    }

    std::vector<long long> values;
    try {
        values = parseInput(inputText);
    } catch (const std::exception& error) {
        std::cerr << "Input error: " << error.what()
                  << " The default list will be used.\n";
        values = {121, 1331, 42, 97, -44, 1001};
    }

    const std::vector<Result> results = analyzeNumbers(values);
    printReport(results);

    int palindromeCount = 0;
    int primeCount = 0;
    for (const Result& result : results) {
        palindromeCount += result.palindrome ? 1 : 0;
        primeCount += result.prime ? 1 : 0;
    }

    std::cout << "\nSummary: total=" << results.size()
              << ", palindromes=" << palindromeCount
              << ", primes=" << primeCount << ".\n";

    return 0;
}
\end{lstlisting}


\section{Physics and Astronomy}

\subsection{Physics Examples}

\subsubsection{Measurements, Units, and Uncertainty}

A measured velocity may be reported as

\[
v
=
(3.42\pm0.05)
\times10^{5}
\,\mathrm{m\,s^{-1}}.
\]

An energy measurement with asymmetric uncertainty may be written as

\[
E
=
1.50^{+0.18}_{-0.12}
\,\mathrm{keV}.
\]

\begin{table}[tbp]
\centering
\caption{Physics measurements with different uncertainty formats.}
\label{tab:physics-uncertainty}
\small
\begin{tabular}{@{}lll@{}}
\toprule
Quantity & Measured value & Unit\\
\midrule
Velocity
    & \(3.42\pm0.05\)
    & \(10^{5}\,\mathrm{m\,s^{-1}}\)\\
Energy
    & \(1.50^{+0.18}_{-0.12}\)
    & \(\mathrm{keV}\)\\
Temperature
    & \(295.4\pm0.6\)
    & \(\mathrm{K}\)\\
\bottomrule
\end{tabular}
\end{table}


% -------------------------------------------------
\subsubsection{Motion with Units and Vector Notation}

Consider an object with mass \(m=2\,\mathrm{kg}\) and acceleration

\[
\mathbf{a}
=
\begin{bmatrix}
3\\
-1\\
2
\end{bmatrix}
\,\mathrm{m\,s^{-2}}.
\]

Newton's second law gives

\begin{align}
\mathbf{F}
    &=m\mathbf{a}\\
    &=2
    \begin{bmatrix}
    3\\
    -1\\
    2
    \end{bmatrix}\\
    &=
    \begin{bmatrix}
    6\\
    -2\\
    4
    \end{bmatrix}
    \,\mathrm{N}.
\end{align}

The magnitude of the force is

\begin{align}
\lVert\mathbf{F}\rVert
    &=
    \sqrt{6^{2}+(-2)^{2}+4^{2}}\\
    &=
    \sqrt{56}\\
    &=
    2\sqrt{14}\,\mathrm{N}.
\end{align}


% -------------------------------------------------
\subsubsection{Electromagnetic Field Equations}

Gauss's law for the electric field is

\[
\nabla\cdot\mathbf{E}
=
\frac{\rho}{\varepsilon_{0}}.
\]

The Ampere--Maxwell equation is

\begin{align}
\nabla\times\mathbf{B}
    &=
    \mu_{0}\mathbf{J}
    \notag\\
    &\quad+
    \mu_{0}\varepsilon_{0}
    \frac{\partial\mathbf{E}}{\partial t}.
\end{align}

The Lorentz force on a particle is

\[
\mathbf{F}
=
q
\left(
\mathbf{E}
+
\mathbf{v}\times\mathbf{B}
\right).
\]


% -------------------------------------------------
\subsubsection{Quantum-Mechanical Notation}

The time-dependent SchrÃ¶dinger equation may be written as

\[
i\hbar
\frac{\partial}{\partial t}
\lvert\psi(t)\rangle
=
\hat{H}
\lvert\psi(t)\rangle.
\]

Normalization requires

\begin{align}
\langle\psi\mid\psi\rangle
    &=
    \int_{-\infty}^{\infty}
    \lvert\psi(x)\rvert^{2}\,dx\\
    &=1.
\end{align}

The expected value of position is

\[
\langle x\rangle
=
\langle\psi\lvert
\hat{x}
\rvert\psi\rangle.
\]


% -------------------------------------------------
\subsubsection{Tensor and General-Relativity Notation}

Einstein's field equation is

\[
G_{\mu\nu}
+
\Lambda g_{\mu\nu}
=
\frac{8\pi G}{c^{4}}
T_{\mu\nu}.
\]

An infinitesimal spacetime interval may be written as

\[
ds^{2}
=
g_{\mu\nu}
\,dx^{\mu}dx^{\nu}.
\]


% -------------------------------------------------
\subsubsection{Experimental Measurements and Fitted Model}

The measured response is compared with the model

\[
y(t)
=
e^{-0.40t}
\cos(1.80t).
\]

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.68\columnwidth,
    xlabel={Time \(t\) (\(\mathrm{s}\))},
    ylabel={Response \(y(t)\)},
    xmin=0,
    xmax=3.6,
    ymin=-0.45,
    ymax=1.15,
    grid=major,
    legend style={
        font=\scriptsize,
        draw=none,
        at={(0.98,0.97)},
        anchor=north east
    },
    tick label style={font=\scriptsize},
    label style={font=\small}
]
\addplot[
    black,
    thick
]
coordinates {
    (0.0,1.00)
    (0.5,0.68)
    (1.0,0.20)
    (1.5,-0.17)
    (2.0,-0.31)
    (2.5,-0.20)
    (3.0,0.02)
    (3.5,0.14)
};
\addlegendentry{Fitted model}

\addplot[
    only marks,
    mark=*,
    mark size=1.7pt,
    black,
    error bars/.cd,
    y dir=both,
    y explicit
]
table[
    x=t,
    y=value,
    y error=error,
    row sep=\\
] {
t value error\\
0.0  1.03 0.04\\
0.5  0.69 0.04\\
1.0  0.18 0.03\\
1.5 -0.20 0.04\\
2.0 -0.31 0.03\\
2.5 -0.17 0.03\\
3.0  0.03 0.04\\
3.5  0.15 0.04\\
};
\addlegendentry{Measurements}
\end{axis}
\end{tikzpicture}

\caption{Measured oscillatory response with uncertainty bars and a fitted
model. Filled circles represent measurements; the solid line represents the
model.}
\label{fig:physics-experiment}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Measured points follow a damped oscillatory model.

\textbf{Long description.}
Time runs from zero to \(3.5\) seconds. The response begins near \(1.0\),
decreases through zero, reaches approximately \(-0.31\) at two seconds, and
then increases toward zero. Each measured point has a vertical uncertainty
bar. The measured points remain close to the fitted curve.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Data represented in the experimental-response graph.}
\label{tab:physics-experiment-data}
\small
\begin{tabular}{@{}rrrr@{}}
\toprule
\(t\) (\(\mathrm{s}\))
& Measured
& Uncertainty
& Model\\
\midrule
0.0 &  1.03 & 0.04 &  1.00\\
0.5 &  0.69 & 0.04 &  0.68\\
1.0 &  0.18 & 0.03 &  0.20\\
1.5 & -0.20 & 0.04 & -0.17\\
2.0 & -0.31 & 0.03 & -0.31\\
2.5 & -0.17 & 0.03 & -0.20\\
3.0 &  0.03 & 0.04 &  0.02\\
3.5 &  0.15 & 0.04 &  0.14\\
\bottomrule
\end{tabular}
\end{table}


% -------------------------------------------------
\subsubsection{Experimental-Apparatus Diagram}

\begin{figure}[tbp]
\centering
\begin{tikzpicture}[
    component/.style={
        draw,
        rounded corners,
        minimum width=1.05cm,
        minimum height=0.65cm,
        align=center,
        font=\scriptsize
    },
    flow/.style={
        -{Stealth[length=2mm]},
        thick
    },
    node distance=4mm
]
\node[component] (laser) {Laser};
\node[component, right=of laser] (lens) {Lens};
\node[component, right=of lens] (sample) {Sample};
\node[component, right=of sample] (detector) {Detector};
\node[component, below=6mm of detector] (computer) {Computer};

\draw[flow] (laser) -- node[above,font=\tiny] {beam} (lens);
\draw[flow] (lens) -- (sample);
\draw[flow] (sample) -- (detector);
\draw[flow] (detector) -- node[right,font=\tiny] {signal} (computer);
\end{tikzpicture}

\caption{Simplified optical measurement apparatus. Arrows show the direction
of the optical beam and recorded signal.}
\label{fig:physics-apparatus}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
A laser beam passes through a lens and sample before reaching a detector.

\textbf{Long description.}
From left to right, the laser sends a beam to the lens, the lens directs the
beam through the sample, and the transmitted beam reaches the detector. The
detector sends an electrical signal downward to a computer.
\end{minipage}
\end{figure}


% =================================================
\subsection{Astronomy Examples}

\subsubsection{Orbital Period and Received Flux}

For two bodies with masses \(M\) and \(m\), the orbital period of a circular
orbit with radius \(a\) is

\[
T
=
2\pi
\sqrt{
\frac{a^{3}}{G(M+m)}
}.
\]

The received flux from a source with luminosity \(L\) at distance \(d\) is

\[
F
=
\frac{L}{4\pi d^{2}}.
\]

If the distance doubles while luminosity remains constant, then

\begin{align}
F_{\mathrm{new}}
    &=
    \frac{L}{4\pi(2d)^{2}}\\
    &=
    \frac{L}{16\pi d^{2}}\\
    &=
    \frac{1}{4}F.
\end{align}


% -------------------------------------------------
\subsubsection{Distance Modulus and Redshift}

The distance modulus is

\[
m-M
=
5\log_{10}
\left(
\frac{d}{10\,\mathrm{pc}}
\right).
\]

Astronomical redshift is

\[
z
=
\frac{
\lambda_{\mathrm{obs}}-\lambda_{0}
}{
\lambda_{0}
}.
\]

For \(\lambda_{\mathrm{obs}}=660.0\,\mathrm{nm}\) and
\(\lambda_{0}=656.3\,\mathrm{nm}\),

\begin{align}
z
    &=
    \frac{660.0-656.3}{656.3}\\
    &\approx
    5.64\times10^{-3}.
\end{align}


% -------------------------------------------------
\subsubsection{Celestial Coordinates}

A source position may be written as

\begin{align}
\alpha
    &=
    12^{\mathrm{h}}
    34^{\mathrm{m}}
    56.7^{\mathrm{s}},\\
\delta
    &=
    -45^{\circ}
    18^{\prime}
    22^{\prime\prime}.
\end{align}

Here, \(\alpha\) is right ascension and \(\delta\) is declination.

\begin{table}[tbp]
\centering
\caption{Example celestial coordinates.}
\label{tab:celestial-coordinates}
\scriptsize
\begin{tabular}{@{}lll@{}}
\toprule
Source & Right ascension & Declination\\
\midrule
A & 12:34:56.7 & \(-45\):18:22\\
B & 12:35:04.1 & \(-45\):17:49\\
C & 12:35:15.8 & \(-45\):19:03\\
\bottomrule
\end{tabular}
\end{table}


% -------------------------------------------------
\subsubsection{Multi-Panel Astronomical Image}

\begin{figure*}[tbp]
\centering
\begin{tikzpicture}[font=\small]

% Panel A
\begin{scope}
\fill[black!6] (0,0) rectangle (5.1,3.5);
\draw (0,0) rectangle (5.1,3.5);
\node[anchor=north west,font=\bfseries] at (0.10,3.40) {(A) Optical};

\foreach \x/\y/\r in {
0.45/0.55/0.04,
0.85/2.55/0.06,
1.25/1.35/0.04,
1.75/2.85/0.05,
2.05/0.60/0.04,
2.55/1.75/0.09,
3.15/2.55/0.05,
3.65/0.85/0.04,
4.10/2.90/0.06,
4.55/1.45/0.05,
4.75/0.45/0.04
}{
    \fill (\x,\y) circle (\r);
}

\draw[very thick] (2.55,1.75) circle (0.22);
\draw[-{Stealth[length=2mm]}] (0.45,2.65) -- (0.45,3.15);
\node[above,font=\scriptsize] at (0.45,3.15) {N};
\draw[-{Stealth[length=2mm]}] (0.45,2.65) -- (0.95,2.65);
\node[right,font=\scriptsize] at (0.95,2.65) {E};
\draw[thick] (3.70,0.35) -- (4.55,0.35);
\node[above,font=\scriptsize] at (4.12,0.35) {\(10^{\prime\prime}\)};
\end{scope}

% Panel B
\begin{scope}[xshift=5.55cm]
\fill[black!14] (0,0) rectangle (5.1,3.5);
\draw (0,0) rectangle (5.1,3.5);
\node[anchor=north west,font=\bfseries] at (0.10,3.40) {(B) Infrared};

\foreach \x/\y/\r in {
0.50/0.55/0.07,
0.90/2.60/0.08,
1.30/1.40/0.07,
1.80/2.80/0.08,
2.10/0.65/0.07,
2.55/1.75/0.20,
3.20/2.50/0.08,
3.65/0.90/0.07,
4.10/2.85/0.10,
4.55/1.45/0.08
}{
    \fill[black!75] (\x,\y) circle (\r);
}

\fill[black!35] (2.55,1.75) circle (0.48);
\draw[very thick] (2.55,1.75) circle (0.22);
\draw[thick] (3.70,0.35) -- (4.55,0.35);
\node[above,font=\scriptsize] at (4.12,0.35) {\(10^{\prime\prime}\)};
\end{scope}

% Panel C
\begin{scope}[xshift=11.10cm]
\fill[black!9] (0,0) rectangle (5.1,3.5);
\draw (0,0) rectangle (5.1,3.5);
\node[anchor=north west,font=\bfseries] at (0.10,3.40)
{(C) Composite};

\foreach \x/\y/\r in {
0.50/0.55/0.05,
0.90/2.60/0.06,
1.30/1.40/0.05,
1.80/2.80/0.06,
2.10/0.65/0.05,
2.55/1.75/0.11,
3.20/2.50/0.06,
3.65/0.90/0.05,
4.10/2.85/0.07,
4.55/1.45/0.06
}{
    \fill (\x,\y) circle (\r);
}

\draw[thick] (2.55,1.75) ellipse (0.45 and 0.30);
\draw[thick,dashed] (2.55,1.75) ellipse (0.75 and 0.52);
\draw[thick,dotted] (2.55,1.75) ellipse (1.05 and 0.75);
\draw[very thick] (2.55,1.75) circle (0.20);
\draw[thick] (3.70,0.35) -- (4.55,0.35);
\node[above,font=\scriptsize] at (4.12,0.35) {\(10^{\prime\prime}\)};
\end{scope}
\end{tikzpicture}

\caption{Controlled multi-panel astronomy image. Panel A represents an optical
observation, Panel B represents an infrared observation, and Panel C combines
the source positions with three contour levels. Circles identify the target;
solid, dashed, and dotted contours represent increasing spatial extent.}
\label{fig:astronomy-panels}

\begin{minipage}{0.96\textwidth}
\small
\textbf{Short text alternative.}
Three observations show the same astronomical field in optical, infrared, and
composite representations.

\textbf{Long description.}
All three panels show the same rectangular sky region. The target is near the
center and is marked by a thick circle. Panel A contains several compact
optical sources. Panel B shows the central target as a broader infrared
source. Panel C overlays solid, dashed, and dotted elliptical contours around
the central target. North points upward, east points right, and the scale bar
represents ten arcseconds. The panel labels, contour line styles, target
marker, orientation arrows, and scale bar provide information without relying
only on color.
\end{minipage}
\end{figure*}


% -------------------------------------------------
\subsubsection{Astronomical Light Curve}

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.68\columnwidth,
    xlabel={Time (\(\mathrm{h}\))},
    ylabel={Relative flux},
    xmin=0,
    xmax=8,
    ymin=0.955,
    ymax=1.012,
    grid=major,
    legend style={
        font=\scriptsize,
        draw=none,
        at={(0.03,0.03)},
        anchor=south west
    },
    tick label style={font=\scriptsize},
    label style={font=\small},
    yticklabel style={
        /pgf/number format/fixed,
        /pgf/number format/precision=2
    }
]
\addplot[
    black,
    dashed,
    thick
]
coordinates {
    (0,1.000)
    (1,1.000)
    (2,0.998)
    (3,0.985)
    (4,0.965)
    (5,0.985)
    (6,0.998)
    (7,1.000)
    (8,1.000)
};
\addlegendentry{Transit model}

\addplot[
    only marks,
    mark=*,
    mark size=1.7pt,
    black,
    error bars/.cd,
    y dir=both,
    y explicit
]
table[
    x=time,
    y=flux,
    y error=error,
    row sep=\\
] {
time flux error\\
0 1.002 0.004\\
1 0.999 0.004\\
2 0.997 0.004\\
3 0.983 0.004\\
4 0.964 0.005\\
5 0.986 0.004\\
6 0.999 0.004\\
7 1.001 0.004\\
8 1.000 0.004\\
};
\addlegendentry{Observed flux}
\end{axis}
\end{tikzpicture}

\caption{Example transit light curve. Filled circles with error bars represent
observed flux; the dashed line represents the fitted transit model.}
\label{fig:light-curve}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Relative flux temporarily decreases near four hours.

\textbf{Long description.}
Relative flux remains near \(1.00\) before decreasing to approximately
\(0.964\) at four hours. It then returns to approximately \(1.00\). This
symmetric decrease represents a possible transit. Vertical error bars show
measurement uncertainty.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Representative light-curve data.}
\label{tab:light-curve-data}
\small
\begin{tabular}{@{}rrr@{}}
\toprule
Time (\(\mathrm{h}\))
& Relative flux
& Uncertainty\\
\midrule
0 & 1.002 & 0.004\\
1 & 0.999 & 0.004\\
2 & 0.997 & 0.004\\
3 & 0.983 & 0.004\\
4 & 0.964 & 0.005\\
5 & 0.986 & 0.004\\
6 & 0.999 & 0.004\\
7 & 1.001 & 0.004\\
8 & 1.000 & 0.004\\
\bottomrule
\end{tabular}
\end{table}


% -------------------------------------------------
\subsubsection{Stellar Spectrum}

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.68\columnwidth,
    xlabel={Wavelength (\(\text{\AA}\))},
    ylabel={Normalized flux},
    xmin=6400,
    xmax=6700,
    ymin=0.35,
    ymax=1.65,
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\small},
    scaled x ticks=false
]
\addplot[
    black,
    thick
]
coordinates {
    (6400,1.02)
    (6440,1.00)
    (6470,0.97)
    (6495,0.52)
    (6520,0.98)
    (6545,1.00)
    (6563,1.52)
    (6580,1.02)
    (6620,0.99)
    (6660,1.01)
    (6700,1.00)
};

\draw[dashed]
    (axis cs:6495,0.35)
    --
    (axis cs:6495,0.75);

\node[
    font=\scriptsize,
    anchor=south
]
at (axis cs:6495,0.75)
{absorption};

\draw[dotted]
    (axis cs:6563,1.20)
    --
    (axis cs:6563,1.62);

\node[
    font=\scriptsize,
    anchor=south
]
at (axis cs:6563,1.53)
{emission};
\end{axis}
\end{tikzpicture}

\caption{Example stellar spectrum containing an absorption feature near
\(6495\) angstroms and an emission feature near \(6563\) angstroms.}
\label{fig:stellar-spectrum}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
The spectrum contains one strong absorption feature and one strong emission
feature.

\textbf{Long description.}
Normalized flux is close to \(1.0\) across most wavelengths. It decreases to
approximately \(0.52\) near \(6495\) angstroms, producing an absorption line.
It increases to approximately \(1.52\) near \(6563\) angstroms, producing an
emission line.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Representative spectrum values.}
\label{tab:spectrum-data}
\small
\begin{tabular}{@{}rrl@{}}
\toprule
Wavelength (\(\text{\AA}\))
& Normalized flux
& Interpretation\\
\midrule
6440 & 1.00 & Continuum\\
6470 & 0.97 & Continuum\\
6495 & 0.52 & Absorption\\
6520 & 0.98 & Continuum\\
6563 & 1.52 & Emission\\
6580 & 1.02 & Continuum\\
6620 & 0.99 & Continuum\\
\bottomrule
\end{tabular}
\end{table}


% -------------------------------------------------
\subsubsection{Hertzsprung--Russell Diagram}

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.74\columnwidth,
    xlabel={Temperature (\(\mathrm{K}\))},
    ylabel={Absolute magnitude},
    xmin=3500,
    xmax=14000,
    ymin=-5,
    ymax=12,
    x dir=reverse,
    y dir=reverse,
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\small},
    legend style={
        font=\scriptsize,
        draw=none,
        at={(0.02,0.02)},
        anchor=south west
    }
]
\addplot[
    only marks,
    mark=*,
    mark size=1.8pt,
    black
]
coordinates {
    (12000,-2)
    (10000,0)
    (8000,2)
    (6500,4)
    (5500,5.5)
    (4500,8)
    (3800,11)
};
\addlegendentry{Main sequence}

\addplot[
    only marks,
    mark=square*,
    mark size=2pt,
    black
]
coordinates {
    (5200,-1.0)
    (4600,-2.2)
    (4000,-3.0)
};
\addlegendentry{Giants}

\addplot[
    only marks,
    mark=triangle*,
    mark size=2.2pt,
    black
]
coordinates {
    (12500,9.5)
    (11000,10.5)
    (9500,11.5)
};
\addlegendentry{White dwarfs}
\end{axis}
\end{tikzpicture}

\caption{Controlled Hertzsprung--Russell diagram. Circles represent
main-sequence stars, squares represent giants, and triangles represent white
dwarfs.}
\label{fig:hr-diagram}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Three stellar groups occupy different regions of a temperature--magnitude
diagram.

\textbf{Long description.}
Temperature decreases from left to right. Absolute magnitude is also displayed
in reverse order, with brighter negative magnitudes near the top. Main-sequence
stars form a diagonal pattern from hot and bright at upper left to cool and
faint at lower right. Giants appear near the upper-right region. White dwarfs
appear near the lower-left region. Marker shape, rather than color alone,
identifies each group.
\end{minipage}
\end{figure}


% -------------------------------------------------
\subsubsection{Astronomical Source Catalog}

\begin{table*}[tbp]
\centering
\caption{Example astronomical source catalog containing uncertainties,
limits, and unavailable values.}
\label{tab:astronomy-catalog}
\small
\begin{tabular}{@{}lcccccl@{}}
\toprule
Source
& Right ascension
& Declination
& \(g\) magnitude
& Flux (\(\mu\mathrm{Jy}\))
& Redshift
& Note\\
\midrule
SRC-001
& 12:34:56.7
& \(-45\):18:22
& \(18.42\pm0.03\)
& \(3.21\pm0.14\)
& 0.125
& Detected\\

SRC-002
& 12:35:04.1
& \(-45\):17:49
& \(>22.10\)
& \(<0.18\)
& \(\ldots\)
& Upper limit\\

SRC-003
& 12:35:15.8
& \(-45\):19:03
& \(19.07\pm0.05\)
& \(2.48\pm0.17\)
& 0.138
& Detected\\

SRC-004
& 12:35:22.4
& \(+02\):14:08
& \(20.31\pm0.08\)
& \(0.91\pm0.12\)
& 0.207
& Low signal\\
\bottomrule
\end{tabular}

\begin{minipage}{0.96\textwidth}
\small
\textit{Table note.}
A greater-than sign in the magnitude column indicates that the source is
fainter than the stated limiting magnitude. A less-than sign in the flux
column indicates an upper limit. An ellipsis indicates that no redshift is
available; it does not mean zero.
\end{minipage}
\end{table*}


% =================================================
\section{Engineering}

\subsection{Electrical Circuit and Kirchhoff's Current Law}

Consider a voltage divider with source voltage \(V_s\), resistors \(R_1\) and
\(R_2\), and output voltage \(V_o\).

\begin{figure}[tbp]
\centering
\begin{tikzpicture}[
    component/.style={
        draw,
        minimum width=1.05cm,
        minimum height=0.48cm,
        font=\small
    },
    flow/.style={
        -{Stealth[length=2mm]},
        thick
    },
    font=\small
]
\node[draw,circle,minimum size=0.85cm] (source) at (0,1.35) {};
\node at (-0.13,1.55) {\scriptsize \(+\)};
\node at (-0.13,1.15) {\scriptsize \(-\)};
\node[left=2mm of source] {\(V_s\)};

\node[component] (r1) at (1.65,2.55) {\(R_1\)};
\node[component] (r2) at (3.30,1.25) {\(R_2\)};

\draw[thick] (source.north) -- (0,2.55) -- (r1.west);
\draw[thick] (r1.east) -- (3.30,2.55) -- (r2.north);
\draw[thick] (r2.south) -- (3.30,0.15) -- (0,0.15)
    -- (source.south);

\fill (3.30,2.55) circle (1.8pt);
\node[right] at (3.30,2.55) {\(V_o\)};

\draw[flow] (0.65,2.90) -- (2.15,2.90);
\node[above] at (1.40,2.90) {\(i\)};

\draw[thick] (1.65,0.15) -- (1.65,-0.05);
\draw[thick] (1.30,-0.05) -- (2.00,-0.05);
\draw[thick] (1.40,-0.18) -- (1.90,-0.18);
\draw[thick] (1.50,-0.31) -- (1.80,-0.31);
\node[below] at (1.65,-0.31) {ground};
\end{tikzpicture}

\caption{Voltage-divider circuit. Current \(i\) flows from the source through
\(R_1\). The output node connects \(R_1\) to \(R_2\), and \(R_2\) connects the
output node to ground.}
\label{fig:voltage-divider}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
A voltage source and two series resistors form a voltage divider.

\textbf{Long description.}
The positive terminal of source \(V_s\) connects to \(R_1\). The other terminal
of \(R_1\) is the output node \(V_o\). Resistor \(R_2\) connects the output node
to ground. The negative terminal of the source also connects to ground. Current
\(i\) flows from the source through \(R_1\) toward the output node.
\end{minipage}
\end{figure}

Kirchhoff's current law at the output node gives

\begin{align}
\frac{V_s-V_o}{R_1}
    &=
    \frac{V_o}{R_2},\\
R_2(V_s-V_o)
    &=
    R_1V_o,\\
R_2V_s-R_2V_o
    &=
    R_1V_o,\\
R_2V_s
    &=
    (R_1+R_2)V_o,\\
V_o
    &=
    \frac{R_2}{R_1+R_2}V_s.
\end{align}

For \(V_s=12\,\mathrm{V}\), \(R_1=2\,\mathrm{k\Omega}\), and
\(R_2=1\,\mathrm{k\Omega}\),

\begin{align}
V_o
    &=
    \frac{1}{2+1}(12)\\
    &=
    4\,\mathrm{V}.
\end{align}

\begin{table}[tbp]
\centering
\caption{Voltage-divider component connections.}
\label{tab:voltage-divider-connections}
\small
\begin{tabular}{@{}llll@{}}
\toprule
Component & From & To & Value\\
\midrule
Source & Ground & Input node & \(12\,\mathrm{V}\)\\
\(R_1\) & Input node & Output node & \(2\,\mathrm{k\Omega}\)\\
\(R_2\) & Output node & Ground & \(1\,\mathrm{k\Omega}\)\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{State-Space and Feedback-Control Models}

A continuous-time linear system may be written as

\begin{align}
\dot{\mathbf{x}}(t)
    &=
    A\mathbf{x}(t)+B\mathbf{u}(t),\\
\mathbf{y}(t)
    &=
    C\mathbf{x}(t)+D\mathbf{u}(t),
\end{align}

where

\begin{align}
A&=
\begin{bmatrix}
0 & 1\\
-2 & -3
\end{bmatrix},
&
B&=
\begin{bmatrix}
0\\
1
\end{bmatrix},\\
C&=
\begin{bmatrix}
1 & 0
\end{bmatrix},
&
D&=0.
\end{align}

The transfer function can be derived as

\begin{align}
G(s)
    &=
    C(sI-A)^{-1}B+D,\\
sI-A
    &=
    \begin{bmatrix}
    s & -1\\
    2 & s+3
    \end{bmatrix},\\
(sI-A)^{-1}
    &=
    \frac{1}{s^{2}+3s+2}
    \begin{bmatrix}
    s+3 & 1\\
    -2 & s
    \end{bmatrix},\\
G(s)
    &=
    \frac{1}{s^{2}+3s+2}.
\end{align}

A closed-loop control system is shown in
Figure~\ref{fig:closed-loop-control}.

\begin{figure}[tbp]
\centering
\begin{tikzpicture}[
    block/.style={
        draw,
        minimum width=1.05cm,
        minimum height=0.58cm,
        align=center,
        font=\scriptsize
    },
    sum/.style={
        draw,
        circle,
        minimum size=0.52cm,
        inner sep=0pt
    },
    flow/.style={
        -{Stealth[length=2mm]},
        thick
    },
    font=\scriptsize
]
\node[sum] (sum) at (0,0) {\(\sum\)};
\node[block] (controller) at (1.45,0) {Controller\\\(K(s)\)};
\node[block] (plant) at (3.05,0) {Plant\\\(G(s)\)};
\node[block] (sensor) at (2.25,-1.25) {Sensor\\\(H(s)\)};

\draw[flow] (-1.05,0) -- (sum.west)
    node[midway,above] {\(R(s)\)};
\draw[flow] (sum.east) -- (controller.west)
    node[midway,above] {\(E(s)\)};
\draw[flow] (controller.east) -- (plant.west)
    node[midway,above] {\(U(s)\)};
\draw[flow] (plant.east) -- (4.25,0)
    node[midway,above] {\(Y(s)\)};

\fill (4.05,0) circle (1.6pt);

\draw[flow] (4.05,0) -- (4.05,-1.25) -- (sensor.east);
\draw[flow] (sensor.west) -- (0,-1.25) -- (sum.south);

\node at (-0.18,0.20) {\(+\)};
\node at (-0.18,-0.22) {\(-\)};
\node[below] at (3.45,-1.25) {feedback};
\end{tikzpicture}

\caption{Closed-loop control system with negative feedback.}
\label{fig:closed-loop-control}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
A controller and plant form a forward path with sensor-based negative feedback.

\textbf{Long description.}
The reference \(R(s)\) enters the positive input of a summing junction. The error
\(E(s)\) passes through controller \(K(s)\), producing control signal \(U(s)\).
The plant \(G(s)\) produces output \(Y(s)\). The output also passes through sensor
\(H(s)\) and returns to the negative input of the summing junction.
\end{minipage}
\end{figure}

The closed-loop transfer function is obtained from

\begin{align}
E(s)
    &=
    R(s)-H(s)Y(s),\\
Y(s)
    &=
    G(s)K(s)E(s),\\
Y(s)
    &=
    G(s)K(s)
    \left[
    R(s)-H(s)Y(s)
    \right],\\
\left[
1+G(s)K(s)H(s)
\right]Y(s)
    &=
    G(s)K(s)R(s),\\
\frac{Y(s)}{R(s)}
    &=
    \frac{G(s)K(s)}
    {1+G(s)K(s)H(s)}.
\end{align}

An actuator magnitude limit \(u_{\max}>0\) may be represented by

\[
\operatorname{sat}(v)
=
\begin{cases}
-u_{\max},
    & v<-u_{\max},\\
v,
    & -u_{\max}\leq v\leq u_{\max},\\
u_{\max},
    & v>u_{\max}.
\end{cases}
\]

The implemented control input is

\[
u(t)
=
\operatorname{sat}
\left(
-K\mathbf{x}(t)
\right).
\]


% =================================================
\subsection{Bode Magnitude and Phase Response}

For the first-order system

\[
G(s)=\frac{1}{s+1},
\]

the frequency response is

\begin{align}
\left|G(j\omega)\right|
    &=
    \frac{1}{\sqrt{1+\omega^{2}}},\\
M(\omega)
    &=
    20\log_{10}
    \left|G(j\omega)\right|,\\
\phi(\omega)
    &=
    -\tan^{-1}(\omega).
\end{align}

\begin{figure}[tbp]
\centering

\begin{tikzpicture}
\begin{axis}[
    width=0.97\columnwidth,
    height=0.52\columnwidth,
    xmode=log,
    xlabel={Angular frequency \(\omega\) (\(\mathrm{rad\,s^{-1}}\))},
    ylabel={Magnitude (\(\mathrm{dB}\))},
    xmin=0.1,
    xmax=10,
    ymin=-22,
    ymax=2,
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\scriptsize}
]
\addplot[
    black,
    thick,
    mark=*
]
coordinates {
    (0.1,-0.04)
    (0.2,-0.17)
    (0.5,-0.97)
    (1.0,-3.01)
    (2.0,-6.99)
    (5.0,-14.15)
    (10.0,-20.04)
};

\draw[dashed]
    (axis cs:1,-22)
    --
    (axis cs:1,2);

\node[
    font=\scriptsize,
    anchor=south west
]
at (axis cs:1,-18)
{\(\omega_c=1\)};
\end{axis}
\end{tikzpicture}

\vspace{2mm}

\begin{tikzpicture}
\begin{axis}[
    width=0.97\columnwidth,
    height=0.52\columnwidth,
    xmode=log,
    xlabel={Angular frequency \(\omega\) (\(\mathrm{rad\,s^{-1}}\))},
    ylabel={Phase (\(^{\circ}\))},
    xmin=0.1,
    xmax=10,
    ymin=-95,
    ymax=5,
    ytick={-90,-60,-45,-30,0},
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\scriptsize}
]
\addplot[
    black,
    thick,
    mark=square*
]
coordinates {
    (0.1,-5.7)
    (0.2,-11.3)
    (0.5,-26.6)
    (1.0,-45.0)
    (2.0,-63.4)
    (5.0,-78.7)
    (10.0,-84.3)
};

\draw[dashed]
    (axis cs:1,-95)
    --
    (axis cs:1,5);
\end{axis}
\end{tikzpicture}

\caption{Bode response of \(G(s)=1/(s+1)\). The upper panel shows magnitude in
decibels, and the lower panel shows phase in degrees. Both panels use a
logarithmic frequency axis.}
\label{fig:bode-response}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Magnitude decreases and phase approaches negative \(90\) degrees as frequency
increases.

\textbf{Long description.}
Frequency increases logarithmically from \(0.1\) to \(10\) radians per second.
Magnitude begins near zero decibels, equals approximately negative \(3.01\)
decibels at one radian per second, and decreases to approximately negative
\(20.04\) decibels. Phase decreases from approximately negative \(5.7\) degrees
to negative \(84.3\) degrees. The cutoff frequency is one radian per second.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Numerical values represented in the Bode plots.}
\label{tab:bode-data}
\small
\begin{tabular}{@{}rrr@{}}
\toprule
\(\omega\)
& Magnitude (\(\mathrm{dB}\))
& Phase (\(^{\circ}\))\\
\midrule
0.1  & \(-0.04\)  & \(-5.7\)\\
0.2  & \(-0.17\)  & \(-11.3\)\\
0.5  & \(-0.97\)  & \(-26.6\)\\
1.0  & \(-3.01\)  & \(-45.0\)\\
2.0  & \(-6.99\)  & \(-63.4\)\\
5.0  & \(-14.15\) & \(-78.7\)\\
10.0 & \(-20.04\) & \(-84.3\)\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Beam Loading and Free-Body Diagram}

Consider a simply supported beam of length \(L\) with a downward point load \(P\)
at its midpoint.

\begin{figure}[tbp]
\centering
\begin{tikzpicture}[
    force/.style={
        -{Stealth[length=2.5mm]},
        very thick
    },
    dimension/.style={
        {Stealth[length=1.8mm]}-{Stealth[length=1.8mm]},
        thin
    },
    font=\small
]
\draw[very thick] (0,1.15) -- (5,1.15);

% Pin support
\draw[thick] (0,1.10) -- (-0.32,0.55) -- (0.32,0.55) -- cycle;
\draw[thick] (-0.45,0.48) -- (0.45,0.48);

% Roller support
\draw[thick] (5,1.10) -- (4.68,0.62) -- (5.32,0.62) -- cycle;
\draw[thick] (4.82,0.50) circle (0.10);
\draw[thick] (5.18,0.50) circle (0.10);
\draw[thick] (4.60,0.35) -- (5.40,0.35);

% Applied load
\draw[force] (2.5,2.20) -- (2.5,1.25);
\node[above] at (2.5,2.20) {\(P\)};

% Reactions
\draw[force] (0,0.10) -- (0,1.00);
\node[left] at (0,0.55) {\(R_A\)};

\draw[force] (5,0.10) -- (5,1.00);
\node[right] at (5,0.55) {\(R_B\)};

% Coordinate
\draw[-{Stealth[length=2mm]}] (0,1.45) -- (1.15,1.45);
\node[above] at (1.15,1.45) {\(x\)};

% Dimensions
\draw[dimension] (0,-0.25) -- (2.5,-0.25);
\draw[dimension] (2.5,-0.25) -- (5,-0.25);
\node[below] at (1.25,-0.25) {\(L/2\)};
\node[below] at (3.75,-0.25) {\(L/2\)};

\draw[thin] (0,0.05) -- (0,-0.40);
\draw[thin] (2.5,1.05) -- (2.5,-0.40);
\draw[thin] (5,0.05) -- (5,-0.40);

\node[below] at (0,-0.48) {support A};
\node[below] at (5,-0.48) {support B};
\end{tikzpicture}

\caption{Free-body diagram of a simply supported beam with a midpoint load.}
\label{fig:beam-free-body}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
A midpoint load acts downward on a beam with upward reactions at both ends.

\textbf{Long description.}
A horizontal beam extends from pin support A at \(x=0\) to roller support B at
\(x=L\). A downward force \(P\) acts at \(x=L/2\). Reactions \(R_A\) and \(R_B\)
act upward at the two supports. The positive \(x\)-direction points from support
A toward support B.
\end{minipage}
\end{figure}

Force and moment equilibrium give

\begin{align}
\sum F_y
    &=
    R_A+R_B-P=0,\\
\sum M_A
    &=
    R_BL-P\frac{L}{2}=0,\\
R_A
    &=
    R_B=\frac{P}{2}.
\end{align}

The internal shear force is

\[
V(x)
=
\begin{cases}
\dfrac{P}{2},
    & 0<x<\dfrac{L}{2},\\[5pt]
-\dfrac{P}{2},
    & \dfrac{L}{2}<x<L.
\end{cases}
\]

The bending moment is

\[
M(x)
=
\begin{cases}
\dfrac{Px}{2},
    & 0\leq x\leq\dfrac{L}{2},\\[5pt]
\dfrac{P(L-x)}{2},
    & \dfrac{L}{2}\leq x\leq L.
\end{cases}
\]

The maximum moment occurs at the midpoint:

\[
M_{\max}
=
M\left(\frac{L}{2}\right)
=
\frac{PL}{4}.
\]


% =================================================
\subsection{CAD Drawing, Dimensions, and Tolerances}

Figure~\ref{fig:cad-drawing} represents a rectangular plate containing one
centered through-hole. All dimensions are in millimeters.

\begin{figure*}[tbp]
\centering
\begin{tikzpicture}[
    x=1cm,
    y=1cm,
    font=\scriptsize,
    dimension/.style={
        {Stealth[length=1.7mm]}-{Stealth[length=1.7mm]},
        thin
    },
    centerline/.style={
        dash pattern=on 7pt off 2pt on 1pt off 2pt,
        thin
    },
    hidden/.style={
        dashed,
        thin
    }
]
% ---------------- Front view
\begin{scope}
\draw[very thick] (0,0) rectangle (5,3);
\draw[very thick] (2.5,1.5) circle (0.5);

\draw[centerline] (1.65,1.5) -- (3.35,1.5);
\draw[centerline] (2.5,0.65) -- (2.5,2.35);

\node[above,font=\small\bfseries] at (2.5,3.55) {Front view};

\draw[thin] (0,0) -- (0,-0.65);
\draw[thin] (5,0) -- (5,-0.65);
\draw[dimension] (0,-0.50) -- (5,-0.50);
\node[fill=white] at (2.5,-0.50) {\(100.00\)};

\draw[thin] (0,0) -- (-0.65,0);
\draw[thin] (0,3) -- (-0.65,3);
\draw[dimension] (-0.50,0) -- (-0.50,3);
\node[fill=white,rotate=90] at (-0.50,1.5) {\(60.00\)};

\draw[-{Stealth[length=1.8mm]}]
    (4.30,2.55)
    --
    (2.85,1.85);
\node[anchor=west] at (4.30,2.55)
{\(\varnothing 20.00^{+0.02}_{-0.00}\)};
\end{scope}

% ---------------- Top view
\begin{scope}[xshift=6.25cm]
\draw[very thick] (0,0) rectangle (5,0.65);
\draw[hidden] (2.0,0) -- (2.0,0.65);
\draw[hidden] (3.0,0) -- (3.0,0.65);
\draw[centerline] (2.5,-0.25) -- (2.5,0.90);

\node[above,font=\small\bfseries] at (2.5,1.25) {Top view};

\draw[thin] (5,0) -- (5.65,0);
\draw[thin] (5,0.65) -- (5.65,0.65);
\draw[dimension] (5.50,0) -- (5.50,0.65);
\node[fill=white,rotate=90] at (5.50,0.325) {\(10.00\)};
\end{scope}

% ---------------- Right-side view
\begin{scope}[xshift=12.75cm]
\draw[very thick] (0,0) rectangle (3,0.65);
\draw[hidden] (1.0,0) -- (1.0,0.65);
\draw[hidden] (2.0,0) -- (2.0,0.65);
\draw[centerline] (1.5,-0.25) -- (1.5,0.90);

\node[above,font=\small\bfseries] at (1.5,1.25) {Right-side view};
\end{scope}
\end{tikzpicture}

\caption{Orthographic drawing of a rectangular plate. The front view shows the
plate length, width, hole diameter, and centerlines. The top and right-side
views show plate thickness and hidden edges of the through-hole.}
\label{fig:cad-drawing}

\begin{minipage}{0.96\textwidth}
\small
\textbf{Short text alternative.}
Three orthographic views describe a rectangular plate with one centered
through-hole.

\textbf{Long description.}
The front view is a \(100\)-millimeter by \(60\)-millimeter rectangle. A
\(20\)-millimeter-diameter through-hole is centered \(50\) millimeters from
either end and \(30\) millimeters from the top or bottom. The hole diameter has
an upper tolerance of \(0.02\) millimeter and a lower tolerance of zero. The
plate thickness is \(10\) millimeters. Long-short centerlines identify the hole
center, while dashed hidden lines show the hole in the top and side views.
\end{minipage}
\end{figure*}

\begin{table*}[tbp]
\centering
\caption{Critical dimensions and features in the technical drawing.}
\label{tab:cad-dimensions}
\small
\begin{tabular}{@{}lllll@{}}
\toprule
Feature
& Nominal value
& Upper tolerance
& Lower tolerance
& Description\\
\midrule
Plate length
& \(100.00\,\mathrm{mm}\)
& \(+0.10\,\mathrm{mm}\)
& \(-0.10\,\mathrm{mm}\)
& Horizontal front-view dimension\\
Plate width
& \(60.00\,\mathrm{mm}\)
& \(+0.10\,\mathrm{mm}\)
& \(-0.10\,\mathrm{mm}\)
& Vertical front-view dimension\\
Plate thickness
& \(10.00\,\mathrm{mm}\)
& \(+0.05\,\mathrm{mm}\)
& \(-0.05\,\mathrm{mm}\)
& Top and side views\\
Hole diameter
& \(20.00\,\mathrm{mm}\)
& \(+0.02\,\mathrm{mm}\)
& \(-0.00\,\mathrm{mm}\)
& Centered through-hole\\
Hole center
& \(50.00,\ 30.00\,\mathrm{mm}\)
& Not applicable
& Not applicable
& Measured from lower-left corner\\
\bottomrule
\end{tabular}
\end{table*}


% =================================================
\subsection{Material Stress--Strain Response}

Engineering stress and strain are defined as

\begin{align}
\sigma
    &=
    \frac{F}{A_0},\\
\varepsilon
    &=
    \frac{\Delta L}{L_0}.
\end{align}

Within the linear elastic region, Young's modulus is

\[
E
=
\frac{d\sigma}{d\varepsilon}.
\]

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.72\columnwidth,
    xlabel={Engineering strain \(\varepsilon\) (\%)},
    ylabel={Engineering stress \(\sigma\) (\(\mathrm{MPa}\))},
    xmin=0,
    xmax=22,
    ymin=0,
    ymax=500,
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\scriptsize}
]
\addplot[
    black,
    thick,
    mark=*
]
coordinates {
    (0.0,0)
    (0.1,100)
    (0.2,200)
    (0.25,250)
    (2.0,300)
    (5.0,380)
    (10.0,450)
    (15.0,420)
    (20.0,350)
};

\node[font=\scriptsize,anchor=west]
    at (axis cs:0.25,250) {yield};

\node[font=\scriptsize,anchor=south]
    at (axis cs:10,450) {ultimate strength};

\node[font=\scriptsize,anchor=west]
    at (axis cs:20,350) {fracture};
\end{axis}
\end{tikzpicture}

\caption{Controlled engineering stress--strain curve showing elastic behavior,
yielding, strain hardening, ultimate tensile strength, necking, and fracture.}
\label{fig:stress-strain}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Stress initially increases linearly, reaches a maximum, and then decreases
before fracture.

\textbf{Long description.}
Stress increases linearly from zero to approximately \(250\) megapascals at
\(0.25\) percent strain. This is followed by plastic deformation and strain
hardening. Ultimate tensile strength is approximately \(450\) megapascals at
\(10\) percent strain. Stress then decreases during necking until fracture at
approximately \(20\) percent strain and \(350\) megapascals.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Representative stress--strain values and regions.}
\label{tab:stress-strain-data}
\small
\begin{tabular}{@{}rrl@{}}
\toprule
Strain (\%)
& Stress (\(\mathrm{MPa}\))
& Region or event\\
\midrule
0.00  & 0   & Initial state\\
0.10  & 100 & Elastic region\\
0.20  & 200 & Elastic region\\
0.25  & 250 & Yield point\\
2.00  & 300 & Plastic region\\
5.00  & 380 & Strain hardening\\
10.00 & 450 & Ultimate strength\\
15.00 & 420 & Necking\\
20.00 & 350 & Fracture\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Chemical-Process Flow and Recycle Loop}

A simplified chemical process contains a mixer, reactor, separator, product
stream, and recycle stream.

\begin{figure*}[tbp]
\centering
\begin{tikzpicture}[
    process/.style={
        draw,
        rounded corners,
        minimum width=2.1cm,
        minimum height=0.85cm,
        align=center,
        font=\small
    },
    flow/.style={
        -{Stealth[length=2.4mm]},
        very thick
    },
    font=\small
]
\node (feed) at (0,0) {Feed};
\node[process] (mixer) at (2.5,0) {M-101\\Mixer};
\node[process] (reactor) at (6.0,0) {R-101\\Reactor};
\node[process] (separator) at (9.5,0) {S-101\\Separator};
\node (product) at (12.6,0) {Product};

\draw[flow] (feed) -- (mixer.west)
    node[midway,above] {Stream 1};
\draw[flow] (mixer.east) -- (reactor.west)
    node[midway,above] {Stream 2};
\draw[flow] (reactor.east) -- (separator.west)
    node[midway,above] {Stream 3};
\draw[flow] (separator.east) -- (product)
    node[midway,above] {Stream 4};

\draw[flow]
    (separator.south)
    -- (9.5,-1.35)
    -- (2.5,-1.35)
    -- (mixer.south);

\node[below] at (6.0,-1.35) {Stream 5: recycle};
\end{tikzpicture}

\caption{Chemical-process flow diagram with a recycle loop. Material flows from
the feed through the mixer, reactor, and separator. Part of the separator output
returns to the mixer.}
\label{fig:chemical-process}

\begin{minipage}{0.96\textwidth}
\small
\textbf{Short text alternative.}
A feed passes through a mixer, reactor, and separator; one separator stream is
recycled to the mixer.

\textbf{Long description.}
Stream 1 carries fresh feed into mixer M-101. The mixer combines Stream 1 with
recycle Stream 5. Stream 2 carries the combined material to reactor R-101.
Stream 3 carries reactor output to separator S-101. The separator divides the
material into product Stream 4 and recycle Stream 5. Stream 5 travels from the
separator back to the mixer, creating a closed recycle loop.
\end{minipage}
\end{figure*}

At steady state, the total mass balances are

\begin{align}
\dot{m}_1+\dot{m}_5
    &=
    \dot{m}_2,\\
\dot{m}_2
    &=
    \dot{m}_3,\\
\dot{m}_3
    &=
    \dot{m}_4+\dot{m}_5.
\end{align}

Combining these equations gives the overall process balance

\[
\dot{m}_1=\dot{m}_4.
\]

\begin{table*}[tbp]
\centering
\caption{Structured description of the chemical-process streams.}
\label{tab:process-streams}
\small
\begin{tabular}{@{}lllll@{}}
\toprule
Stream & From & To & Direction & Purpose\\
\midrule
1 & Fresh-feed source & Mixer M-101 & Forward & Supplies new material\\
2 & Mixer M-101 & Reactor R-101 & Forward & Carries combined feed\\
3 & Reactor R-101 & Separator S-101 & Forward & Carries reactor output\\
4 & Separator S-101 & Product outlet & Forward & Removes final product\\
5 & Separator S-101 & Mixer M-101 & Reverse/recycle & Returns unprocessed material\\
\bottomrule
\end{tabular}
\end{table*}


% =================================================
\subsection{Robotic Coordinate Frames and Transformations}

The homogeneous transformation from coordinate frame \(B\) to coordinate frame
\(A\) is

\[
{}^{A}\mathbf{T}_{B}
=
\begin{bmatrix}
{}^{A}\mathbf{R}_{B}
&
{}^{A}\mathbf{p}_{B}\\
\mathbf{0}^{T}
&
1
\end{bmatrix}.
\]

A point expressed in frame \(B\) is transformed into frame \(A\) using

\[
{}^{A}\mathbf{p}
=
{}^{A}\mathbf{R}_{B}
\,{}^{B}\mathbf{p}
+
{}^{A}\mathbf{p}_{B}.
\]

For a planar rotation through angle \(\theta\),

\[
{}^{A}\mathbf{R}_{B}
=
\begin{bmatrix}
\cos\theta & -\sin\theta & 0\\
\sin\theta & \cos\theta  & 0\\
0          & 0           & 1
\end{bmatrix}.
\]

\begin{figure}[tbp]
\centering
\begin{tikzpicture}[
    axis/.style={
        -{Stealth[length=2.2mm]},
        very thick
    },
    transform/.style={
        -{Stealth[length=2mm]},
        dashed,
        thick
    },
    font=\small
]
% Frame A
\coordinate (A) at (0,0);
\draw[axis] (A) -- (1.35,0)
    node[right] {\(x_A\)};
\draw[axis] (A) -- (0,1.35)
    node[above] {\(y_A\)};
\draw[thick] (A) circle (0.14);
\fill (A) circle (1.6pt);
\node[below left] at (A) {\(O_A\)};
\node[above left] at (-0.05,0.18) {\(z_A\)};

% Frame B
\coordinate (B) at (2.75,1.10);
\draw[axis] (B) -- ++(25:1.25)
    node[right] {\(x_B\)};
\draw[axis] (B) -- ++(115:1.25)
    node[above] {\(y_B\)};
\draw[thick] (B) circle (0.14);
\fill (B) circle (1.6pt);
\node[below right] at (B) {\(O_B\)};
\node[above left] at (2.70,1.30) {\(z_B\)};

% Translation
\draw[transform] (A) -- (B)
    node[midway,below right] {\({}^{A}\mathbf{p}_{B}\)};

\node at (1.75,1.60) {\(\theta\)};
\end{tikzpicture}

\caption{Two robotic coordinate frames. Frame \(B\) is translated and rotated
relative to frame \(A\). A circle with a central dot represents each positive
\(z\)-axis pointing out of the page.}
\label{fig:robot-frames}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Coordinate frame \(B\) is translated and rotated counterclockwise from frame
\(A\).

\textbf{Long description.}
Frame \(A\) has origin \(O_A\), with positive \(x_A\) pointing right, positive
\(y_A\) pointing upward, and positive \(z_A\) pointing out of the page. Frame
\(B\) has origin \(O_B\), located above and to the right of \(O_A\). Its
\(x_B\)- and \(y_B\)-axes are rotated counterclockwise through angle \(\theta\).
The vector from \(O_A\) to \(O_B\) is
\({}^{A}\mathbf{p}_{B}\).
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Coordinate-frame notation used in the transformation.}
\label{tab:coordinate-frames}
\small
\begin{tabular}{@{}ll@{}}
\toprule
Symbol & Meaning\\
\midrule
\({}^{A}\mathbf{T}_{B}\)
& Transform from frame \(B\) to frame \(A\)\\
\({}^{A}\mathbf{R}_{B}\)
& Rotation of frame \(B\) relative to frame \(A\)\\
\({}^{A}\mathbf{p}_{B}\)
& Position of origin \(B\), expressed in frame \(A\)\\
\({}^{B}\mathbf{p}\)
& Point coordinates expressed in frame \(B\)\\
\({}^{A}\mathbf{p}\)
& Same point expressed in frame \(A\)\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Finite-Element Simulation Result}

A finite-element model may approximate displacement using

\[
\mathbf{K}\mathbf{d}
=
\mathbf{f},
\]

where \(\mathbf{K}\) is the global stiffness matrix, \(\mathbf{d}\) is the nodal
displacement vector, and \(\mathbf{f}\) is the applied nodal-force vector.

For a fixed boundary,

\[
\mathbf{d}
=
\mathbf{0}
\qquad
\text{on }
\Gamma_{\mathrm{fixed}}.
\]

\begin{figure}[tbp]
\centering
\begin{tikzpicture}[
    force/.style={
        -{Stealth[length=2.4mm]},
        very thick
    },
    font=\scriptsize
]
% Element cells
\fill[black!45] (0,1) rectangle (1,2);
\fill[black!38] (1,1) rectangle (2,2);
\fill[black!30] (2,1) rectangle (3,2);
\fill[black!20] (3,1) rectangle (4,2);

\fill[black!42] (0,0) rectangle (1,1);
\fill[black!34] (1,0) rectangle (2,1);
\fill[black!26] (2,0) rectangle (3,1);
\fill[black!16] (3,0) rectangle (4,1);

% Mesh
\draw[very thick] (0,0) rectangle (4,2);
\foreach \x in {1,2,3}{
    \draw[thick] (\x,0) -- (\x,2);
}
\draw[thick] (0,1) -- (4,1);

% Numerical stress labels
\node at (0.5,1.5) {\(120\)};
\node at (1.5,1.5) {\(105\)};
\node at (2.5,1.5) {\(85\)};
\node at (3.5,1.5) {\(65\)};

\node at (0.5,0.5) {\(115\)};
\node at (1.5,0.5) {\(95\)};
\node at (2.5,0.5) {\(75\)};
\node at (3.5,0.5) {\(55\)};

% Fixed boundary
\draw[very thick] (0,0) -- (0,2);
\foreach \y in {0.0,0.3,0.6,0.9,1.2,1.5,1.8}{
    \draw[thin] (-0.28,\y-0.18) -- (0,\y);
}
\node[rotate=90] at (-0.55,1) {fixed};

% Applied load
\draw[force] (4,2.85) -- (4,2.10);
\node[above] at (4,2.85) {\(F_y\)};

\node[below] at (2,-0.28)
{Element stress values in \(\mathrm{MPa}\)};
\end{tikzpicture}

\caption{Controlled finite-element mesh with a fixed left boundary and a
downward force at the upper-right corner. Numerical labels give representative
von Mises stress values in megapascals.}
\label{fig:fea-result}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Stress is greatest near the fixed boundary and decreases toward the loaded
right edge.

\textbf{Long description.}
A rectangular model is divided into eight elements arranged in two rows and
four columns. The entire left edge is fixed. A downward force acts at the
upper-right corner. Representative stress values range from \(120\)
megapascals in the upper-left element to \(55\) megapascals in the lower-right
element. Darker shading corresponds to higher stress, but every element also
contains a numerical value so that color or shading is not required.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Representative finite-element results.}
\label{tab:fea-results}
\small
\begin{tabular}{@{}lrr@{}}
\toprule
Region
& Stress (\(\mathrm{MPa}\))
& Displacement (\(\mathrm{mm}\))\\
\midrule
Upper left  & 120 & 0.00\\
Lower left  & 115 & 0.00\\
Upper center-left & 105 & 0.12\\
Lower center-left & 95  & 0.10\\
Upper center-right & 85 & 0.28\\
Lower center-right & 75 & 0.24\\
Upper right & 65 & 0.46\\
Lower right & 55 & 0.39\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\section{Economics and Finance}

\subsection{Market Equilibrium and a Per-Unit Tax}

Let \(Q_d\) denote quantity demanded, \(Q_s\) quantity supplied, \(P_b\) the
price paid by buyers, and \(P_s\) the price received by sellers. Consider

\begin{align}
Q_d
    &=
    100-2P_b,\\
Q_s
    &=
    20+2P_s.
\end{align}

Before a tax, \(P_b=P_s=P\). The competitive equilibrium is obtained from

\begin{align}
Q_d
    &=
    Q_s,\\
100-2P
    &=
    20+2P,\\
80
    &=
    4P,\\
P^{*}
    &=
    20,\\
Q^{*}
    &=
    60.
\end{align}

Now impose a per-unit tax of \(\tau=10\), so that

\[
P_b-P_s=\tau.
\]

Writing both prices as functions of the common traded quantity \(Q\) gives

\begin{align}
P_b
    &=
    \frac{100-Q}{2},\\
P_s
    &=
    \frac{Q-20}{2}.
\end{align}

The after-tax equilibrium follows from

\begin{align}
\frac{100-Q}{2}
-
\frac{Q-20}{2}
    &=
    10,\\
\frac{120-2Q}{2}
    &=
    10,\\
60-Q
    &=
    10,\\
Q_{\tau}
    &=
    50,\\
P_b
    &=
    25,\\
P_s
    &=
    15.
\end{align}

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.76\columnwidth,
    xlabel={Quantity \(Q\)},
    ylabel={Price \(P\)},
    xmin=0,
    xmax=105,
    ymin=0,
    ymax=55,
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\scriptsize},
    clip=false
]
\addplot[
    black,
    very thick,
    domain=0:100,
    samples=2
]
{50-0.5*x};

\addplot[
    black,
    very thick,
    dashed,
    domain=20:105,
    samples=2
]
{-10+0.5*x};

\addplot[
    black,
    thick,
    dotted,
    domain=0:105,
    samples=2
]
{0.5*x};

\addplot[
    only marks,
    mark=*,
    mark size=2.2pt,
    black
]
coordinates {(60,20) (50,25) (50,15)};

\draw[
    {Stealth[length=1.8mm]}-{Stealth[length=1.8mm]},
    thick
]
(axis cs:50,15) -- (axis cs:50,25);

\node[font=\scriptsize,anchor=west]
    at (axis cs:73,12) {demand};
\node[font=\scriptsize,anchor=west]
    at (axis cs:82,32) {supply before tax};
\node[font=\scriptsize,anchor=west]
    at (axis cs:66,39) {supply plus tax};
\node[font=\scriptsize,anchor=south west]
    at (axis cs:60,20) {\(E_0\)};
\node[font=\scriptsize,anchor=south east]
    at (axis cs:50,25) {\(P_b=25\)};
\node[font=\scriptsize,anchor=north east]
    at (axis cs:50,15) {\(P_s=15\)};
\node[font=\scriptsize,anchor=west]
    at (axis cs:50,20) {tax wedge \(=10\)};
\end{axis}
\end{tikzpicture}

\caption{Supply and demand before and after a per-unit tax. The solid demand
curve and dashed pre-tax supply curve meet at \(Q=60\) and \(P=20\). After the
tax, trade falls to \(Q=50\); buyers pay \(25\), and sellers receive \(15\).}
\label{fig:econ-tax-equilibrium}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
A per-unit tax creates a ten-unit gap between buyer and seller prices and
reduces quantity from \(60\) to \(50\).

\textbf{Long description.}
Quantity is on the horizontal axis and price is on the vertical axis. Demand
slopes downward. Supply before tax slopes upward and is dashed. Supply plus tax
also slopes upward and is dotted. The pre-tax equilibrium is quantity \(60\)
and price \(20\). The after-tax quantity is \(50\), with buyer price \(25\) and
seller price \(15\). A vertical double-headed arrow at quantity \(50\) marks the
ten-unit tax wedge.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Market outcomes before and after the tax.}
\label{tab:econ-tax-outcomes}
\small
\begin{tabular}{@{}lrr@{}}
\toprule
Outcome
& Before tax
& After tax\\
\midrule
Quantity traded
& \(60\)
& \(50\)\\
Price paid by buyers
& \(20\)
& \(25\)\\
Price received by sellers
& \(20\)
& \(15\)\\
Tax per unit
& \(0\)
& \(10\)\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Consumer Choice and Constrained Optimization}

A consumer chooses quantities \(x\) and \(y\) to maximize Cobb--Douglas utility
subject to a budget constraint:

\[
\begin{aligned}
\max_{x,y>0}
\quad
&U(x,y)=x^{\alpha}y^{1-\alpha}\\
\text{subject to}
\quad
&p_xx+p_yy=m,
\end{aligned}
\]

where \(p_x\) and \(p_y\) are prices, \(m\) is income, and
\(0<\alpha<1\). Using logarithmic utility, the Lagrangian is

\[
\mathcal{L}
=
\alpha\ln x
+
(1-\alpha)\ln y
+
\lambda
\left(
m-p_xx-p_yy
\right).
\]

The first-order conditions are

\begin{align}
\frac{\partial\mathcal{L}}{\partial x}
    &=
    \frac{\alpha}{x}-\lambda p_x=0,\\
\frac{\partial\mathcal{L}}{\partial y}
    &=
    \frac{1-\alpha}{y}-\lambda p_y=0,\\
\frac{\partial\mathcal{L}}{\partial\lambda}
    &=
    m-p_xx-p_yy=0.
\end{align}

Dividing the first condition by the second and using the budget constraint
gives

\begin{align}
\frac{\alpha y}{(1-\alpha)x}
    &=
    \frac{p_x}{p_y},\\
y
    &=
    \frac{(1-\alpha)p_xx}{\alpha p_y},\\
p_xx
+
p_y
\left[
\frac{(1-\alpha)p_xx}{\alpha p_y}
\right]
    &=
    m,\\
\frac{p_xx}{\alpha}
    &=
    m,\\
x^{*}
    &=
    \frac{\alpha m}{p_x},\\
y^{*}
    &=
    \frac{(1-\alpha)m}{p_y}.
\end{align}

For \(\alpha=0.5\), \(m=100\), \(p_x=10\), and \(p_y=5\), the optimal bundle
is \((x^{*},y^{*})=(5,10)\).

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.75\columnwidth,
    xlabel={Quantity of good \(x\)},
    ylabel={Quantity of good \(y\)},
    xmin=0,
    xmax=11,
    ymin=0,
    ymax=22,
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\scriptsize},
    clip=false
]
\addplot[
    black,
    very thick,
    domain=0:10,
    samples=2
]
{20-2*x};

\addplot[
    black,
    thick,
    dashed,
    domain=2.5:10,
    samples=80
]
{50/x};

\addplot[
    only marks,
    mark=*,
    mark size=2.3pt,
    black
]
coordinates {(5,10)};

\node[font=\scriptsize,anchor=south west]
    at (axis cs:6.8,6.4) {budget line};
\node[font=\scriptsize,anchor=south west]
    at (axis cs:7.2,7.2) {indifference curve};
\node[font=\scriptsize,anchor=south west]
    at (axis cs:5,10) {\((5,10)\)};
\end{axis}
\end{tikzpicture}

\caption{Consumer optimum for income \(100\), prices \(p_x=10\) and \(p_y=5\),
and equal utility weights. The budget line is tangent to the dashed
indifference curve at \((5,10)\).}
\label{fig:consumer-optimum}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
The consumer's highest attainable indifference curve touches the budget line
at five units of \(x\) and ten units of \(y\).

\textbf{Long description.}
Good \(x\) is on the horizontal axis and good \(y\) is on the vertical axis.
The straight budget line runs from \(y=20\) when \(x=0\) to \(x=10\) when
\(y=0\). A dashed, downward-curving indifference curve is tangent to the budget
line at \(x=5\), \(y=10\). The text identifies the curve types, so line shape
and location are not the only means of identification.
\end{minipage}
\end{figure}

The point price elasticity of demand is

\[
\varepsilon_{Q,P}
=
\frac{\partial Q_d}{\partial P}
\frac{P}{Q_d}.
\]

Demand is elastic when \(\lvert\varepsilon_{Q,P}\rvert>1\), unit elastic when
\(\lvert\varepsilon_{Q,P}\rvert=1\), and inelastic when
\(\lvert\varepsilon_{Q,P}\rvert<1\).


% =================================================
\subsection{Macroeconomic Identities, Indexes, and Growth Rates}

Gross domestic product in expenditure form is

\[
Y=C+I+G+(X-M),
\]

where \(C\) is consumption, \(I\) investment, \(G\) government purchases,
\(X\) exports, and \(M\) imports.

If nominal gross domestic product and the price deflator use the same base
year, real gross domestic product is

\[
\text{Real GDP}_{t}
=
\frac{\text{Nominal GDP}_{t}}
{\text{GDP deflator}_{t}/100}.
\]

Inflation and continuously compounded output growth may be written as

\begin{align}
\pi_t
    &=
    100
    \left(
    \frac{\operatorname{CPI}_t-\operatorname{CPI}_{t-1}}
    {\operatorname{CPI}_{t-1}}
    \right),\\
g_t
    &=
    100
    \left[
    \ln(Y_t)-\ln(Y_{t-1})
    \right].
\end{align}

A change from \(4.25\%\) to \(4.75\%\) is an increase of
\(0.50\) percentage point, which is also \(50\) basis points:

\[
4.75\%-4.25\%
=
0.50\text{ percentage point}
=
50\text{ basis points}.
\]

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.68\columnwidth,
    xlabel={Year},
    ylabel={Real GDP index, base year \(=100\)},
    xmin=2020.7,
    xmax=2025.3,
    ymin=98,
    ymax=113,
    xtick={2021,2022,2023,2024,2025},
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\scriptsize}
]
\addplot[
    black,
    very thick,
    mark=*,
    mark size=2pt
]
coordinates {
    (2021,100)
    (2022,103)
    (2023,106)
    (2024,108)
    (2025,111)
};
\end{axis}
\end{tikzpicture}

\caption{Illustrative real GDP index from 2021 through 2025. The index rises
from \(100\) to \(111\); these controlled values are examples, not reported
statistics for a particular country.}
\label{fig:real-gdp-index}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
The illustrative real GDP index increases in every year from 2021 to 2025.

\textbf{Long description.}
Year is on the horizontal axis and a real GDP index with base year equal to
\(100\) is on the vertical axis. The plotted values are \(100\), \(103\),
\(106\), \(108\), and \(111\) for 2021 through 2025, respectively. The
increase is three index points in each of the first two intervals, two points
in the next interval, and three points in the final interval.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Numerical values represented in the real GDP example.}
\label{tab:real-gdp-index}
\small
\begin{tabular}{@{}rrrr@{}}
\toprule
Year
& Nominal GDP
& GDP deflator
& Real GDP index\\
\midrule
2021 & \(100.0\) & \(100.0\) & \(100.0\)\\
2022 & \(108.2\) & \(105.0\) & \(103.0\)\\
2023 & \(116.6\) & \(110.0\) & \(106.0\)\\
2024 & \(123.1\) & \(114.0\) & \(108.0\)\\
2025 & \(130.0\) & \(117.1\) & \(111.0\)\\
\bottomrule
\end{tabular}

\vspace{1mm}
\begin{minipage}{0.96\columnwidth}
\footnotesize
\textit{Note.} Values are controlled examples. Nominal GDP and the GDP
deflator are scaled so the real GDP series is an index with 2021 equal to
\(100\).
\end{minipage}
\end{table}


% =================================================
\subsection{Econometric Model and Regression Results}

For individual \(i\) in period \(t\), a two-way fixed-effects model is

\[
y_{it}
=
\beta_0
+
\beta_1x_{it}
+
\boldsymbol{\gamma}^{T}\mathbf{z}_{it}
+
\alpha_i
+
\delta_t
+
\varepsilon_{it},
\]

where \(y_{it}\) is the outcome, \(x_{it}\) is the main explanatory variable,
\(\mathbf{z}_{it}\) is a vector of controls, \(\alpha_i\) is an individual
fixed effect, \(\delta_t\) is a time fixed effect, and \(\varepsilon_{it}\) is
the error term.

In matrix notation, the ordinary least-squares estimator is

\[
\widehat{\boldsymbol{\beta}}
=
\left(
\mathbf{X}^{T}\mathbf{X}
\right)^{-1}
\mathbf{X}^{T}\mathbf{y}.
\]

A \(95\%\) confidence interval for coefficient \(\beta_j\) is

\[
\widehat{\beta}_j
\mathbin{\pm}
1.96\,
\operatorname{SE}
\left(
\widehat{\beta}_j
\right).
\]

For a difference-in-differences design, let
\(\operatorname{Treat}_i=1\) identify the treatment group and
\(\operatorname{Post}_t=1\) identify the post-intervention period:

\[
Y_{it}
=
\alpha
+
\beta\operatorname{Treat}_i
+
\gamma\operatorname{Post}_t
+
\delta
\left(
\operatorname{Treat}_i
\times
\operatorname{Post}_t
\right)
+
\varepsilon_{it}.
\]

Using the controlled group means in
Table~\ref{tab:did-means}, the estimated treatment effect is

\begin{align}
\widehat{\delta}
    &=
    \left(
    \overline{Y}_{\mathrm{treat,post}}
    -
    \overline{Y}_{\mathrm{treat,pre}}
    \right)\\
    &\quad
    -
    \left(
    \overline{Y}_{\mathrm{control,post}}
    -
    \overline{Y}_{\mathrm{control,pre}}
    \right),\\
    &=
    (70-50)-(55-45),\\
    &=
    20-10,\\
    &=
    10.
\end{align}

\begin{table*}[tbp]
\centering
\caption{Controlled group means for a difference-in-differences example.}
\label{tab:did-means}
\small
\begin{tabular}{@{}lrrr@{}}
\toprule
Group
& Pre-intervention
& Post-intervention
& Change\\
\midrule
Control
& \(45\)
& \(55\)
& \(10\)\\
Treatment
& \(50\)
& \(70\)
& \(20\)\\
Treatment minus control
& \(5\)
& \(15\)
& \(10\)\\
\bottomrule
\end{tabular}
\end{table*}

\begin{table*}[tbp]
\centering
\caption{Illustrative regression results for the
difference-in-differences model.}
\label{tab:did-regression}
\small
\begin{tabular}{@{}lrrl@{}}
\toprule
Term
& Estimate
& Standard error
& \(95\%\) confidence interval\\
\midrule
Treatment group
& \(5.0\)
& \(2.5\)
& \([0.1,\ 9.9]\)\\
Post-intervention period
& \(10.0\)
& \(2.0\)
& \([6.1,\ 13.9]\)\\
Treatment group \(\times\) post-intervention period
& \(10.0\)
& \(3.0\)
& \([4.1,\ 15.9]\)\\
Constant
& \(45.0\)
& \(1.5\)
& \([42.1,\ 47.9]\)\\
\midrule
Observations
& \multicolumn{3}{l}{\(400\)}\\
Individual fixed effects
& \multicolumn{3}{l}{Included}\\
Time fixed effects
& \multicolumn{3}{l}{Included}\\
\bottomrule
\end{tabular}

\vspace{1mm}
\begin{minipage}{0.94\textwidth}
\footnotesize
\textit{Note.} Values are controlled examples. The treatment-by-post
coefficient is the difference-in-differences estimate. Standard errors and
confidence intervals are stated explicitly; statistical significance is not
encoded only with asterisks.
\end{minipage}
\end{table*}


% =================================================
\subsection{Compound Interest and Project Valuation}

If principal \(P\) earns an annual nominal rate \(r\), compounded \(n\) times
per year for \(t\) years, the accumulated amount is

\[
A
=
P
\left(
1+\frac{r}{n}
\right)^{nt}.
\]

For continuous compounding,

\[
A=Pe^{rt}.
\]

For an initial investment \(C_0\), cash flow \(C_t\) in period \(t\), discount
rate \(r\), and final period \(N\), net present value is

\[
\operatorname{NPV}(r)
=
-C_0
+
\sum_{t=1}^{N}
\frac{C_t}{(1+r)^t}.
\]

The internal rate of return is any rate \(r_{\mathrm{IRR}}\) satisfying

\[
0
=
-C_0
+
\sum_{t=1}^{N}
\frac{C_t}
{\left(1+r_{\mathrm{IRR}}\right)^t}.
\]

\begin{figure}[tbp]
\centering
\begin{tikzpicture}[
    cash/.style={
        -{Stealth[length=2.2mm]},
        very thick
    },
    font=\scriptsize
]
\draw[-{Stealth[length=2.2mm]},thick]
    (-0.35,0) -- (5.0,0)
    node[right] {time};

\foreach \x/\t in {0/0,1.15/1,2.30/2,3.45/3,4.60/4}{
    \draw[thick] (\x,-0.10) -- (\x,0.10);
    \node[below] at (\x,-0.10) {\(t=\t\)};
}

\draw[cash] (0,0) -- (0,-1.05);
\node[below] at (0,-1.05) {\(-\$100\)};

\draw[cash] (1.15,0) -- (1.15,0.75);
\node[above] at (1.15,0.75) {\(\$30\)};

\draw[cash] (2.30,0) -- (2.30,0.90);
\node[above] at (2.30,0.90) {\(\$35\)};

\draw[cash] (3.45,0) -- (3.45,1.05);
\node[above] at (3.45,1.05) {\(\$40\)};

\draw[cash] (4.60,0) -- (4.60,1.20);
\node[above] at (4.60,1.20) {\(\$45\)};
\end{tikzpicture}

\caption{Cash-flow timeline for an initial investment of \(100\) dollars and
four later inflows. The downward arrow is an outflow, and the upward arrows are
inflows.}
\label{fig:cash-flow-timeline}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
An initial outflow of \(100\) dollars is followed by inflows of \(30\), \(35\),
\(40\), and \(45\) dollars in periods one through four.

\textbf{Long description.}
Time moves from left to right from period zero through period four. At period
zero, a downward arrow represents a negative \(100\)-dollar investment.
Upward arrows represent positive cash flows of \(30\) dollars in period one,
\(35\) dollars in period two, \(40\) dollars in period three, and \(45\)
dollars in period four. Arrow direction is also stated in text.
\end{minipage}
\end{figure}

At an annual discount rate of \(8\%\),

\begin{align}
\operatorname{NPV}(0.08)
    &=
    -100
    +
    \frac{30}{1.08}
    +
    \frac{35}{1.08^2}
    +
    \frac{40}{1.08^3}
    +
    \frac{45}{1.08^4},\\
    &=
    \$22.61.
\end{align}

The decision rule is

\[
\text{Decision}
=
\begin{cases}
\text{accept the project},
    & \operatorname{NPV}>0,\\
\text{indifferent},
    & \operatorname{NPV}=0,\\
\text{reject the project},
    & \operatorname{NPV}<0.
\end{cases}
\]


% =================================================
\subsection{Bond Pricing, Yield, and Duration}

For a bond with coupon payment \(C\), face value \(F\), yield per period \(y\),
and \(N\) remaining periods, the price is

\[
B_0
=
\sum_{t=1}^{N}
\frac{C}{(1+y)^t}
+
\frac{F}{(1+y)^N}.
\]

For \(C=\$50\), \(F=\$1{,}000\), \(y=0.04\), and \(N=3\),

\begin{align}
B_0
    &=
    \frac{50}{1.04}
    +
    \frac{50}{1.04^2}
    +
    \frac{1{,}050}{1.04^3},\\
    &=
    \$1{,}027.75.
\end{align}

Macaulay duration and modified duration are

\begin{align}
D_{\mathrm{Mac}}
    &=
    \frac{
    \displaystyle
    \sum_{t=1}^{N}
    t\,
    \frac{\operatorname{CF}_t}{(1+y)^t}
    }{B_0},\\
D_{\mathrm{mod}}
    &=
    \frac{D_{\mathrm{Mac}}}{1+y}.
\end{align}

For a small yield change \(\Delta y\), the approximate percentage price change
is

\[
\frac{\Delta B}{B_0}
\approx
-D_{\mathrm{mod}}\Delta y.
\]

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.68\columnwidth,
    xlabel={Maturity in years},
    ylabel={Yield (\%)},
    xmin=0,
    xmax=31,
    ymin=3.5,
    ymax=4.9,
    xtick={0,1,2,5,10,20,30},
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\scriptsize}
]
\addplot[
    black,
    very thick,
    mark=square*,
    mark size=2pt
]
coordinates {
    (0.25,4.30)
    (0.50,4.20)
    (1,4.00)
    (2,3.80)
    (5,4.10)
    (10,4.40)
    (30,4.60)
};
\end{axis}
\end{tikzpicture}

\caption{Illustrative yield curve. Yields decline from three-month to two-year
maturities and then rise through the thirty-year maturity. Values are
controlled examples, not current market quotations.}
\label{fig:yield-curve}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
The illustrative yield curve falls to a minimum at two years and then rises.

\textbf{Long description.}
Maturity in years is on the horizontal axis and yield in percent is on the
vertical axis. The plotted maturity-yield pairs are \(0.25\) year and
\(4.30\%\), \(0.50\) year and \(4.20\%\), one year and \(4.00\%\), two years
and \(3.80\%\), five years and \(4.10\%\), ten years and \(4.40\%\), and
thirty years and \(4.60\%\). The minimum illustrated yield is \(3.80\%\) at
two years.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Numerical values represented in the illustrative yield curve.}
\label{tab:yield-curve}
\small
\begin{tabular}{@{}rr@{}}
\toprule
Maturity in years
& Yield (\%)\\
\midrule
\(0.25\) & \(4.30\)\\
\(0.50\) & \(4.20\)\\
\(1.00\) & \(4.00\)\\
\(2.00\) & \(3.80\)\\
\(5.00\) & \(4.10\)\\
\(10.00\) & \(4.40\)\\
\(30.00\) & \(4.60\)\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Returns, Portfolio Risk, and the Efficient Frontier}

For asset price \(P_t\), prior price \(P_{t-1}\), and distribution \(D_t\), the
simple holding-period return is

\[
R_t
=
\frac{P_t-P_{t-1}+D_t}{P_{t-1}}.
\]

For a portfolio with weight vector \(\mathbf{w}\), expected-return vector
\(\boldsymbol{\mu}\), and covariance matrix \(\boldsymbol{\Sigma}\),

\begin{align}
\operatorname{E}(R_p)
    &=
    \mathbf{w}^{T}\boldsymbol{\mu},\\
\operatorname{Var}(R_p)
    &=
    \mathbf{w}^{T}
    \boldsymbol{\Sigma}
    \mathbf{w},\\
\mathbf{1}^{T}\mathbf{w}
    &=
    1.
\end{align}

For two assets \(A\) and \(B\),

\[
\sigma_p^2
=
w_A^2\sigma_A^2
+
w_B^2\sigma_B^2
+
2w_Aw_B\rho_{AB}\sigma_A\sigma_B.
\]

An example covariance matrix is

\[
\boldsymbol{\Sigma}
=
\begin{bmatrix}
0.0400 & 0.0060\\
0.0060 & 0.0100
\end{bmatrix}.
\]

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.72\columnwidth,
    xlabel={Portfolio volatility \(\sigma_p\) (\%)},
    ylabel={Expected return \(\operatorname{E}(R_p)\) (\%)},
    xmin=3,
    xmax=21,
    ymin=2,
    ymax=11,
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\scriptsize},
    clip=false
]
\addplot[
    black,
    very thick,
    mark=*,
    mark size=2pt,
    smooth
]
coordinates {
    (5,3.0)
    (6,4.3)
    (8,5.8)
    (11,7.2)
    (15,8.5)
    (20,9.5)
};

\addplot[
    only marks,
    mark=square*,
    mark size=3pt,
    black
]
coordinates {(5,3.0)};

\node[font=\scriptsize,anchor=south west]
    at (axis cs:5,3.0) {minimum variance};
\node[font=\scriptsize,anchor=south east]
    at (axis cs:17,9.0) {efficient frontier};
\end{axis}
\end{tikzpicture}

\caption{Controlled risk-return combinations on an illustrative efficient
frontier. The square marker identifies the minimum-variance portfolio; circular
markers identify other portfolios.}
\label{fig:efficient-frontier}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Expected return increases as portfolio volatility increases along the
illustrative efficient frontier.

\textbf{Long description.}
Portfolio volatility in percent is on the horizontal axis and expected return
in percent is on the vertical axis. Six risk-return pairs are shown:
\((5,3.0)\), \((6,4.3)\), \((8,5.8)\), \((11,7.2)\), \((15,8.5)\), and
\((20,9.5)\). The minimum-variance portfolio is the first pair and uses a square
marker. The remaining pairs use circular markers. Marker shape and text, not
color alone, identify the special point.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Numerical values represented in the efficient-frontier example.}
\label{tab:efficient-frontier}
\small
\begin{tabular}{@{}lrr@{}}
\toprule
Portfolio
& Volatility (\%)
& Expected return (\%)\\
\midrule
Minimum variance & \(5.0\)  & \(3.0\)\\
Portfolio 2      & \(6.0\)  & \(4.3\)\\
Portfolio 3      & \(8.0\)  & \(5.8\)\\
Portfolio 4      & \(11.0\) & \(7.2\)\\
Portfolio 5      & \(15.0\) & \(8.5\)\\
Portfolio 6      & \(20.0\) & \(9.5\)\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Option Payoffs and Tail-Risk Measures}

For terminal underlying price \(S_T\) and strike price \(K\), the payoffs of a
European call and put are

\begin{align}
C_T
    &=
    \max(S_T-K,0)
    =
    \begin{cases}
    0,
        & S_T\leq K,\\
    S_T-K,
        & S_T>K,
    \end{cases}\\
P_T
    &=
    \max(K-S_T,0)
    =
    \begin{cases}
    K-S_T,
        & S_T<K,\\
    0,
        & S_T\geq K.
    \end{cases}
\end{align}

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.72\columnwidth,
    xlabel={Terminal underlying price \(S_T\)},
    ylabel={Option payoff},
    xmin=50,
    xmax=150,
    ymin=0,
    ymax=55,
    xtick={50,75,100,125,150},
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\scriptsize},
    clip=false
]
\addplot[
    black,
    very thick,
    domain=50:150,
    samples=101
]
{max(x-100,0)};

\addplot[
    black,
    very thick,
    dashed,
    domain=50:150,
    samples=101
]
{max(100-x,0)};

\draw[dotted,thick]
    (axis cs:100,0)
    --
    (axis cs:100,55);

\node[font=\scriptsize,anchor=south west]
    at (axis cs:125,25) {call payoff};
\node[font=\scriptsize,anchor=south east]
    at (axis cs:75,25) {put payoff};
\node[font=\scriptsize,anchor=south west]
    at (axis cs:100,45) {strike \(K=100\)};
\end{axis}
\end{tikzpicture}

\caption{European call and put payoffs at expiration for strike price
\(K=100\). The call is solid, the put is dashed, and the strike is dotted.}
\label{fig:option-payoffs}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Below the strike, the put has positive payoff and the call has zero payoff;
above the strike, the call has positive payoff and the put has zero payoff.

\textbf{Long description.}
Terminal underlying price ranges from \(50\) to \(150\) on the horizontal axis.
Option payoff is on the vertical axis. The strike is \(100\). The solid call
payoff is zero through \(100\) and then rises dollar for dollar. The dashed put
payoff falls from \(50\) at an underlying price of \(50\) to zero at \(100\),
then remains zero. A dotted vertical line marks the strike.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Selected call and put payoffs for strike \(K=100\).}
\label{tab:option-payoffs}
\small
\begin{tabular}{@{}rrr@{}}
\toprule
Terminal price \(S_T\)
& Call payoff \(C_T\)
& Put payoff \(P_T\)\\
\midrule
\(80\)  & \(0\)  & \(20\)\\
\(100\) & \(0\)  & \(0\)\\
\(120\) & \(20\) & \(0\)\\
\bottomrule
\end{tabular}
\end{table}

For loss random variable \(L\) and confidence level \(\alpha\),

\begin{align}
\operatorname{VaR}_{\alpha}(L)
    &=
    \inf
    \left\{
    \ell:
    \Pr(L\leq\ell)\geq\alpha
    \right\},\\
\operatorname{CVaR}_{\alpha}(L)
    &=
    \operatorname{E}
    \left[
    L
    \,\middle|\,
    L\geq\operatorname{VaR}_{\alpha}(L)
    \right].
\end{align}


% =================================================
\subsection{Financial Statements and Ratio Analysis}

The balance-sheet identity is

\[
\text{Assets}
=
\text{Liabilities}
+
\text{Shareholders' equity}.
\]

Common ratios include

\begin{align}
\text{Current ratio}
    &=
    \frac{\text{Current assets}}
    {\text{Current liabilities}},\\
\text{Debt-to-equity ratio}
    &=
    \frac{\text{Total debt}}
    {\text{Shareholders' equity}},\\
\text{Return on assets}
    &=
    \frac{\text{Net income}}
    {\text{Average total assets}},\\
\text{Free cash flow}
    &=
    \text{Cash flow from operations}\\
    &\quad
    -
    \text{Capital expenditures}.
\end{align}

\begin{table*}[tbp]
\centering
\caption{Illustrative comparative financial statement.}
\label{tab:financial-statement}
\small
\begin{tabular}{@{}lrrl@{}}
\toprule
Line item
& Fiscal year 2024
& Fiscal year 2025
& Unit\\
\midrule
Cash and cash equivalents
& \(\$30.0\)
& \(\$36.0\)
& Millions of US dollars\\
Accounts receivable
& \(\$20.0\)
& \(\$24.0\)
& Millions of US dollars\\
Property and equipment
& \(\$100.0\)
& \(\$110.0\)
& Millions of US dollars\\
\midrule
Total assets
& \(\$150.0\)
& \(\$170.0\)
& Millions of US dollars\\
Total liabilities
& \(\$90.0\)
& \(\$96.0\)
& Millions of US dollars\\
Shareholders' equity
& \(\$60.0\)
& \(\$74.0\)
& Millions of US dollars\\
\midrule
Net income
& \(\$15.0\)
& \(\$18.0\)
& Millions of US dollars\\
Capital expenditures
& \((\$10.0)\)
& \((\$12.0)\)
& Millions of US dollars; cash outflow\\
\bottomrule
\end{tabular}

\vspace{1mm}
\begin{minipage}{0.94\textwidth}
\footnotesize
\textit{Note.} Values are controlled examples. Parentheses around capital
expenditures indicate negative cash flows, not optional information.
\end{minipage}
\end{table*}

The 2025 balance sheet satisfies

\begin{align}
\text{Total assets}
    &=
    \text{Total liabilities}
    +
    \text{Shareholders' equity},\\
\$170.0\text{ million}
    &=
    \$96.0\text{ million}
    +
    \$74.0\text{ million}.
\end{align}


% =================================================
\section{Linguistics}

\subsection{International Phonetic Alphabet and Transcription}

Phonemic transcription uses slashes, while phonetic transcription uses square
brackets. For example,

\begin{description}
    \item[Phonemic form:] /pÉªn/
    \item[Phonetic form:] [pÊ°Éªn]
\end{description}

The superscript h in [pÊ°Éªn] marks aspiration. Common IPA symbols and
modifiers include:

\begin{table}[tbp]
\centering
\caption{Controlled IPA transcription examples.}
\label{tab:ling-ipa-examples}
\small
\begin{tabular}{@{}
>{\raggedright\arraybackslash}p{0.23\columnwidth}
>{\raggedright\arraybackslash}p{0.22\columnwidth}
>{\raggedright\arraybackslash}p{0.43\columnwidth}
@{}}
\toprule
Notation & Feature tested & Meaning\\
\midrule
\strut[ËˆfÉ”nÉ™tÉªks]
& Ëˆ, É™, Éª
& Primary stress and vowels\\
\strut[ÊƒiËp]
& Êƒ, Ë
& Postalveolar sound and length\\
\strut[sÃ£]
& Ã£
& Nasalized vowel\\
\strut[pÊ°]
& Superscript h
& Aspirated consonant\\
\strut[maâµâµ]
& âµâµ
& High level tone\\
\strut[maÂ¹âµ]
& Â¹âµ
& Rising tone\\
\strut[maâµÂ¹]
& âµÂ¹
& Falling tone\\
\bottomrule
\end{tabular}
\end{table}

A minimal-pair table must keep each word, transcription, and meaning in the
same row:

\begin{table}[tbp]
\centering
\caption{Minimal pair differing in one phoneme.}
\label{tab:ling-minimal-pair}
\small
\begin{tabular}{@{}lll@{}}
\toprule
Word & Transcription & Contrasting segment\\
\midrule
pin & /pÉªn/ & /p/\\
bin & /bÉªn/ & /b/\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Acoustic Phonetics and Vowel-Space Data}

The first two formant frequencies, \(F_1\) and \(F_2\), are often used to
describe vowel quality. A controlled vowel-space plot is shown in
Figure~\ref{fig:ling-vowel-space}. The horizontal axis is reversed so that high
\(F_2\) values appear on the left, and the vertical axis is reversed so that
low \(F_1\) values appear at the top.

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.78\columnwidth,
    xlabel={Second formant \(F_2\) (\(\mathrm{Hz}\))},
    ylabel={First formant \(F_1\) (\(\mathrm{Hz}\))},
    xmin=700,
    xmax=2500,
    ymin=250,
    ymax=800,
    x dir=reverse,
    y dir=reverse,
    grid=major,
    tick label style={font=\scriptsize},
    label style={font=\scriptsize},
    clip=false
]
\addplot[
    only marks,
    mark=*,
    mark size=2.2pt,
    black
]
coordinates {
    (2400,300)
    (2000,400)
    (1850,530)
    (1700,660)
    (1100,730)
    (850,570)
    (900,350)
};

\node[font=\scriptsize,anchor=south east]
    at (axis cs:2400,300) {heed};
\node[font=\scriptsize,anchor=south]
    at (axis cs:2000,400) {hid};
\node[font=\scriptsize,anchor=south]
    at (axis cs:1850,530) {head};
\node[font=\scriptsize,anchor=north]
    at (axis cs:1700,660) {had};
\node[font=\scriptsize,anchor=north]
    at (axis cs:1100,730) {hod};
\node[font=\scriptsize,anchor=south west]
    at (axis cs:850,570) {hawed};
\node[font=\scriptsize,anchor=south west]
    at (axis cs:900,350) {who'd};
\end{axis}
\end{tikzpicture}

\caption{Controlled vowel-space plot. Both frequency axes use hertz and are
reversed to approximate the orientation of the articulatory vowel space.}
\label{fig:ling-vowel-space}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Seven vowels are plotted by their first and second formant frequencies on two
reversed axes.

\textbf{Long description.}
The second-formant axis runs from \(2500\) hertz at the left to \(700\) hertz
at the right. The first-formant axis runs from \(250\) hertz at the top to
\(800\) hertz at the bottom. ``Heed'' is near the upper-left at
\(F_1=300\) and \(F_2=2400\). ``Who'd'' is near the upper-right at
\(F_1=350\) and \(F_2=900\). ``Hod'' is near the lower-right at
\(F_1=730\) and \(F_2=1100\). Exact values for every point appear in
Table~\ref{tab:ling-vowel-data}.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Numerical values represented in the vowel-space plot.}
\label{tab:ling-vowel-data}
\small
\begin{tabular}{@{}llrr@{}}
\toprule
Word & IPA & \(F_1\) (\(\mathrm{Hz}\)) & \(F_2\) (\(\mathrm{Hz}\))\\
\midrule
heed  & /hid/ & 300 & 2400\\
hid   & /hÉªd/ & 400 & 2000\\
head  & /hÉ›d/ & 530 & 1850\\
had   & /hÃ¦d/ & 660 & 1700\\
hod   & /hÉ‘d/ & 730 & 1100\\
hawed & /hÉ”d/ & 570 & 850\\
who'd & /hud/ & 350 & 900\\
\bottomrule
\end{tabular}
\end{table}

Voice-onset time can be defined by

\[
\operatorname{VOT}
=
t_{\mathrm{voicing\ onset}}
-
t_{\mathrm{release}}.
\]

For \(t_{\mathrm{release}}=0\,\mathrm{ms}\) and
\(t_{\mathrm{voicing\ onset}}=60\,\mathrm{ms}\),

\begin{align}
\operatorname{VOT}
    &=
    60\,\mathrm{ms}-0\,\mathrm{ms}\\
    &=
    60\,\mathrm{ms}.
\end{align}


% =================================================
\subsection{Phonological Rules, Syllables, and an Optimality Tableau}

A simplified syllable may be represented by the following rules:

\begin{align}
\sigma
    &\rightarrow
    \mathrm{Onset}\,\mathrm{Rhyme},\\
\mathrm{Rhyme}
    &\rightarrow
    \mathrm{Nucleus}\,(\mathrm{Coda}).
\end{align}

Parentheses indicate that the coda is optional. A word-final devoicing rule may
be written as

\[
\begin{bmatrix}
-\mathrm{sonorant}\\
+\mathrm{voice}
\end{bmatrix}
\rightarrow
\begin{bmatrix}
-\mathrm{voice}
\end{bmatrix}
\mathbin{/}
\underline{\hspace{1em}}
]_{\mathrm{word}}.
\]

This rule says that a voiced obstruent becomes voiceless at the end of a word.
The slash introduces the conditioning environment, the underline marks the
location of the changed segment, and the right bracket marks a word boundary.

The same pattern can be presented in a simplified Optimality Theory tableau:

\begin{table}[tbp]
\centering
\caption{Controlled Optimality Theory tableau for input /bad/.}
\label{tab:ling-ot-tableau}
\small
\begin{tabular}{@{}lccc@{}}
\toprule
Candidate
& \(\ast\)\textsc{Voice-Coda}
& \textsc{Max}
& \textsc{Ident-Voice}\\
\midrule
{[bad]}
& \(\ast!\) &  & \\
\(\rightarrow\)[bat]
&  &  & \(\ast\)\\
{[ba]}
&  & \(\ast!\) & \\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Morphology and Interlinear Glossed Text}

The word ``unhelpfulness'' may be segmented as

\[
\underbrace{\text{un}}_{\text{prefix}}
+
\underbrace{\text{help}}_{\text{root}}
+
\underbrace{\text{ful}}_{\text{derivational suffix}}
+
\underbrace{\text{ness}}_{\text{nominalizing suffix}}.
\]

A compact feature representation for a noun may be written as

\[
\begin{bmatrix}
+\text{common}\\
-\text{animate}\\
+\text{count}
\end{bmatrix}.
\]

Interlinear glossed text aligns a language example, a
morpheme-by-morpheme gloss, and a free translation. The following controlled
Turkish example illustrates plural, first-person singular possessive, and
locative morphology:

\begin{table}[tbp]
\centering
\caption{Interlinear glossed text with aligned morphemes.}
\label{tab:ling-interlinear-gloss}
\small
\begin{tabular}{@{}llll@{}}
\toprule
\multicolumn{4}{@{}l@{}}{\textbf{Turkish}}\\
\midrule
\textit{ev}
& \textit{-ler}
& \textit{-im}
& \textit{-de}\\
house
& \textsc{-pl}
& \textsc{-1sg.poss}
& \textsc{-loc}\\
\multicolumn{4}{@{}l@{}}{`in my houses'}\\
\bottomrule
\end{tabular}
\end{table}

The same example can be supplied in a linear fallback form:

\begin{quote}
\textit{ev-ler-im-de}\\
house-\textsc{pl}-\textsc{1sg.poss}-\textsc{loc}\\
`in my houses'
\end{quote}

\begin{table}[tbp]
\centering
\caption{Glossing abbreviations used in
Table~\ref{tab:ling-interlinear-gloss}.}
\label{tab:ling-gloss-abbreviations}
\small
\begin{tabular}{@{}ll@{}}
\toprule
Abbreviation & Meaning\\
\midrule
\textsc{pl} & plural\\
\textsc{1sg} & first person singular\\
\textsc{poss} & possessive\\
\textsc{loc} & locative\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Judgment Marks, Phrase Structure, and Constituency}

Linguistic examples may use symbols before a sentence to report different
types of judgments:

\begin{table}[tbp]
\centering
\caption{Common judgment marks in linguistic examples.}
\label{tab:ling-judgment-marks}
\small
\begin{tabular}{@{}
>{\raggedright\arraybackslash}p{0.10\columnwidth}
>{\raggedright\arraybackslash}p{0.36\columnwidth}
>{\raggedright\arraybackslash}p{0.43\columnwidth}
@{}}
\toprule
Mark & Example & Intended interpretation\\
\midrule
none
& The student read the article.
& Judged acceptable in the stated context\\
\(\ast\)
& \(\ast\)The student the article.
& Morphosyntactically unacceptable\\
\(?\)
& \(?\)The student may likely possibly leave.
& Marginal or uncertain judgment\\
\(\#\)
& \(\#\)The square circle slept.
& Unacceptable under the intended meaning or context\\
\bottomrule
\end{tabular}
\end{table}

A simplified grammar may use the following phrase-structure rules:

\begin{align}
\mathrm{S}
    &\rightarrow
    \mathrm{NP}\,\mathrm{VP},\\
\mathrm{NP}
    &\rightarrow
    \mathrm{Det}\,\mathrm{N},\\
\mathrm{VP}
    &\rightarrow
    \mathrm{V}\,\mathrm{NP}.
\end{align}

The constituent structure of ``The student reads the article'' is shown in
Figure~\ref{fig:ling-constituency-tree}.

\begin{figure}[tbp]
\centering
\begin{tikzpicture}[
    node/.style={
        draw,
        rounded corners,
        inner sep=1.5pt,
        font=\scriptsize
    },
    edge/.style={thick}
]
\node[node] (s) at (0,3.6) {S};
\node[node] (np1) at (-1.65,2.8) {NP};
\node[node] (vp) at (1.15,2.8) {VP};
\node[node] (det1) at (-2.15,2.0) {Det};
\node[node] (n1) at (-1.15,2.0) {N};
\node[node] (v) at (0.45,2.0) {V};
\node[node] (np2) at (1.85,2.0) {NP};
\node[node] (det2) at (1.35,1.2) {Det};
\node[node] (n2) at (2.35,1.2) {N};
\node[node] (the1) at (-2.15,1.2) {The};
\node[node] (student) at (-1.15,1.2) {student};
\node[node] (reads) at (0.45,1.2) {reads};
\node[node] (the2) at (1.35,0.4) {the};
\node[node] (article) at (2.35,0.4) {article};

\draw[edge] (s) -- (np1);
\draw[edge] (s) -- (vp);
\draw[edge] (np1) -- (det1);
\draw[edge] (np1) -- (n1);
\draw[edge] (det1) -- (the1);
\draw[edge] (n1) -- (student);
\draw[edge] (vp) -- (v);
\draw[edge] (vp) -- (np2);
\draw[edge] (v) -- (reads);
\draw[edge] (np2) -- (det2);
\draw[edge] (np2) -- (n2);
\draw[edge] (det2) -- (the2);
\draw[edge] (n2) -- (article);
\end{tikzpicture}

\caption{Constituency tree for ``The student reads the article.''}
\label{fig:ling-constituency-tree}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
The sentence consists of a subject noun phrase followed by a verb phrase.

\textbf{Long description.}
The root node is S. Its first child is a noun phrase containing determiner
``The'' and noun ``student.'' Its second child is a verb phrase containing
verb ``reads'' and an object noun phrase. The object noun phrase contains
determiner ``the'' and noun ``article.''
\end{minipage}
\end{figure}

The same hierarchy is available as bracketed text:

\[
\begin{aligned}
\mathrm{S}
\rightarrow
{}&
[\mathrm{NP}\,
    [\mathrm{Det}\ \text{The}]
    [\mathrm{N}\ \text{student}]]\\
&[\mathrm{VP}\,
    [\mathrm{V}\ \text{reads}]
    [\mathrm{NP}\,
        [\mathrm{Det}\ \text{the}]
        [\mathrm{N}\ \text{article}]]].
\end{aligned}
\]


% =================================================
\subsection{Dependency Syntax and Corpus Annotation}

A dependency analysis treats ``reads'' as the root. Arrows connect each head
to its dependent in Figure~\ref{fig:ling-dependency-tree}.

\begin{figure}[tbp]
\centering
\begin{tikzpicture}[
    x=0.72cm,
    token/.style={font=\small},
    dep/.style={-{Stealth[length=2mm]},thick},
    label/.style={font=\scriptsize,fill=white,inner sep=1pt}
]
\node[token] (w1) at (0,0) {The};
\node[token] (w2) at (2.0,0) {student};
\node[token] (w3) at (4.3,0) {reads};
\node[token] (w4) at (6.4,0) {the};
\node[token] (w5) at (8.4,0) {article};

\draw[dep] (w2.north) to[bend left=35]
    node[label,above] {\texttt{det}} (w1.north);
\draw[dep] (w3.north) to[bend left=30]
    node[label,above] {\texttt{nsubj}} (w2.north);
\draw[dep] (w3.north) to[bend left=30]
    node[label,above] {\texttt{obj}} (w5.north);
\draw[dep] (w5.north) to[bend left=35]
    node[label,above] {\texttt{det}} (w4.north);
\draw[dep] (4.3,1.8) -- node[label,right] {\texttt{root}} (w3.north);
\end{tikzpicture}

\caption{Dependency analysis with arrows from heads to dependents. ``Reads'' is
the root; ``student'' is its nominal subject, and ``article'' is its object.}
\label{fig:ling-dependency-tree}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
The root ``reads'' governs the subject ``student'' and object ``article'';
each noun governs its determiner.

\textbf{Long description.}
Tokens occur in the order The, student, reads, the, article. Token 3, reads,
has head 0 and relation root. Token 2, student, depends on reads with relation
nsubj. Token 1, The, depends on student with relation det. Token 5, article,
depends on reads with relation obj. Token 4, the, depends on article with
relation det. The same information appears in
Table~\ref{tab:ling-conllu}.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Structured dependency annotation in a simplified CoNLL-U form.}
\label{tab:ling-conllu}
\scriptsize
\setlength{\tabcolsep}{2.2pt}
\begin{tabular}{@{}rllllrl@{}}
\toprule
ID & Form & Lemma & POS & Features & Head & Relation\\
\midrule
1 & The     & the     & DET  & Definite=Def & 2 & det\\
2 & student & student & NOUN & Number=Sing  & 3 & nsubj\\
3 & reads   & read    & VERB & Tense=Pres   & 0 & root\\
4 & the     & the     & DET  & Definite=Def & 5 & det\\
5 & article & article & NOUN & Number=Sing  & 3 & obj\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Formal Semantics, Quantifiers, and Scope}

Double semantic brackets denote interpretation. A controlled lexical entry is

\[
\left[\left[
\text{reads}
\right]\right]
=
\lambda y.\lambda x.\,
\operatorname{Read}(x,y).
\]

Generalized quantifier meanings may be written as

\begin{align}
\left[\left[
\text{every}
\right]\right]
    &=
    \lambda P.\lambda Q.\,
    \forall x
    \left(
    P(x)\rightarrow Q(x)
    \right),\\
\left[\left[
\text{a}
\right]\right]
    &=
    \lambda P.\lambda Q.\,
    \exists x
    \left(
    P(x)\land Q(x)
    \right).
\end{align}

The sentence ``Every student read a book'' has at least two scope readings:

\begin{align}
&\text{every \(>\) a:}\nonumber\\[-2pt]
&\forall x
\left[
\operatorname{Student}(x)
\right.\nonumber\\[-2pt]
&\qquad\left.
\rightarrow
\exists y
\left(
\operatorname{Book}(y)
\land
\operatorname{Read}(x,y)
\right)
\right],\\[2pt]
&\text{a \(>\) every:}\nonumber\\[-2pt]
&\exists y
\left[
\operatorname{Book}(y)
\right.\nonumber\\[-2pt]
&\qquad\left.
\land
\forall x
\left(
\operatorname{Student}(x)
\rightarrow
\operatorname{Read}(x,y)
\right)
\right].
\end{align}

The first reading allows a potentially different book for each student. The
second reading requires one book that every student read.

\begin{table}[tbp]
\centering
\caption{Logical symbols in the semantic representations.}
\label{tab:ling-semantic-symbols}
\small
\begin{tabular}{@{}ll@{}}
\toprule
Symbol & Meaning\\
\midrule
\(\lambda x\) & function abstraction over \(x\)\\
\(\forall x\) & for every \(x\)\\
\(\exists x\) & there exists an \(x\)\\
\(\land\) & logical conjunction, ``and''\\
\(\rightarrow\) & material implication, ``if--then''\\
\(>\) & wider scope than\\
\(\left[\left[\,\cdot\,\right]\right]\)
& semantic interpretation\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Pragmatics, Coreference, and Spoken-Language Transcripts}

Referential indices can show possible coreference:

\[
\text{Maria}_{i}
\text{ told Lena}_{j}
\text{ that she}_{i/j}
\text{ had won.}
\]

The notation \(i/j\) states that ``she'' may refer to Maria or Lena. It does
not assert that both interpretations are equally likely in every context.

Spoken-language corpora may contain speaker labels, time codes, pauses,
overlap, uncertain words, and non-speech events:

\begin{table}[tbp]
\centering
\caption{Controlled spoken-language transcript.}
\label{tab:ling-spoken-transcript}
\scriptsize
\setlength{\tabcolsep}{2.2pt}
\begin{tabular}{@{}
r
>{\raggedright\arraybackslash}p{0.25\columnwidth}
l
>{\raggedright\arraybackslash}p{0.46\columnwidth}
@{}}
\toprule
Line & Time & Speaker & Transcription\\
\midrule
1 & \texttt{00:00.0--00:02.4} & A
& I sent the draft (0.8) yesterday.\\
2 & \texttt{00:02.1--00:03.5} & B
& \texttt{[}You sent the final one?\texttt{]}\\
3 & \texttt{00:02.1--00:03.7} & A
& \texttt{[}The revised one,\texttt{]} yes.\\
4 & \texttt{00:03.8--00:05.0} & B
& ((laughs)) I missed that.\\
5 & \texttt{00:05.1--00:06.2} & A
& It was in the (shared) folder.\\
\bottomrule
\end{tabular}
\end{table}

Lines 2 and 3 overlap from 00:02.1. The value \((0.8)\) is a pause measured in
seconds, double parentheses mark a non-speech event, and parentheses around
``shared'' mark uncertain transcription.


% =================================================
\subsection{Signed-Language and Multimodal Annotation}

Signed and multimodal data are often represented on synchronized tiers. The
following notation is schematic and is not intended as a grammatical claim
about a particular signed language:

\[
\overbrace{
\mathrm{YOU}\qquad
\mathrm{BUY}\qquad
\mathrm{WHAT}
}^{\text{raised brows across the full utterance}}.
\]

\begin{table}[tbp]
\centering
\caption{Time-aligned multimodal annotation tiers.}
\label{tab:ling-multimodal-tiers}
\scriptsize
\setlength{\tabcolsep}{2pt}
\begin{tabular}{@{}
>{\raggedright\arraybackslash}p{0.15\columnwidth}
>{\raggedright\arraybackslash}p{0.18\columnwidth}
>{\raggedright\arraybackslash}p{0.19\columnwidth}
>{\raggedright\arraybackslash}p{0.22\columnwidth}
>{\raggedright\arraybackslash}p{0.13\columnwidth}
@{}}
\toprule
Time interval
& Dominant hand
& Non-dominant hand
& Nonmanual behavior
& Free translation\\
\midrule
\texttt{0.0--0.8 s}
& \textsc{index-2}
& neutral
& brows raised
& `you'\\
\texttt{0.8--1.6 s}
& \textsc{buy}
& neutral
& brows raised
& `buy'\\
\texttt{1.6--2.4 s}
& \textsc{what}
& neutral
& brows raised
& `what'\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Historical Linguistics and Language-Family Relationships}

Historical notation uses several symbols whose meanings depend on context. In
the following constructed illustration,

\[
{}^{\ast}\mathrm{p}
\,>\,
\mathrm{f}
\mathbin{/}
\#\,
\underline{\hspace{1em}},
\]

the superscript asterisk marks a reconstructed form, \(>\) means ``changes
into,'' the slash introduces the environment, the number sign marks a word
boundary, and the underline marks the position of the changing sound.

\begin{table}[tbp]
\centering
\caption{Constructed sound correspondences for three daughter varieties.}
\label{tab:ling-sound-correspondence}
\small
\begin{tabular}{@{}llll@{}}
\toprule
Reconstruction & Variety A & Variety B & Variety C\\
\midrule
\({}^{\ast}\)pata & pata & fata & hata\\
\({}^{\ast}\)pilu & pilu & filu & hilu\\
\({}^{\ast}\)puna & puna & funa & huna\\
\bottomrule
\end{tabular}
\end{table}

\begin{figure}[tbp]
\centering
\begin{tikzpicture}[
    node/.style={
        draw,
        rounded corners,
        inner sep=2pt,
        font=\scriptsize
    },
    edge/.style={thick}
]
\node[node] (proto) at (0,2.4) {Proto-L};
\node[node] (branch) at (-1.2,1.4) {Branch 1};
\node[node] (c) at (1.3,1.4) {Variety C};
\node[node] (a) at (-2.0,0.4) {Variety A};
\node[node] (b) at (-0.4,0.4) {Variety B};

\draw[edge] (proto) -- (branch);
\draw[edge] (proto) -- (c);
\draw[edge] (branch) -- (a);
\draw[edge] (branch) -- (b);
\end{tikzpicture}

\caption{Constructed language-family tree. Proto-L divides into Branch 1 and
Variety C; Branch 1 later divides into Varieties A and B.}
\label{fig:ling-language-family}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Proto-L has two immediate descendants: Branch 1 and Variety C.

\textbf{Long description.}
The root is Proto-L. Its first child is Branch 1, whose children are Variety A
and Variety B. The root's second child is Variety C. The vertical arrangement
shows ancestry, not geographic position or chronological scale.
\end{minipage}
\end{figure}


% =================================================
\subsection{Geographic Variation and a Schematic Dialect Map}

Figure~\ref{fig:ling-dialect-map} is a schematic survey map rather than a real
geographic boundary map. Pattern and text labels identify four regions.

\begin{figure}[tbp]
\centering
\begin{tikzpicture}[font=\scriptsize]
\fill[black!12] (0,2) rectangle (2.4,4);
\fill[black!25] (2.4,2) rectangle (4.8,4);
\fill[black!38] (0,0) rectangle (2.4,2);
\fill[black!52] (2.4,0) rectangle (4.8,2);
\draw[very thick] (0,0) rectangle (4.8,4);
\draw[thick] (2.4,0) -- (2.4,4);
\draw[thick] (0,2) -- (4.8,2);

\node[align=center] at (1.2,3)
    {North\\variant A\\62\%};
\node[align=center] at (3.6,3)
    {Coast\\variant B\\71\%};
\node[align=center] at (1.2,1)
    {Central\\variant A\\55\%};
\node[align=center] at (3.6,1)
    {South\\variant C\\68\%};
\end{tikzpicture}

\caption{Schematic dialect survey with four labeled regions. Shading is
redundant because each region also contains its name, leading variant, and
percentage.}
\label{fig:ling-dialect-map}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Variant A leads in North and Central, variant B leads in Coast, and variant C
leads in South.

\textbf{Long description.}
The schematic has four rectangular regions. North is upper-left and reports
variant A at \(62\) percent. Coast is upper-right and reports variant B at
\(71\) percent. Central is lower-left and reports variant A at \(55\)
percent. South is lower-right and reports variant C at \(68\) percent. These
positions are only a controlled accessibility test and are not real
geographic boundaries.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Data represented in the schematic dialect map.}
\label{tab:ling-dialect-map-data}
\small
\begin{tabular}{@{}llr@{}}
\toprule
Region & Leading variant & Share (\%)\\
\midrule
North   & A & 62\\
Coast   & B & 71\\
Central & A & 55\\
South   & C & 68\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Corpus Frequencies and Sociolinguistic Models}

A normalized corpus frequency per million words is

\[
\operatorname{Frequency}_{\mathrm{pmw}}
=
\frac{\text{target-token count}}
{\text{total corpus tokens}}
\times
10^{6}.
\]

For \(420\) target tokens in a corpus of \(2{,}000{,}000\) tokens,

\begin{align}
\operatorname{Frequency}_{\mathrm{pmw}}
    &=
    \frac{420}{2{,}000{,}000}
    \times
    10^{6}\\
    &=
    210.
\end{align}

The normalized frequency is \(210\) occurrences per million words.

A mixed-effects logistic model for a binary linguistic outcome may be written
as

\[
\operatorname{logit}
\left[
\Pr(Y_{ij}=1)
\right]
=
\beta_{0}
+
\beta_{1}\operatorname{Group}_{i}
+
\beta_{2}\operatorname{Style}_{j}
+
u_{i}
+
v_{j},
\]

where \(i\) indexes speakers, \(j\) indexes lexical items,
\(\beta_{0}\) is the intercept, \(\beta_{1}\) and \(\beta_{2}\) are fixed
effects, \(u_i\) is a speaker-specific random intercept, and \(v_j\) is an
item-specific random intercept.

\begin{figure}[tbp]
\centering
\begin{tikzpicture}
\begin{axis}[
    width=0.98\columnwidth,
    height=0.72\columnwidth,
    xlabel={Speech style},
    ylabel={Probability of variant A},
    xmin=0.8,
    xmax=3.2,
    ymin=0,
    ymax=1,
    xtick={1,2,3},
    xticklabels={reading,interview,conversation},
    grid=major,
    legend style={
        font=\scriptsize,
        at={(0.5,-0.30)},
        anchor=north,
        legend columns=2
    },
    tick label style={font=\scriptsize},
    label style={font=\scriptsize}
]
\addplot[
    black,
    thick,
    mark=*,
    solid
]
coordinates {
    (1,0.28)
    (2,0.46)
    (3,0.67)
};
\addlegendentry{Group 1}

\addplot[
    black,
    thick,
    mark=square*,
    dashed
]
coordinates {
    (1,0.18)
    (2,0.31)
    (3,0.49)
};
\addlegendentry{Group 2}
\end{axis}
\end{tikzpicture}

\caption{Controlled sociolinguistic probabilities by group and speech style.
Group 1 is a solid line with circular markers; Group 2 is a dashed line with
square markers.}
\label{fig:ling-sociolinguistic-plot}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
The probability of variant A rises from reading to conversation in both
groups, and Group 1 is higher at every style.

\textbf{Long description.}
The horizontal axis lists reading, interview, and conversation in that order.
The vertical axis ranges from zero to one. Group 1 probabilities are
\(0.28\), \(0.46\), and \(0.67\). Group 2 probabilities are \(0.18\),
\(0.31\), and \(0.49\). Exact values appear in
Table~\ref{tab:ling-sociolinguistic-data}.
\end{minipage}
\end{figure}

\begin{table}[tbp]
\centering
\caption{Numerical values in the sociolinguistic plot.}
\label{tab:ling-sociolinguistic-data}
\small
\begin{tabular}{@{}lrr@{}}
\toprule
Style & Group 1 & Group 2\\
\midrule
Reading      & 0.28 & 0.18\\
Interview    & 0.46 & 0.31\\
Conversation & 0.67 & 0.49\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\section{Philosophy and Logic}

\subsection{Logical Symbols, Scope, and Use--Mention Distinctions}

Let \(P\), \(Q\), and \(R\) be propositions. Parentheses explicitly mark the
scope of each connective:

\[
\neg P\lor(Q\land R).
\]

This formula means that either \(P\) is false, or both \(Q\) and \(R\) are true.
It must not be read as

\[
(\neg P\lor Q)\land R,
\]

which has a different grouping and can have a different truth value.

\begin{table}[H]
\centering
\caption{Core logical symbols and their intended readings.}
\label{tab:phil-core-symbols}
\small
\begin{tabular}{@{}
>{\centering\arraybackslash}p{0.18\columnwidth}
>{\raggedright\arraybackslash}p{0.31\columnwidth}
>{\raggedright\arraybackslash}p{0.40\columnwidth}
@{}}
\toprule
Symbol & Typical reading & Structural point to preserve\\
\midrule
\(\neg P\)
& not \(P\)
& Negation applies to \(P\)\\
\(P\land Q\)
& \(P\) and \(Q\)
& Conjunction has two operands\\
\(P\lor Q\)
& \(P\) or \(Q\)
& Inclusive disjunction unless stated otherwise\\
\(P\rightarrow Q\)
& if \(P\), then \(Q\)
& Antecedent precedes consequent\\
\(P\leftrightarrow Q\)
& \(P\) if and only if \(Q\)
& Biconditional, not implication in one direction\\
\(\forall x\,F(x)\)
& every \(x\) is \(F\)
& Universal quantifier binds \(x\)\\
\(\exists x\,F(x)\)
& some \(x\) is \(F\)
& Existential quantifier binds \(x\)\\
\(\Gamma\vdash\varphi\)
& \(\varphi\) is derivable from \(\Gamma\)
& Syntactic consequence\\
\(\Gamma\models\varphi\)
& \(\varphi\) is true in every model of \(\Gamma\)
& Semantic consequence\\
\(\varphi\equiv\psi\)
& \(\varphi\) and \(\psi\) are equivalent
& Equivalence at the stated level\\
\bottomrule
\end{tabular}
\end{table}

Philosophical writing also distinguishes using an expression from mentioning
that expression:

\begin{align}
\text{Boston is a city}
&\quad\text{uses the name Boston},\\
\text{``Boston'' has six letters}
&\quad\text{mentions the name Boston}.
\end{align}

A T-schema instance makes the distinction explicit:

\[
\text{``Snow is white'' is true}
\quad\leftrightarrow\quad
\text{snow is white}.
\]


% =================================================
\subsection{Propositional Logic and Complete Truth Tables}

The following two tables test negation and all common binary truth-functional
connectives in a controlled example.

\begin{table}[H]
\centering
\caption{Negation, conjunction, and inclusive disjunction.}
\label{tab:phil-basic-truth-functions}
\scriptsize
\begin{tabular}{@{}ccccc@{}}
\toprule
\(P\)
& \(Q\)
& \(\neg P\)
& \(P\land Q\)
& \(P\lor Q\)\\
\midrule
True  & True  & False & True  & True\\
True  & False & False & False & True\\
False & True  & True  & False & True\\
False & False & True  & False & False\\
\bottomrule
\end{tabular}
\end{table}

\begin{table}[H]
\centering
\caption{Implication, biconditional, and exclusive disjunction. The symbol
\(\oplus\) denotes exclusive disjunction.}
\label{tab:phil-conditional-truth-functions}
\scriptsize
\begin{tabular}{@{}ccccc@{}}
\toprule
\(P\)
& \(Q\)
& \(P\rightarrow Q\)
& \(P\leftrightarrow Q\)
& \(P\oplus Q\)\\
\midrule
True  & True  & True  & True  & False\\
True  & False & False & False & True\\
False & True  & True  & False & True\\
False & False & True  & True  & False\\
\bottomrule
\end{tabular}
\end{table}

De Morgan's law states

\[
\neg(P\land Q)
\equiv
(\neg P\lor\neg Q).
\]

Modus ponens can be represented as an argument and as a single conditional:

\begin{align}
P\rightarrow Q,\quad P
&\therefore Q,\\
\bigl[(P\rightarrow Q)\land P\bigr]\rightarrow Q
&\quad\text{is a tautology}.
\end{align}

\begin{table}[H]
\centering
\caption{Classification of representative formulas.}
\label{tab:phil-formula-classification}
\small
\begin{tabular}{@{}
>{\raggedright\arraybackslash}p{0.48\columnwidth}
>{\raggedright\arraybackslash}p{0.39\columnwidth}
@{}}
\toprule
Formula & Classification\\
\midrule
\(P\lor\neg P\)
& Tautology: true on every valuation\\
\(P\land\neg P\)
& Contradiction: false on every valuation\\
\(P\rightarrow Q\)
& Contingency: true on some valuations and false on others\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Natural Deduction and the Scope of a Subproof}

The following derivation proves \(P\rightarrow R\) from
\(P\rightarrow Q\) and \(Q\rightarrow R\). Lines 3 through 5 form a subproof
whose temporary assumption is discharged on line 6.

\begin{table}[H]
\centering
\caption{Line-by-line natural-deduction proof.}
\label{tab:phil-natural-deduction}
\small
\begin{tabular}{@{}rlll@{}}
\toprule
Line & Scope & Formula & Justification\\
\midrule
1 & Main & \(P\rightarrow Q\) & Premise\\
2 & Main & \(Q\rightarrow R\) & Premise\\
3 & Subproof & \(P\) & Assumption\\
4 & Subproof & \(Q\) & \(\rightarrow\) elimination, 1 and 3\\
5 & Subproof & \(R\) & \(\rightarrow\) elimination, 2 and 4\\
6 & Main & \(P\rightarrow R\) & \(\rightarrow\) introduction, 3--5\\
\bottomrule
\end{tabular}
\end{table}

Common inference-rule layouts include

\begin{align}
\frac{P\qquad P\rightarrow Q}{Q}
&\quad(\rightarrow E),\\
\frac{P\qquad Q}{P\land Q}
&\quad(\land I),\\
\frac{\begin{array}{c}
[\neg P]\\[-1mm]
\vdots\\[-1mm]
\bot
\end{array}}{P}
&\quad(\mathrm{RAA}).
\end{align}

Here, \(\bot\) denotes contradiction, \(I\) denotes introduction, \(E\)
denotes elimination, and RAA denotes reductio ad absurdum.


% =================================================
\subsection{Predicate Logic, Quantifier Order, and Identity}

Consider the premises

\begin{align}
&\forall x\,
\bigl(
\operatorname{Human}(x)
\rightarrow
\operatorname{Mortal}(x)
\bigr),\\
&\operatorname{Human}(\mathrm{Socrates}).
\end{align}

The conclusion follows by universal instantiation and modus ponens:

\begin{align}
\forall x\,
\bigl(
\operatorname{Human}(x)
\rightarrow
\operatorname{Mortal}(x)
\bigr)
&\quad\text{Premise},\\
\operatorname{Human}(\mathrm{Socrates})
&\quad\text{Premise},\\
\operatorname{Human}(\mathrm{Socrates})
\rightarrow
\operatorname{Mortal}(\mathrm{Socrates})
&\quad\forall E,\\
\operatorname{Mortal}(\mathrm{Socrates})
&\quad\rightarrow E.
\end{align}

Quantifier order changes meaning:

\begin{align}
\forall x\,\exists y\,\operatorname{Admires}(x,y)
&\quad
\text{Everyone admires someone},\\
\exists y\,\forall x\,\operatorname{Admires}(x,y)
&\quad
\text{Someone is admired by everyone}.
\end{align}

The two quantifier-negation laws are

\begin{align}
\neg\forall x\,F(x)
&\equiv
\exists x\,\neg F(x),\\
\neg\exists x\,F(x)
&\equiv
\forall x\,\neg F(x).
\end{align}

Existence and uniqueness may be written without introducing a special
uniqueness quantifier:

\[
\exists x\,
\left[
F(x)
\land
\forall y\,
\bigl(
F(y)\rightarrow y=x
\bigr)
\right].
\]

This formula says that exactly one object is \(F\).

\begin{table}[H]
\centering
\caption{Quantifier-scope contrasts.}
\label{tab:phil-quantifier-scope}
\small
\begin{tabular}{@{}
>{\raggedright\arraybackslash}p{0.47\columnwidth}
>{\raggedright\arraybackslash}p{0.41\columnwidth}
@{}}
\toprule
Formula & Controlled reading\\
\midrule
\(\forall x\,(F(x)\rightarrow G(x))\)
& Every \(F\) is a \(G\)\\
\(\exists x\,(F(x)\land G(x))\)
& Some \(F\) is a \(G\)\\
\(\forall x\,\exists y\,R(x,y)\)
& Each object bears \(R\) to at least one object\\
\(\exists y\,\forall x\,R(x,y)\)
& One object is borne \(R\) by every object\\
\(\exists x\,[F(x)\land\forall y(F(y)\rightarrow y=x)]\)
& Exactly one object is \(F\)\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Categorical Logic and an Euler Diagram}

Consider the categorical argument:

\begin{enumerate}
\item All poets are writers.
\item No writers are machines.
\item Therefore, no poets are machines.
\end{enumerate}

Let \(P\), \(W\), and \(M\) denote the sets of poets, writers, and machines.
The premises and conclusion are

\[
P\subseteq W,
\qquad
W\cap M=\varnothing,
\qquad
\therefore P\cap M=\varnothing.
\]

\begin{figure}[H]
\centering
\begin{tikzpicture}[font=\small]
\draw[very thick] (0,0) ellipse (1.80cm and 1.25cm);
\draw[thick,dashed] (-0.35,0) ellipse (0.82cm and 0.58cm);
\draw[very thick] (3.55,0) ellipse (1.10cm and 0.85cm);

\node at (0,0.90) {writers \(W\)};
\node at (-0.35,0) {poets \(P\)};
\node at (3.55,0) {machines \(M\)};
\end{tikzpicture}

\caption{Euler diagram for the categorical argument. The dashed poets region
is entirely inside the writers region, and the machines region is disjoint
from both.}
\label{fig:phil-euler-categorical}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Poets are a subset of writers, and machines do not overlap writers.

\textbf{Long description.}
A large solid ellipse represents all writers. A smaller dashed ellipse
representing poets lies completely inside the writers ellipse. A separate
solid ellipse representing machines lies to the right and does not overlap
the writers or poets ellipses. Therefore, the poets and machines regions are
disjoint.
\end{minipage}
\end{figure}

\begin{table}[H]
\centering
\caption{Structured equivalent of the Euler diagram.}
\label{tab:phil-euler-structure}
\small
\begin{tabular}{@{}lll@{}}
\toprule
Region 1 & Relation & Region 2\\
\midrule
Poets \(P\) & is a subset of & Writers \(W\)\\
Writers \(W\) & is disjoint from & Machines \(M\)\\
Poets \(P\) & is disjoint from & Machines \(M\)\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Sets, Relations, Functions, and a Relation Matrix}

Let

\[
A=\{a,b,c\},
\qquad
\mathcal{R}
=
\{(a,b),(a,c),(b,c)\}.
\]

Using the order \(a,b,c\) for both rows and columns, the adjacency matrix of
\(\mathcal{R}\) is

\[
M_{\mathcal{R}}
=
\begin{bmatrix}
0 & 1 & 1\\
0 & 0 & 1\\
0 & 0 & 0
\end{bmatrix}.
\]

The relation is transitive because

\[
\forall x\,\forall y\,\forall z\,
\left[
\bigl(
x\mathcal{R}y
\land
y\mathcal{R}z
\bigr)
\rightarrow
x\mathcal{R}z
\right].
\]

A function and its composition may be written as

\begin{align}
f\colon A&\rightarrow B,\\
g\colon B&\rightarrow C,\\
(g\circ f)(a)&=g\bigl(f(a)\bigr).
\end{align}

\begin{table}[H]
\centering
\caption{Row-by-row equivalent of the relation matrix.}
\label{tab:phil-relation-matrix}
\small
\begin{tabular}{@{}cccc@{}}
\toprule
From\(\backslash\)to & \(a\) & \(b\) & \(c\)\\
\midrule
\(a\) & 0 & 1 & 1\\
\(b\) & 0 & 0 & 1\\
\(c\) & 0 & 0 & 0\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Formal Semantics, Models, and Metalogical Consequence}

A first-order model may be represented by

\[
\mathcal{M}
=
\langle D,I\rangle,
\]

where \(D\) is a nonempty domain and \(I\) is an interpretation function.
Truth relative to a model \(\mathcal{M}\), variable assignment \(s\), and
formula \(\varphi\) is written

\[
\mathcal{M},s\models\varphi.
\]

Semantic and syntactic consequence must remain distinct:

\begin{align}
\Gamma\models\varphi
&\quad
\text{every model of \(\Gamma\) satisfies \(\varphi\)},\\
\Gamma\vdash\varphi
&\quad
\text{there is a formal derivation of \(\varphi\) from \(\Gamma\)}.
\end{align}

For a sound and complete proof system,

\begin{align}
\Gamma\vdash\varphi
&\Longrightarrow
\Gamma\models\varphi
\quad\text{(soundness)},\\
\Gamma\models\varphi
&\Longrightarrow
\Gamma\vdash\varphi
\quad\text{(completeness)}.
\end{align}

The satisfaction clause for conjunction is

\[
\mathcal{M},s\models
(\varphi\land\psi)
\quad\text{if and only if}\quad
\mathcal{M},s\models\varphi
\ \text{and}\
\mathcal{M},s\models\psi.
\]

\begin{table}[H]
\centering
\caption{Levels of logical analysis.}
\label{tab:phil-levels-analysis}
\small
\begin{tabular}{@{}
>{\raggedright\arraybackslash}p{0.25\columnwidth}
>{\raggedright\arraybackslash}p{0.27\columnwidth}
>{\raggedright\arraybackslash}p{0.36\columnwidth}
@{}}
\toprule
Level & Example & Meaning\\
\midrule
Object language
& \(P\rightarrow Q\)
& Formula inside the formal system\\
Proof theory
& \(\Gamma\vdash\varphi\)
& Derivability by formal rules\\
Semantics
& \(\mathcal{M},s\models\varphi\)
& Truth in a model under an assignment\\
Metatheory
& Soundness and completeness
& Claims about relations between proof and semantics\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Sequents, Proof Trees, and a Semantic Tableau}

A sequent places assumptions to the left of the turnstile and conclusions to
the right:

\[
P,\ P\rightarrow Q
\vdash
Q.
\]

The same inference can be displayed as a proof tree:

\[
\frac{
P
\qquad
P\rightarrow Q
}{
Q
}
\;(\rightarrow E).
\]

To test whether

\[
P\lor Q,\quad \neg P,\quad \neg Q
\]

is satisfiable, a semantic tableau branches on \(P\lor Q\).

\begin{figure}[H]
\centering
\begin{tikzpicture}[
    formula/.style={
        draw,
        rounded corners,
        align=center,
        minimum width=2.55cm,
        minimum height=0.72cm,
        font=\small
    },
    branch/.style={
        -{Stealth[length=2mm]},
        thick
    }
]
\node[formula] (root) at (0,1.75)
{\(P\lor Q\)\\\(\neg P\)\\\(\neg Q\)};

\node[formula] (left) at (-1.45,0)
{\(P\)\\\(\neg P\)\\closed \(\times\)};

\node[formula] (right) at (1.45,0)
{\(Q\)\\\(\neg Q\)\\closed \(\times\)};

\draw[branch] (root) -- (left)
node[midway,left,font=\scriptsize] {left branch};
\draw[branch] (root) -- (right)
node[midway,right,font=\scriptsize] {right branch};
\end{tikzpicture}

\caption{Closed semantic tableau. The disjunction creates two branches; the
left contains \(P\) and \(\neg P\), and the right contains \(Q\) and
\(\neg Q\).}
\label{fig:phil-semantic-tableau}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Both branches close because each contains a proposition and its negation.

\textbf{Long description.}
The root lists \(P\lor Q\), not \(P\), and not \(Q\). Expanding the
disjunction creates a left branch containing \(P\) and a right branch
containing \(Q\). The left branch closes because it contains both \(P\) and
not \(P\). The right branch closes because it contains both \(Q\) and not
\(Q\). Since every branch closes, the original set is unsatisfiable.
\end{minipage}
\end{figure}

\begin{table}[H]
\centering
\caption{Structured description of the tableau branches.}
\label{tab:phil-tableau-branches}
\small
\begin{tabular}{@{}llll@{}}
\toprule
Branch & Added formula & Conflict & Status\\
\midrule
Left & \(P\) & \(P,\neg P\) & Closed\\
Right & \(Q\) & \(Q,\neg Q\) & Closed\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Modal Logic and a Possible-World Model}

A Kripke model is a triple

\[
\mathcal{K}
=
\langle W,\mathcal{R},V\rangle,
\]

where \(W\) is a nonempty set of worlds, \(\mathcal{R}\) is an accessibility
relation, and \(V\) is a valuation.

\begin{align}
\mathcal{K},w\models\Box\varphi
&\quad\text{if and only if}\quad
\forall v\,
\bigl(
w\mathcal{R}v
\rightarrow
\mathcal{K},v\models\varphi
\bigr),\\
\mathcal{K},w\models\Diamond\varphi
&\quad\text{if and only if}\quad
\exists v\,
\bigl(
w\mathcal{R}v
\land
\mathcal{K},v\models\varphi
\bigr).
\end{align}

\begin{figure}[H]
\centering
\begin{tikzpicture}[
    world/.style={
        circle,
        draw,
        very thick,
        minimum size=1.05cm,
        align=center,
        font=\small
    },
    access/.style={
        -{Stealth[length=2.2mm]},
        thick
    }
]
\node[world] (w0) at (0,0) {\(w_0\)};
\node[world] (w1) at (2.15,1.15) {\(w_1\)\\\(p\)};
\node[world] (w2) at (2.15,-1.15) {\(w_2\)\\\(p,q\)};

\draw[access] (w0) -- (w1);
\draw[access] (w0) -- (w2);
\draw[access] (w1) to[loop above] (w1);
\draw[access] (w2) -- (w1);

\node[font=\scriptsize,anchor=east] at (-0.58,0)
{actual world};
\end{tikzpicture}

\caption{Possible-world model with actual world \(w_0\). World \(w_0\) accesses
\(w_1\) and \(w_2\); \(w_1\) accesses itself; and \(w_2\) accesses \(w_1\).
Proposition \(p\) is true at \(w_1\) and \(w_2\), while \(q\) is true only at
\(w_2\).}
\label{fig:phil-kripke-model}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
The actual world accesses two worlds where \(p\) is true; \(q\) is true in only
one of them.

\textbf{Long description.}
There are three worlds. From \(w_0\), arrows lead to \(w_1\) and \(w_2\).
World \(w_1\) has a loop to itself. An arrow from \(w_2\) leads to \(w_1\).
The valuation at \(w_1\) contains \(p\). The valuation at \(w_2\) contains both
\(p\) and \(q\). No proposition is marked true at \(w_0\). Consequently,
\(\Box p\) and \(\Diamond q\) are true at \(w_0\), but \(\Box q\) is false
there.
\end{minipage}
\end{figure}

\begin{table}[H]
\centering
\caption{Structured equivalent of the possible-world diagram.}
\label{tab:phil-kripke-worlds}
\small
\begin{tabular}{@{}llll@{}}
\toprule
World & Accessible worlds & True atoms & Result at world\\
\midrule
\(w_0\) & \(w_1,w_2\) & none & \(\Box p,\Diamond q,\neg\Box q\)\\
\(w_1\) & \(w_1\) & \(p\) & \(\Box p,\neg q\)\\
\(w_2\) & \(w_1\) & \(p,q\) & \(q,\Box p\)\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Modalities Used in Philosophical Logic}

The same formal architecture is used for several philosophically important
kinds of modality.

\begin{table}[H]
\centering
\caption{Representative operators used in philosophical logic.}
\label{tab:phil-modal-operators}
\scriptsize
\begin{tabular}{@{}
>{\raggedright\arraybackslash}p{0.24\columnwidth}
>{\centering\arraybackslash}p{0.23\columnwidth}
>{\raggedright\arraybackslash}p{0.43\columnwidth}
@{}}
\toprule
System & Formula & Controlled reading\\
\midrule
Alethic
& \(\Box P,\ \Diamond P\)
& Necessarily \(P\); possibly \(P\)\\
Epistemic
& \(K_aP\)
& Agent \(a\) knows that \(P\)\\
Doxastic
& \(B_aP\)
& Agent \(a\) believes that \(P\)\\
Deontic
& \(\begin{gathered}
O(P),\ \operatorname{Perm}(P),\\
F(P)
\end{gathered}\)
& \(P\) is obligatory, permitted, or forbidden\\
Temporal
& \(\begin{gathered}
\mathrm{G}P,\ \mathrm{F}P,\\
\mathrm{H}P,\ \mathrm{P}P
\end{gathered}\)
& Always in the future, sometime in the future, always in the past,
or sometime in the past\\
Counterfactual
& \(P\mathbin{\Box\!\!\rightarrow}Q\)
& If \(P\) were the case, \(Q\) would be the case\\
Dynamic epistemic
& \([!P]K_aQ\)
& After the public announcement of \(P\), agent \(a\) knows \(Q\)\\
\bottomrule
\end{tabular}
\end{table}

Modal and quantifier scope can create a de re/de dicto contrast:

\begin{align}
\exists x\,\Box F(x)
&\quad
\text{Some particular object is necessarily \(F\)},\\
\Box\exists x\,F(x)
&\quad
\text{It is necessary that some object is \(F\)}.
\end{align}

One standard duality is

\[
\Diamond P
\equiv
\neg\Box\neg P.
\]


% =================================================
\subsection{Many-Valued, Fuzzy, and Paraconsistent Logic}

In a three-valued system, let truth degrees be

\[
\left\{
0,\frac{1}{2},1
\right\},
\]

where \(0\) is false, \(1/2\) is indeterminate, and \(1\) is true. One
controlled set of operations is

\begin{align}
v(\neg P)
&=
1-v(P),\\
v(P\land Q)
&=
\min\{v(P),v(Q)\},\\
v(P\lor Q)
&=
\max\{v(P),v(Q)\}.
\end{align}

\begin{table}[H]
\centering
\caption{Three-valued negation, conjunction, and disjunction.}
\label{tab:phil-three-valued}
\scriptsize
\begin{tabular}{@{}ccccc@{}}
\toprule
\(v(P)\)
& \(v(Q)\)
& \(v(\neg P)\)
& \(v(P\land Q)\)
& \(v(P\lor Q)\)\\
\midrule
\(0\)           & \(0\)           & \(1\)           & \(0\)           & \(0\)\\
\(0\)           & \(\tfrac12\)    & \(1\)           & \(0\)           & \(\tfrac12\)\\
\(0\)           & \(1\)           & \(1\)           & \(0\)           & \(1\)\\
\(\tfrac12\)    & \(0\)           & \(\tfrac12\)    & \(0\)           & \(\tfrac12\)\\
\(\tfrac12\)    & \(\tfrac12\)    & \(\tfrac12\)    & \(\tfrac12\)    & \(\tfrac12\)\\
\(\tfrac12\)    & \(1\)           & \(\tfrac12\)    & \(\tfrac12\)    & \(1\)\\
\(1\)           & \(0\)           & \(0\)           & \(0\)           & \(1\)\\
\(1\)           & \(\tfrac12\)    & \(0\)           & \(\tfrac12\)    & \(1\)\\
\(1\)           & \(1\)           & \(0\)           & \(1\)           & \(1\)\\
\bottomrule
\end{tabular}
\end{table}

A fuzzy-membership example is

\[
\mu_{\mathrm{Tall}}(\mathrm{Alex})=0.7.
\]

This assigns a degree of membership and does not mean that the proposition is
true with probability \(0.7\).

Some paraconsistent systems distinguish four informational states:

\begin{table}[H]
\centering
\caption{Four informational states used in a paraconsistent presentation.}
\label{tab:phil-paraconsistent-states}
\small
\begin{tabular}{@{}cll@{}}
\toprule
Code & Evidence for \(P\) & Evidence for \(\neg P\)\\
\midrule
\(\mathrm{T}\) & Present & Absent\\
\(\mathrm{F}\) & Absent & Present\\
\(\mathrm{B}\) & Present & Present\\
\(\mathrm{N}\) & Absent & Absent\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Bayesian Epistemology and Rational Choice}

Bayesian confirmation uses conditional probability:

\[
\Pr(H\mid E)
=
\frac{
\Pr(E\mid H)\Pr(H)
}{
\Pr(E)
}.
\]

If

\begin{align}
\Pr(H)
&=
0.20,\\
\Pr(E\mid H)
&=
0.80,\\
\Pr(E\mid\neg H)
&=
0.10,
\end{align}

then

\begin{align}
\Pr(E)
&=
\Pr(E\mid H)\Pr(H)
+
\Pr(E\mid\neg H)\Pr(\neg H),\\
&=
(0.80)(0.20)+(0.10)(0.80),\\
&=
0.24,\\
\Pr(H\mid E)
&=
\frac{(0.80)(0.20)}{0.24},\\
&=
\frac{2}{3}.
\end{align}

For actions \(a\), states \(s\), utility \(u(a,s)\), and evidence \(E\),
expected utility is

\[
\operatorname{EU}(a\mid E)
=
\sum_{s\in S}
\Pr(s\mid E)\,u(a,s).
\]

\begin{table}[H]
\centering
\caption{Controlled decision matrix with utilities.}
\label{tab:phil-decision-matrix}
\small
\begin{tabular}{@{}lrr@{}}
\toprule
Action & State \(s_1\) & State \(s_2\)\\
\midrule
\(a_1\) & \(10\) & \(-4\)\\
\(a_2\) & \(6\) & \(2\)\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Argument Maps, Objections, and Replies}

Philosophical arguments often contain supporting reasons, objections, and
replies rather than a single linear proof.

\begin{figure}[H]
\centering
\begin{tikzpicture}[
    claim/.style={
        draw,
        rounded corners,
        align=center,
        text width=2.35cm,
        minimum height=0.85cm,
        font=\scriptsize
    },
    support/.style={
        -{Stealth[length=2.2mm]},
        very thick
    },
    attack/.style={
        -{Stealth[length=2.2mm]},
        thick,
        dashed
    }
]
\node[claim] (p1) at (-1.45,3.45)
{\(P_1\): Causing unnecessary harm is wrong};

\node[claim] (p2) at (1.45,3.45)
{\(P_2\): Action \(A\) causes unnecessary harm};

\node[claim] (c) at (0,1.65)
{\(C\): Therefore, action \(A\) is wrong};

\node[claim] (o) at (0,-0.15)
{\(O_1\): Action \(A\) prevents a greater harm};

\node[claim] (r) at (0,-1.95)
{\(R_1\): A less harmful alternative prevents that harm};

\draw[support] (p1) -- (c)
node[midway,left,font=\scriptsize] {supports};
\draw[support] (p2) -- (c)
node[midway,right,font=\scriptsize] {supports};
\draw[attack] (o) -- (c)
node[midway,right,font=\scriptsize] {objects};
\draw[support] (r) -- (o)
node[midway,right,font=\scriptsize] {replies to};
\end{tikzpicture}

\caption{Argument map containing two supporting premises, a conclusion, an
objection, and a reply. Solid arrows indicate support or reply; the dashed
arrow indicates an objection.}
\label{fig:phil-argument-map}

\begin{minipage}{0.96\columnwidth}
\small
\textbf{Short text alternative.}
Two premises support the conclusion that action \(A\) is wrong; an objection
appeals to preventing greater harm, and a reply identifies a less harmful
alternative.

\textbf{Long description.}
Premise \(P_1\), ``Causing unnecessary harm is wrong,'' and premise \(P_2\),
``Action \(A\) causes unnecessary harm,'' each have a solid support arrow
pointing to conclusion \(C\), ``Action \(A\) is wrong.'' Objection \(O_1\),
``Action \(A\) prevents a greater harm,'' has a dashed attack arrow pointing
to conclusion \(C\). Reply \(R_1\), ``A less harmful alternative prevents that
harm,'' has a solid reply arrow pointing to objection \(O_1\).
\end{minipage}
\end{figure}

\begin{table}[H]
\centering
\caption{Structured equivalent of the argument map.}
\label{tab:phil-argument-map}
\scriptsize
\begin{tabular}{@{}
>{\raggedright\arraybackslash}p{0.18\columnwidth}
>{\raggedright\arraybackslash}p{0.52\columnwidth}
>{\raggedright\arraybackslash}p{0.20\columnwidth}
@{}}
\toprule
Identifier and role & Statement & Relation\\
\midrule
\(P_1\), premise & Causing unnecessary harm is wrong & Supports \(C\)\\
\(P_2\), premise & Action \(A\) causes unnecessary harm & Supports \(C\)\\
\(C\), conclusion & Action \(A\) is wrong & Supported by \(P_1,P_2\)\\
\(O_1\), objection & Action \(A\) prevents a greater harm & Attacks \(C\)\\
\(R_1\), reply & A less harmful alternative prevents that harm & Replies to \(O_1\)\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\subsection{Self-Reference, Quotation, and Defined Predicates}

Quotation devices are especially important in discussions of truth and
self-reference. Let \(L\) name the sentence that says of itself that it is not
true. A compact representation is

\[
L
\leftrightarrow
\neg\operatorname{True}
\bigl(
\ulcorner L\urcorner
\bigr).
\]

Here, \(\ulcorner L\urcorner\) denotes a name or quotation of the expression
\(L\); it is not another assertion of \(L\).

A proposed analysis of knowledge might be displayed as a definition:

\[
K_aP
\mathrel{\mathop:}= 
\bigl(
P\land B_aP\land J_aP
\bigr),
\]

where \(B_aP\) means that agent \(a\) believes \(P\), and \(J_aP\) means that
agent \(a\) is justified in believing \(P\). The displayed formula records a
proposed analysis; it does not establish that the analysis is correct.

\begin{table}[H]
\centering
\caption{Object-language and metalanguage distinctions.}
\label{tab:phil-object-meta}
\small
\begin{tabular}{@{}
>{\raggedright\arraybackslash}p{0.25\columnwidth}
>{\raggedright\arraybackslash}p{0.30\columnwidth}
>{\raggedright\arraybackslash}p{0.34\columnwidth}
@{}}
\toprule
Item & Level & Function\\
\midrule
\(L\)
& Object-language sentence
& Makes or represents an assertion\\
\(\ulcorner L\urcorner\)
& Metalanguage name
& Refers to the expression \(L\)\\
\(\operatorname{True}(\ulcorner L\urcorner)\)
& Semantic predication
& Attributes truth to the named sentence\\
\(\mathrel{\mathop:}=\)
& Definitional notation
& Introduces a proposed definition\\
\bottomrule
\end{tabular}
\end{table}


% =================================================
\end{document}