Skip to content

Commit

Permalink
feat(latex): add sample LaTeX documents for demo
Browse files Browse the repository at this point in the history
Add a sample `.tex` file with minimal examples such as equations,
hyperref, and bibliography with `biblatex`. This state of the repo will
serve as `v1` (with a tag) for release demonstration.
  • Loading branch information
tunakasif committed Jul 15, 2022
1 parent b71db46 commit 7b678da
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 0 deletions.
7 changes: 7 additions & 0 deletions bibliography.bib
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
@book{knuth1997art,
title = {The Art of Computer Programming},
author = {Donald E. Knuth},
publisher = {Addison Wesley},
year = {1997},
edition = {3.},
}
36 changes: 36 additions & 0 deletions main.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
\documentclass[a4paper,11pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[style=ieee]{biblatex}
\usepackage{amsmath, amssymb, amsthm}
\usepackage{hyperref}
\usepackage[capitalize]{cleveref}

\newcommand{\IM}{i} % change i with j for electrical engineering
\newcommand{\EXP}[1]{e^{#1}} % comment for \exp instead of e^{}
% \newcommand{\EXP}[1]{\exp\left(#1\right)} % and uncomment for \exp

\title{Title}
\author{Name Surname}
\date{\today}
\bibliography{bibliography}
\hypersetup{
colorlinks=true,
linkcolor=red,
urlcolor=blue,
citecolor=green,
}

\begin{document}
\maketitle

\section{Dummy Section}
This is a dummy section with an inline equation \(F = ma\), a set of
aligned mathematical identities in~\cref{eq:general,eq:special}, and
a book reference of~\autocite{knuth1997art}.
\begin{align}
\EXP{\IM\theta} & = \cos(\theta)+\IM\sin(\theta)~\label{eq:general} \\
1 + \EXP{\IM\pi} & = 0~\label{eq:special}
\end{align}

\printbibliography{}
\end{document}

0 comments on commit 7b678da

Please sign in to comment.