Initial commit

This commit is contained in:
Ian Jauslin 2018-05-18 22:53:34 +00:00
commit 06e19c0db2
24 changed files with 2850 additions and 0 deletions

File diff suppressed because it is too large Load Diff

55
Makefile Normal file
View File

@ -0,0 +1,55 @@
PROJECTNAME=$(basename $(wildcard *.tex))
LIBS=$(notdir $(wildcard libs/*))
FIGS=$(notdir $(wildcard figs/*.fig))
PDFS=$(addsuffix .pdf, $(PROJECTNAME))
SYNCTEXS=$(addsuffix .synctex.gz, $(PROJECTNAME))
all: $(PROJECTNAME)
$(PROJECTNAME): $(LIBS) $(FIGS)
pdflatex -file-line-error $@.tex
pdflatex -file-line-error $@.tex
pdflatex -synctex=1 $@.tex
$(PROJECTNAME).aux: $(LIBS) $(FIGS)
pdflatex -file-line-error -draftmode $(PROJECTNAME).tex
$(SYNCTEXS): $(LIBS) $(FIGS)
pdflatex -synctex=1 $(patsubst %.synctex.gz, %.tex, $@)
libs: $(LIBS)
$(LIBS):
ln -fs libs/$@ ./
figs: $(FIGS)
$(FIGS):
make -C figs/$@
ln -fs figs/$@/*.pdf ./
clean-aux: clean-figs-aux
rm -f $(addsuffix .aux, $(PROJECTNAME))
rm -f $(addsuffix .log, $(PROJECTNAME))
rm -f $(addsuffix .out, $(PROJECTNAME))
rm -f $(addsuffix .toc, $(PROJECTNAME))
clean-libs:
rm -f $(LIBS)
clean-figs:
$(foreach fig,$(addprefix figs/, $(FIGS)), make -C $(fig) clean; )
rm -f $(notdir $(wildcard figs/*.fig/*.pdf))
clean-figs-aux:
$(foreach fig,$(addprefix figs/, $(FIGS)), make -C $(fig) clean-aux; )
clean-tex:
rm -f $(PDFS) $(SYNCTEXS)
clean: clean-aux clean-tex clean-libs clean-figs

39
README Normal file
View File

@ -0,0 +1,39 @@
This directory contains the source files to typeset the article, and generate
the figures. This can be accomplished by running
make
This document uses a custom class file, located in the 'libs' directory, which
defines a number of commands. Most of these are drop-in replacements for those
defined in the 'article' class.
Some extra functionality is provided in custom style files, located in the
'libs' directory.
* Dependencies:
pdflatex
TeXlive packages:
amsfonts
color
dsfont
graphics
hyperref
latex
marginnote
pgf
standalone
GNU make
gnuplot
* Files:
Disertori_Giuliani_Jauslin.tex:
main LaTeX file
libs:
custom LaTeX class file
figs:
source code for the figures

View File

@ -0,0 +1,62 @@
\bibitem[APK04]{APK04}B.R. Acharya, A. Primak, S. Kumar - {\it Biaxial Nematic Phase in Bent-Core Thermotropic Mesogens}, Physical Review Letters, volume~\-92, number~\-14, page~\-145506, 2004,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1103/PhysRevLett.92.145506}{10.1103/PhysRevLett.92.145506}}.\par\medskip
\bibitem[AZ82]{AZ82}N. Angelescu, V.A. Zagrebnov - {\it A lattice model of liquid crystals with matrix order parameter}, Journal of Physics A: Mathematical and General, volume~\-15, issue~\-11, pages L639-L643, 1982,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1088/0305-4470/15/11/012}{10.1088/0305-4470/15/11/012}}.\par\medskip
\bibitem[BZ00]{BZ00}A. Bovier, M. Zahradn\'\i k - {\it A Simple Inductive Approach to the Problem of Convergence of Cluster Expansions of Polymer Models}, Journal of Statistical Physics, volume~\-100, issue~\-3-4, pages~\-765-778, 2000,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1023/A:1018631710626}{10.1023/A:1018631710626}}.\par\medskip
\bibitem[BKL84]{BKL84}J. Bricmont, K. Kuroda, J.L. Lebowitz - {\it The struture of Gibbs states and phase coexistence for non-symmetric continuum Widom-Rowlinson models}, Zeitschrift f\"ur Wahrscheinlichkeitstheorie und Verwandte Gebiete, volume~\-67, issue~\-2, pages~\-121-138, 1984,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1007/BF00535264}{10.1007/BF00535264}}.\par\medskip
\bibitem[Br86]{Br86}D.C. Brydges - {\it A short course on cluster expansions}, Les Houches, session XLIII, Elsevier, 1986.\par\medskip
\bibitem[DG13]{DG13}M. Disertori, A. Giuliani - {\it The nematic phase of a system of long hard rods}, Communications in Mathematical Physics, volume~\-323, pages~\-143-175, 2013,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1007/s00220-013-1767-1}{10.1007/s00220-013-1767-1}}, arxiv:{\tt\color{blue}\href{http://arxiv.org/abs/1112.5564}{1112.5564}}.\par\medskip
\bibitem[GBG04]{GBG04}G. Gallavotti, F. Bonetto, G. Gentile - {\it Aspects of Ergodic, Qualitative and Statistical Theory of Motion}, Springer, 2004.\par\medskip
\bibitem[GD07]{GD07}A. Ghosh, D. Dhar - {\it On the orientational ordering of long rods on a lattice}, Europhysics Letters, volume~\-78, page~\-20003, 2007,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1209/0295-5075/78/20003}{10.1209/0295-5075/78/20003}}, arxiv:{\tt\color{blue}\href{http://arxiv.org/abs/cond-mat/0611361}{cond-mat/0611361}}.\par\medskip
\bibitem[Gr62]{Gr62}J. Groeneveld - {\it Two theorems on classical many-particle systems}, Physics Letters, volume~\-3, issue~\-1, pages~\-50-51, 1962,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1016/0031-9163(62)90198-1}{10.1016/0031-9163(62)90198-1}}.\par\medskip
\bibitem[HL79]{HL79}O.J. Heilmann, E.H. Lieb - {\it Lattice models for liquid crystals}, Journal of Statistical Physics, volume~\-20, issue~\-6, pages~\-679-693, 1979,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1007/BF01009518}{10.1007/BF01009518}}.\par\medskip
\bibitem[IVZ06]{IVZ06}D. Ioffe, Y. Velenik, M. Zahradn\'\i k - {\it Entropy-Driven Phase Transition in a Polydisperse Hard-Rods Lattice System}, Journal of Statistical Physics, volume~\-122, issue~\-4, pages~\-761-786, 2006,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1007/s10955-005-8085-8}{10.1007/s10955-005-8085-8}}, arxiv:{\tt\color{blue}\href{http://arxiv.org/abs/math/0503222}{math/0503222}}.\par\medskip
\bibitem[JL17]{JL17c}I. Jauslin, E.H. Lieb - {\it Nematic liquid crystal phase Nematic liquid crystal phase}, 2017,\par\penalty10000
arxiv:{\tt\color{blue}\href{http://arxiv.org/abs/1709.05297}{1709.05297}}.\par\medskip
\bibitem[KP84]{KP84}R. Koteck\'y, D. Preiss - {\it An inductive approach to the Pirogov-Sinai theory}, Proceedings of the~\-11th Winter School on Abstract Analysis, Rendiconti del Circolo Matematico di Palermo, Serie II, supplemento~\-3, pages~\-161-164, 1984.\par\medskip
\bibitem[KP86]{KP86}R. Koteck\'y, D. Preiss - {\it Cluster expansion for abstract polymer models}, Communications in Mathematical Physics, volume~\-103, issue~\-3, pages~\-491-498, 1986,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1007/BF01211762}{10.1007/BF01211762}}.\par\medskip
\bibitem[MDe04]{MDe04}L.A. Madsen, T.J. Dingemans, M. Nakata, E.T. Samulski - {\it Thermotropic Biaxial Nematic Liquid Crystals}, Physical Review Letters, volume~\-92, issue~\-14, page~\-145505, 2004,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1103/PhysRevLett.92.145505}{10.1103/PhysRevLett.92.145505}}.\par\medskip
\bibitem[MKe04]{MKe04}K. Merkel, A. Kocot, J.K. Vij, R. Korlacki, G.H. Mehl, T. Meyer - {\it Thermotropic Biaxial Nematic Phase in Liquid Crystalline Organo-Siloxane Tetrapodes}, Physical Review Letters, volume~\-93, issue~\-23, page~\-237801, 2004,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1103/PhysRevLett.93.237801}{10.1103/PhysRevLett.93.237801}}.\par\medskip
\bibitem[Pe63]{Pe63}O. Penrose - {\it Convergence of Fugacity Expansions for Fluids and Lattice Gases}, Journal of Mathematical Physics, volume~\-4, issue~\-10, pages~\-1312-1320, 1963,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1063/1.1703906}{10.1063/1.1703906}}.\par\medskip
\bibitem[PS75]{PS75}S.A. Pirogov, Y.G. Sinai - {\it Phase diagrams of classical lattice systems}, Theoretical and Mathematical Physics, volume~\-25, pages~\-1185-1192, 1975,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1007/BF01040127}{10.1007/BF01040127}}.\par\medskip
\bibitem[Ru63]{Ru63}D. Ruelle - {\it Correlation functions of classical gases}, Annals of Physics, volume~\-25, issue~\-1, pages~\-109-120, 1963,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1016/0003-4916(63)90336-1}{10.1016/0003-4916(63)90336-1}}.\par\medskip
\bibitem[Ru71]{Ru71}D. Ruelle - {\it Existence of a phase transition in a continuous classical system}, Physical Review Letters, volume~\-27, issue~\-16, pages~\-1040-1041, 1971,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1103/PhysRevLett.27.1040}{10.1103/PhysRevLett.27.1040}}.\par\medskip
\bibitem[Ru99]{Ru99}D. Ruelle - {\it Statistical mechanics: rigorous results}, Imperial College Press, World Scientific, (first edition: Benjamin, 1969), 1999.\par\medskip
\bibitem[Za96]{Za96}V.A. Zagrebnov - {\it Long-range order in a lattice-gas model of nematic liquid crystals}, Physica A: Statistical Mechanics and its Applications, volume~\-232, issues~\-3-4, pages~\-737-746, 1996,\par\penalty10000
doi:{\tt\color{blue}\href{http://dx.doi.org/10.1016/0378-4371(96)00181-1}{10.1016/0378-4371(96)00181-1}}.\par\medskip

27
figs/libs/Makefile Normal file
View File

@ -0,0 +1,27 @@
PROJECTNAME=$(basename $(basename $(wildcard *.tikz.tex)))
LIBS=$(notdir $(wildcard libs/*))
PDFS=$(addsuffix .pdf, $(PROJECTNAME))
all: $(PDFS)
$(PDFS): $(LIBS)
pdflatex -jobname $(basename $@) -file-line-error $(patsubst %.pdf, %.tikz.tex, $@)
install: $(PDFS)
cp $^ $(INSTALLDIR)/
$(LIBS):
ln -fs libs/$@ ./
clean-libs:
rm -f $(LIBS)
clean-aux:
rm -f $(addsuffix .aux, $(PROJECTNAME))
rm -f $(addsuffix .log, $(PROJECTNAME))
clean-tex:
rm -f $(PDFS)
clean: clean-libs clean-aux clean-tex

24
figs/libs/grid.sty Normal file
View File

@ -0,0 +1,24 @@
% light gray color
\definecolor{lightgray}{gray}{0.7}
% a grid with starting from #1 mesh #2 of width #3*#2 and height #4*#2
\def\grid#1#2#3#4{
% vertical lines
\foreach\i in{0,...,#3}{
\draw[color=lightgray]#1++(\i*#2,0)--++(0,#4*#2);
}
% horizontal lines
\foreach\j in{0,...,#4}{
\draw[color=lightgray]#1++(0,\j*#2)--++(#3*#2,0);
}
}
% a square centered at #1 of side #2
\def\square#1#2{
\draw#1++(-0.5*#2,-0.5*#2)--++(#2,0)--++(0,#2)--++(-#2,0)--cycle;
}
% fill a square centered at #1 of side #2 and color #3
\def\fillsquare#1#2#3{
\fill[color=#3]#1++(-0.5*#2,-0.5*#2)--++(#2,0)--++(0,#2)--++(-#2,0)--cycle;
}

1
figs/peel.fig/Makefile Symbolic link
View File

@ -0,0 +1 @@
../libs/Makefile

1
figs/peel.fig/libs/grid.sty Symbolic link
View File

@ -0,0 +1 @@
../../libs/grid.sty

View File

@ -0,0 +1,21 @@
\documentclass{standalone}
\usepackage{tikz}
\usepackage{grid}
\begin{document}
\begin{tikzpicture}
\fillsquare{(0,0.5)}5{red}
\fillsquare{(0,-0.5)}5{red}
\fillsquare{(3,2.5)}5{red}
\fillsquare{(3,3.5)}5{red}
\fillsquare{(6,2.5)}5{red}
\fillsquare{(6,3.5)}5{red}
\fillsquare{(0,0)}4{cyan}
\fillsquare{(3,3)}4{cyan}
\fillsquare{(6,3)}4{cyan}
\grid{(-3,-3.5)}{0.5}{24}{20}
\end{tikzpicture}
\end{document}

View File

@ -0,0 +1,23 @@
PROJECTNAME=$(basename $(wildcard *.gnuplot))
PDFS=$(addsuffix .pdf, $(PROJECTNAME))
all: $(PDFS)
$(PDFS):
gnuplot $(patsubst %.pdf, %.gnuplot, $@) > $(patsubst %.pdf, %.tikz.tex, $@)
pdflatex -jobname $(basename $@) -file-line-error $(patsubst %.pdf, %.tikz.tex, $@)
install: $(PDFS)
cp $^ $(INSTALLDIR)/
clean-aux:
rm -f $(addsuffix .tikz.tex, $(PROJECTNAME))
rm -f $(addsuffix .aux, $(PROJECTNAME))
rm -f $(addsuffix .log, $(PROJECTNAME))
clean-pdf:
rm -f $(PDFS)
clean: clean-aux clean-pdf

View File

@ -0,0 +1,44 @@
# to output to tikz
# default output canvas size: 12.5cm x 8.75cm
set term lua tikz standalone
# parameter: k
k=2
# ranges
set xrange[0:1]
set yrange [:1./k]
# label x axis
set xlabel "$\\alpha$"
set xtics 0,0.25
set xtics nomirror
# no y axis
unset ytics
set ylabel "density"
# no keu
set key off
# label phases
set object 1 circle at 0.15,0.18 size 0.03
set label "$I$" at 0.15,0.18 center
set object 2 circle at 0.15,0.31 size 0.03
set label "$N_+$" at 0.15,0.31 center
set object 3 circle at 0.83,0.21 size 0.03
set label "$N_-$" at 0.83,0.21 center
set object 4 circle at 0.50,0.30 size 0.03
set label "$N_b$" at 0.50,0.30 center
set object 5 circle at 0.50,0.21 size 0.03
set label "?" at 0.50,0.21 center
# set linestyle 1
set style line 1 linetype rgbcolor "#000000" linewidth 2
plot \
k**(-1-x) with filledcurves above x2 fillcolor rgbcolor "#999999", \
k**(-1-x) with lines linestyle 1, \
k**(-2-x) with lines linestyle 1, \
k**(-2) with lines linestyle 1, \
k**(-1-2*x) with lines linestyle 1

1
figs/plates.fig/Makefile Symbolic link
View File

@ -0,0 +1 @@
../libs/Makefile

View File

@ -0,0 +1,87 @@
\documentclass{standalone}
\usepackage{tikz}
% a global rescaling factor
\def\rescale{0.6}
% length of the axes
\def\axeslength{\rescale*3}
% width, length and height of a plate
\def\w{\rescale*2.5}
\def\l{\rescale*4}
\def\h{\rescale*0.2}
% space between figures
\def\interlen{\rescale*8}
% offset of the label of each figure
\def\labeloffsetx{\rescale*2}
\def\labeloffsety{\rescale*3}
% factor by which to multiply lengths to get depths
\def\rotx{0.5*0.5}
\def\roty{0.5*0.866}
% draw a plate at #1 of width #2, length #3 and height #4
\def\plate#1#2#3#4{
\def\width{#2}
\def\length{#3}
\def\height{#4}
% the center
\path#1coordinate(O);
% draw first half of axes
\draw(O)++(-\axeslength,0)--(O);
\path(O)++(\rotx*\axeslength,\roty*\axeslength)coordinate(t);
\draw[->](O)++(\rotx*0.5*\width,\roty*0.5*\width)--(t);
\draw(O)++(0,-\axeslength)--(O);
% define points
\path(O)++(-0.5*\length,-0.5*\height)++(-0.5*\rotx*\width,-0.5*\roty*\width)coordinate(A);
\path(A)++(\length,0)coordinate(B);
\path(B)++(\rotx*\width,\roty*\width)coordinate(C);
\path(C)++(-\length,0)coordinate(D);
\path(D)++(0,\height)coordinate(E);
\path(E)++(-\rotx*\width,-\roty*\width)coordinate(F);
\path(F)++(\length,0)coordinate(G);
\path(G)++(\rotx*\width,\roty*\width)coordinate(H);
% fill and stroke the plate (covers part of the axes)
\fill[color=white](A)--(B)--(C)--(H)--(E)--(F)--(A);
\draw(A)--(B)--(C)--(H)--(E)--(F)--(G)--(H);
\draw(A)--(F);
\draw(B)--(G);
% draw the second half of the axes after having filled the plate
\path(O)++(\axeslength,0)coordinate(t);
\draw[->](O)++(0.5*\length,0)--(t);
\path(O)++(-\rotx*0.5*\width,-\roty*0.5*\width)coordinate(t);
\draw(O)++(-\rotx*\axeslength,-\roty*\axeslength)--(t);
\path(O)++(0,\axeslength)coordinate(t);
\draw[->](O)++(0,0.5*\height)--(t);
}
\begin{document}
\begin{tikzpicture}
% 3a
\plate{(0,0)}{\w}{\l}{\h}
\path(-\labeloffsetx,\labeloffsety)node{$3_a$};
% 3b
\plate{(\interlen,0)}{\l}{\w}{\h}
\path(\interlen,0)++(-\labeloffsetx,\labeloffsety)node{$3_b$};
% 1a
\plate{(2*\interlen,0)}{\l}{\h}{\w}
\path(2*\interlen,0)++(-\labeloffsetx,\labeloffsety)node{$1_a$};
% 1b
\plate{(0,-\interlen)}{\w}{\h}{\l}
\path(0,-\interlen)++(-\labeloffsetx,\labeloffsety)node{$1_b$};
% 2a
\plate{(\interlen,-\interlen)}{\h}{\w}{\l}
\path(\interlen,-\interlen)++(-\labeloffsetx,\labeloffsety)node{$2_a$};
% 2b
\plate{(2*\interlen,-\interlen)}{\h}{\l}{\w}
\path(2*\interlen,-\interlen)++(-\labeloffsetx,\labeloffsety)node{$2_b$};
\end{tikzpicture}
\end{document}

View File

@ -0,0 +1 @@
../libs/Makefile

View File

@ -0,0 +1,18 @@
\documentclass{standalone}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\fill[color=cyan](0,0)--++(2,0)--++(1,0.8)--++(0,2)--++(-2,0)--++(-1,-0.8);
\fill[color=red](0,0)--++(0,1)--++(1,0)--++(0,-1);
\draw(0,0)--++(2,0)--++(0,2)--++(-2,0)--cycle;
\draw(2,0)--++(1,0.8)--++(0,2)--++(-2,0)--++(-1,-0.8);
\draw(2,2)--++(1,0.8);
\draw(1,0)--++(0,2)--++(1,0.8);
\draw(0,1)--++(2,0)--++(1,0.8);
\draw(0,2)++(0.5,0.4)--++(2,0)--++(0,-2);
\end{tikzpicture}
\end{document}

View File

@ -0,0 +1 @@
../libs/Makefile

View File

@ -0,0 +1 @@
../../libs/grid.sty

View File

@ -0,0 +1,36 @@
\documentclass{standalone}
\usepackage{tikz}
\usepackage{grid}
\begin{document}
\begin{tikzpicture}
% the positions of the smoothing cubes
\def\smoothingsquares{(0,0),(4,4),(-4,0),(-4,4),(-8,4),(-4,8),(0,12),(4,8),(12,12),(12,8),(16,4)}
% the positions of the bad cubes
\def\badsquares{(-0.5,0),(-1.5,0),(-2,0),(-0.5,0.5),(-1.5,0.5),(-2,0.5),(-7,4.5),(-7,5.5),(-6,4.5),(-6,5.5),(-5.5,5.5),(-5.5,5),(-5,7.5),(-5.5,7.5),(-5.5,8),(-5,8),(0,10.5),(-0.5,10.5),(0,11),(-0.5,11),(3.5,5.5),(4,5.5),(4,6),(3.5,6),(10.5,8.5),(10.5,9.5),(10.5,10.5),(10.5,11.5),(10.5,12),(11.5,12),(12.5,12),(12.5,11),(12.5,10),(12,9),(11.5,8.5),(12,9.5),(15,4),(16,4),(16,3),(15,3)}
% first fill the smearings
\foreach\pos in\smoothingsquares{
\fillsquare{\pos}5{blue}
}
% fill the smoothing cubes
\foreach\pos in\smoothingsquares{
\fillsquare{\pos}4{gray}
}
% fill the bad cubes
\foreach\pos in\badsquares{
\fillsquare{\pos}{1}{green}
}
% draw grid
\grid{(-11,-3)}{0.5}{60}{36}
% stroke the smoothing squares
\foreach\pos in\smoothingsquares{
\square{\pos}4
}
\end{tikzpicture}
\end{document}

32
libs/constants.sty Normal file
View File

@ -0,0 +1,32 @@
%%
%% constants package:
%% automatically numbered constants
%%
%% TeX format
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
%% package name
\ProvidesPackage{constants}[2016/11/19]
%% declare new constant
\def\cst#1#2{%
% check whether the constant was defined
\ifcsname cst@#1@#2\endcsname%
#1_{\csname cst@#1@#2\endcsname}%
\else%
% check whether this character has a counter associated to it
\ifcsname thecst@#1@@count\endcsname%
\else%
\newcounter{cst@#1@@count}%
\fi%
% increment counter
\stepcounter{cst@#1@@count}%
\expandafter\xdef\csname cst@#1@#2\endcsname{\csname thecst@#1@@count\endcsname}#1_{\csname thecst@#1@@count\endcsname}%
\fi
}
%% end
\endinput

670
libs/ian.cls Normal file
View File

@ -0,0 +1,670 @@
%%
%% Ian's class file
%%
%% TeX format
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
%% class name
\ProvidesClass{ian}[2017/09/29]
%% boolean to signal that this class is being used
\newif\ifianclass
%% options
% no section numbering in equations
\DeclareOption{section_in_eq}{\sectionsineqtrue}
\DeclareOption{section_in_fig}{\sectionsinfigtrue}
\DeclareOption{section_in_theo}{\PassOptionsToPackage{\CurrentOption}{iantheo}}
\DeclareOption{section_in_all}{\sectionsineqtrue\sectionsinfigtrue\PassOptionsToPackage{section_in_theo}{iantheo}}
\DeclareOption{subsection_in_eq}{\subsectionsineqtrue}
\DeclareOption{subsection_in_fig}{\subsectionsinfigtrue}
\DeclareOption{subsection_in_theo}{\PassOptionsToPackage{\CurrentOption}{iantheo}}
\DeclareOption{subsection_in_all}{\subsectionsineqtrue\subsectionsinfigtrue\PassOptionsToPackage{subsection_in_theo}{iantheo}}
\DeclareOption{no_section_in_eq}{\sectionsineqfalse}
\DeclareOption{no_section_in_fig}{\sectionsinfigfalse}
\DeclareOption{no_section_in_theo}{\PassOptionsToPackage{\CurrentOption}{iantheo}}
\DeclareOption{no_section_in_all}{\sectionsineqfalse\sectionsinfigfalse\PassOptionsToPackage{no_section_in_theo}{iantheo}}
\DeclareOption{no_subsection_in_eq}{\subsectionsineqfalse}
\DeclareOption{no_subsection_in_fig}{\subsectionsinfigfalse}
\DeclareOption{no_subsection_in_theo}{\PassOptionsToPackage{\CurrentOption}{iantheo}}
\DeclareOption{no_subsection_in_all}{\subsectionsineqfalse\subsectionsinfigfalse\PassOptionsToPackage{no_subsection_in_theo}{iantheo}}
% reset point
\DeclareOption{point_reset_at_section}{\PassOptionsToPackage{reset_at_section}{point}}
\DeclareOption{point_no_reset_at_section}{\PassOptionsToPackage{no_reset_at_section}{point}}
\DeclareOption{point_reset_at_theo}{\PassOptionsToPackage{reset_at_theo}{point}}
\DeclareOption{point_no_reset_at_theo}{\PassOptionsToPackage{no_reset_at_theo}{point}}
\def\ian@defaultoptions{
\ExecuteOptions{section_in_all, no_subsection_in_all}
\ProcessOptions
%% required packages
\RequirePackage{iantheo}
\RequirePackage{point}
\RequirePackage{color}
\RequirePackage{marginnote}
\RequirePackage{amssymb}
\PassOptionsToPackage{hidelinks}{hyperref}
\RequirePackage{hyperref}
}
%% paper dimensions
\setlength\paperheight{297mm}
\setlength\paperwidth{210mm}
%% fonts
\input{size11.clo}
\DeclareOldFontCommand{\rm}{\normalfont\rmfamily}{\mathrm}
\DeclareOldFontCommand{\sf}{\normalfont\sffamily}{\mathsf}
\DeclareOldFontCommand{\tt}{\normalfont\ttfamily}{\mathtt}
\DeclareOldFontCommand{\bf}{\normalfont\bfseries}{\mathbf}
\DeclareOldFontCommand{\it}{\normalfont\itshape}{\mathit}
%% text dimensions
\hoffset=-50pt
\voffset=-72pt
\textwidth=460pt
\textheight=704pt
%% remove default indentation
\parindent=0pt
%% indent command
\def\indent{\hskip20pt}
%% something is wrong with \thepage, redefine it
\gdef\thepage{\the\c@page}
%% array lines (to use the array environment)
\setlength\arraycolsep{5\p@}
\setlength\arrayrulewidth{.4\p@}
%% correct vertical alignment at the end of a document
\AtEndDocument{
\vfill
\eject
}
%% hyperlinks
% hyperlinkcounter
\newcounter{lncount}
% hyperref anchor
\def\hrefanchor{%
\stepcounter{lncount}%
\hypertarget{ln.\thelncount}{}%
}
%% define a command and write it to aux file
\def\outdef#1#2{%
% define command%
\expandafter\xdef\csname #1\endcsname{#2}%
% hyperlink number%
\expandafter\xdef\csname #1@hl\endcsname{\thelncount}%
% write command to aux%
\immediate\write\@auxout{\noexpand\expandafter\noexpand\gdef\noexpand\csname #1\endcsname{\csname #1\endcsname}}%
\immediate\write\@auxout{\noexpand\expandafter\noexpand\gdef\noexpand\csname #1@hl\endcsname{\thelncount}}%
}
%% can call commands even when they are not defined
\def\safe#1{%
\ifdefined#1%
#1%
\else%
{\color{red}\bf?}%
\fi%
}
%% define a label for the latest tag
%% label defines a command containing the string stored in \tag
\def\deflabel{
\def\label##1{\expandafter\outdef{label@##1}{\safe\tag}}
\def\ref##1{%
% check whether the label is defined (hyperlink runs into errors if this check is omitted)
\ifcsname label@##1@hl\endcsname%
\hyperlink{ln.\csname label@##1@hl\endcsname}{{\color{blue}\safe\csname label@##1\endcsname}}%
\else%
\ifcsname label@##1\endcsname%
{\color{blue}\csname ##1\endcsname}%
\else%
{\bf ??}%
\fi%
\fi%
}
}
%% make a custom link at any given location in the document
\def\makelink#1#2{%
\hrefanchor%
\outdef{label@#1}{#2}%
}
%% section command
% counter
\newcounter{sectioncount}
% space before section
\newlength\secskip
\setlength\secskip{40pt}
% a prefix to put before the section number, e.g. A for appendices
\def\sectionprefix{}
% define some lengths
\newlength\secnumwidth
\newlength\sectitlewidth
\def\section#1{
% reset counters
\stepcounter{sectioncount}
\setcounter{subsectioncount}{0}
\ifsectionsineq
\setcounter{seqcount}0
\fi
\ifsectionsinfig
\setcounter{figcount}0
\fi
% space before section (if not first)
\ifnum\thesectioncount>1
\vskip\secskip
\penalty-1000
\fi
% hyperref anchor
\hrefanchor
% define tag (for \label)
\xdef\tag{\sectionprefix\thesectioncount}
% get widths
\def\@secnum{{\bf\Large\sectionprefix\thesectioncount.\hskip10pt}}
\settowidth\secnumwidth{\@secnum}
\setlength\sectitlewidth\textwidth
\addtolength\sectitlewidth{-\secnumwidth}
% print name
\parbox{\textwidth}{
\@secnum
\parbox[t]{\sectitlewidth}{\Large\bf #1}}
% write to table of contents
\iftoc
% save lncount in aux variable which is written to toc
\immediate\write\tocoutput{\noexpand\expandafter\noexpand\edef\noexpand\csname toc@sec.\thesectioncount\endcsname{\thelncount}}
\write\tocoutput{\noexpand\tocsection{#1}{\thepage}}
\fi
%space
\par\penalty10000
\bigskip\penalty10000
}
%% subsection
% counter
\newcounter{subsectioncount}
% space before subsection
\newlength\subsecskip
\setlength\subsecskip{30pt}
\def\subsection#1{
% counters
\stepcounter{subsectioncount}
\setcounter{subsubsectioncount}{0}
\ifsubsectionsineq
\setcounter{seqcount}0
\fi
\ifsubsectionsinfig
\setcounter{figcount}0
\fi
% space before subsection
\vskip\subsecskip
\penalty-500
% hyperref anchor
\hrefanchor
% define tag (for \label)
\xdef\tag{\sectionprefix\thesectioncount.\thesubsectioncount}
% get widths
\def\@secnum{{\bf\large\hskip.5cm\sectionprefix\thesectioncount.\thesubsectioncount.\hskip5pt}}
\settowidth\secnumwidth{\@secnum}
\setlength\sectitlewidth\textwidth
\addtolength\sectitlewidth{-\secnumwidth}
% print name
\parbox{\textwidth}{
\@secnum
\parbox[t]{\sectitlewidth}{\large\bf #1}}
% write to table of contents
\iftoc
% save lncount in aux variable which is written to toc
\immediate\write\tocoutput{\noexpand\expandafter\noexpand\edef\noexpand\csname toc@subsec.\thesectioncount.\thesubsectioncount\endcsname{\thelncount}}
\write\tocoutput{\noexpand\tocsubsection{#1}{\thepage}}
\fi
% space
\par\penalty10000
\medskip\penalty10000
}
%% subsubsection
% counter
\newcounter{subsubsectioncount}
% space before subsubsection
\newlength\subsubsecskip
\setlength\subsubsecskip{20pt}
\def\subsubsection#1{
% counters
\stepcounter{subsubsectioncount}
% space before subsubsection
\vskip\subsubsecskip
\penalty-500
% hyperref anchor
\hrefanchor
% define tag (for \label)
\xdef\tag{\sectionprefix\thesectioncount.\thesubsectioncount.\thesubsubsectioncount}
% get widths
\def\@secnum{{\bf\hskip1.cm\sectionprefix\thesectioncount.\thesubsectioncount.\thesubsubsectioncount.\hskip5pt}}
\settowidth\secnumwidth{\@secnum}
\setlength\sectitlewidth\textwidth
\addtolength\sectitlewidth{-\secnumwidth}
% print name
\parbox{\textwidth}{
\@secnum
\parbox[t]{\sectitlewidth}{\large\bf #1}}
% write to table of contents
\iftoc
% save lncount in aux variable which is written to toc
\immediate\write\tocoutput{\noexpand\expandafter\noexpand\edef\noexpand\csname toc@subsubsec.\thesectioncount.\thesubsectioncount.\thesubsubsectioncount\endcsname{\thelncount}}
\write\tocoutput{\noexpand\tocsubsubsection{#1}{\thepage}}
\fi
% space
\par\penalty10000
\medskip\penalty10000
}
%% itemize
\newlength\itemizeskip
% left margin for items
\setlength\itemizeskip{20pt}
\newlength\itemizeseparator
% space between the item symbol and the text
\setlength\itemizeseparator{5pt}
% penalty preceding an itemize
\newcount\itemizepenalty
\itemizepenalty=0
% counter counting the itemize level
\newcounter{itemizecount}
% item symbol
\def\itemizept#1{
\ifnum#1=1
\textbullet
\else
$\scriptstyle\blacktriangleright$
\fi
}
\newlength\current@itemizeskip
\setlength\current@itemizeskip{0pt}
\def\itemize{%
\par\expandafter\penalty\the\itemizepenalty\medskip\expandafter\penalty\the\itemizepenalty%
\addtocounter{itemizecount}{1}%
\addtolength\current@itemizeskip{\itemizeskip}%
\leftskip\current@itemizeskip%
}
\def\enditemize{%
\addtocounter{itemizecount}{-1}%
\addtolength\current@itemizeskip{-\itemizeskip}%
\par\expandafter\penalty\the\itemizepenalty\leftskip\current@itemizeskip%
\medskip\expandafter\penalty\the\itemizepenalty%
}
% item, with optional argument to specify the item point
% @itemarg is set to true when there is an optional argument
\newif\if@itemarg
\def\item{%
% check whether there is an optional argument (if there is none, add on empty '[]')
\@ifnextchar [{\@itemargtrue\@itemx}{\@itemargfalse\@itemx[]}%
}
\newlength\itempt@total
\def\@itemx[#1]{
\if@itemarg
\settowidth\itempt@total{#1}
\else
\settowidth\itempt@total{\itemizept\theitemizecount}
\fi
\addtolength\itempt@total{\itemizeseparator}
\par
\medskip
\if@itemarg
\hskip-\itempt@total#1\hskip\itemizeseparator
\else
\hskip-\itempt@total\itemizept\theitemizecount\hskip\itemizeseparator
\fi
}
%% prevent page breaks after itemize
\newcount\previtemizepenalty
\def\nopagebreakafteritemize{
\previtemizepenalty=\itemizepenalty
\itemizepenalty=10000
}
%% back to previous value
\def\restorepagebreakafteritemize{
\itemizepenalty=\previtemizepenalty
}
%% enumerate
\newcounter{enumerate@count}
\def\enumerate{
\setcounter{enumerate@count}0
\let\olditem\item
\let\olditemizept\itemizept
\def\item{
% counter
\stepcounter{enumerate@count}
% set header
\def\itemizept{\theenumerate@count.}
% hyperref anchor
\hrefanchor
% define tag (for \label)
\xdef\tag{\theenumerate@count}
\olditem
}
\itemize
}
\def\endenumerate{
\enditemize
\let\item\olditem
\let\itemizept\olditemizept
}
%% equation numbering
% counter
\newcounter{seqcount}
% booleans (write section or subsection in equation number)
\newif\ifsectionsineq
\newif\ifsubsectionsineq
\def\seqcount{
\stepcounter{seqcount}
% the output
\edef\seqformat{\theseqcount}
% add subsection number
\ifsubsectionsineq
\let\tmp\seqformat
\edef\seqformat{\thesubsectioncount.\tmp}
\fi
% add section number
\ifsectionsineq
\let\tmp\seqformat
\edef\seqformat{\sectionprefix\thesectioncount.\tmp}
\fi
% define tag (for \label)
\xdef\tag{\seqformat}
% write number
\marginnote{\hfill(\seqformat)}
}
%% equation environment compatibility
\def\equation{\hrefanchor$$\seqcount}
\def\endequation{$$\@ignoretrue}
%% figures
% counter
\newcounter{figcount}
% booleans (write section or subsection in equation number)
\newif\ifsectionsinfig
\newif\ifsubsectionsinfig
% width of figures
\newlength\figwidth
\setlength\figwidth\textwidth
\addtolength\figwidth{-2.5cm}
% caption
\def\defcaption{
\long\def\caption##1{
\stepcounter{figcount}
% hyperref anchor
\hrefanchor
% the number of the figure
\edef\figformat{\thefigcount}
% add subsection number
\ifsubsectionsinfig
\let\tmp\figformat
\edef\figformat{\thesubsectioncount.\tmp}
\fi
% add section number
\ifsectionsinfig
\let\tmp\figformat
\edef\figformat{\sectionprefix\thesectioncount.\tmp}
\fi
% define tag (for \label)
\xdef\tag{\figformat}
% write
\hfil fig \figformat: \parbox[t]{\figwidth}{\leavevmode\small##1}
% space
\par\bigskip
}
}
%% short caption: centered
\def\captionshort#1{
\stepcounter{figcount}
% hyperref anchor
\hrefanchor
% the number of the figure
\edef\figformat{\thefigcount}
% add section number
\ifsectionsinfig
\let\tmp\figformat
\edef\figformat{\sectionprefix\thesectioncount.\tmp}
\fi
% define tag (for \label)
\xdef\tag{\figformat}
% write
\hfil fig \figformat: {\small#1}
%space
\par\bigskip
}
%% environment
\def\figure{
\par
\vfil\penalty100\vfilneg
\bigskip
}
\def\endfigure{
\par
\bigskip
}
%% start appendices
\def\appendix{
\vfill
\pagebreak
% counter
\setcounter{sectioncount}0
% prefix
\def\sectionprefix{A}
% write
{\bf \LARGE Appendices}\par\penalty10000\bigskip\penalty10000
% add a mention in the table of contents
\iftoc
\immediate\write\tocoutput{\noexpand\tocappendices}\penalty10000
\fi
%% uncomment for new page for each appendix
%\def\seqskip{\vfill\pagebreak}
}
%% bibliography
% size of header
\newlength\bibheader
\def\thebibliography#1{
\hrefanchor
% add a mention in the table of contents
\iftoc
% save lncount in aux variable which is written to toc
\immediate\write\tocoutput{\noexpand\expandafter\noexpand\edef\noexpand\csname toc@references\endcsname{\thelncount}}
\write\tocoutput{\noexpand\tocreferences{\thepage}}\penalty10000
\fi
% write
{\bf \LARGE References}\par\penalty10000\bigskip\penalty10000
% width of header
\settowidth\bibheader{[#1]}
\leftskip\bibheader
}
% end environment
\def\endthebibliography{
\par\leftskip0pt
}
%% bibitem command
\def\bibitem[#1]#2{%
\hrefanchor%
\outdef{label@cite#2}{#1}%
\hskip-\bibheader%
\makebox[\bibheader]{\cite{#2}\hfill}%
}
%% cite command (adapted from latex.ltx)
% @tempswa is set to true when there is an optional argument
\newif\@tempswa
\def\cite{%
% check whether there is an optional argument (if there is none, add on empty '[]')
\@ifnextchar [{\@tempswatrue\@citex}{\@tempswafalse\@citex[]}%
}
% command with optional argument
\def\@citex[#1]#2{\leavevmode%
% initialize loop
\let\@citea\@empty%
% format
\@cite{%
% loop over ',' separated list
\@for\@citeb:=#2\do{%
% text to add at each iteration of the loop (separator between citations)
\@citea\def\@citea{,\ }%
% add entry to citelist
\@writecitation{\@citeb}%
\ref{cite\@citeb}%
}%
}%
% add optional argument text (as an argument to '\@cite')
{#1}%
}
\def\@cite#1#2{%
[#1\if@tempswa , #2\fi]%
}
%% add entry to citelist after checking it has not already been added
\def\@writecitation#1{%
\ifcsname if#1cited\endcsname%
\else%
\expandafter\newif\csname if#1cited\endcsname%
\immediate\write\@auxout{\string\citation{#1}}%
\fi%
}
%% table of contents
% boolean
\newif\iftoc
\def\tableofcontents{
{\bf \large Table of contents:}\par\penalty10000\bigskip\penalty10000
% copy content from file
\IfFileExists{\jobname.toc}{\input{\jobname.toc}}{{\tt error: table of contents missing}}
% open new toc
\newwrite\tocoutput
\immediate\openout\tocoutput=\jobname.toc
\toctrue
}
%% close file
\AtEndDocument{
% close toc
\iftoc
\immediate\closeout\tocoutput
\fi
}
%% fill line with dots
\def\leaderfill{\leaders\hbox to 1em {\hss. \hss}\hfill}
%% same as sectionprefix
\def\tocsectionprefix{}
%% toc formats
\newcounter{tocsectioncount}
\def\tocsection #1#2{
\stepcounter{tocsectioncount}
\setcounter{tocsubsectioncount}{0}
\setcounter{tocsubsubsectioncount}{0}
% write
\smallskip\hyperlink{ln.\csname toc@sec.\thetocsectioncount\endcsname}{{\bf \tocsectionprefix\thetocsectioncount}.\hskip5pt {\color{blue}#1}\leaderfill#2}\par
}
\newcounter{tocsubsectioncount}
\def\tocsubsection #1#2{
\stepcounter{tocsubsectioncount}
\setcounter{tocsubsubsectioncount}{0}
% write
{\hskip10pt\hyperlink{ln.\csname toc@subsec.\thetocsectioncount.\thetocsubsectioncount\endcsname}{{\bf \thetocsubsectioncount}.\hskip5pt {\color{blue}\small #1}\leaderfill#2}}\par
}
\newcounter{tocsubsubsectioncount}
\def\tocsubsubsection #1#2{
\stepcounter{tocsubsubsectioncount}
% write
{\hskip20pt\hyperlink{ln.\csname toc@subsubsec.\thetocsectioncount.\thetocsubsectioncount.\thetocsubsubsectioncount\endcsname}{{\bf \thetocsubsubsectioncount}.\hskip5pt {\color{blue}\small #1}\leaderfill#2}}\par
}
\def\tocappendices{
\medskip
\setcounter{tocsectioncount}0
{\bf Appendices}\par
\smallskip
\def\tocsectionprefix{A}
}
\def\tocreferences#1{
\medskip
{\hyperlink{ln.\csname toc@references\endcsname}{{\color{blue}\bf References}\leaderfill#1}}\par
\smallskip
}
%% definitions that must be loaded at begin document
\let\ian@olddocument\document
\def\document{
\ian@olddocument
\deflabel
\defcaption
}
%% end
\ian@defaultoptions
\endinput

162
libs/iantheo.sty Normal file
View File

@ -0,0 +1,162 @@
%%
%% iantheorem package:
%% Ian's customized theorem command
%%
%% boolean to signal that this package was loaded
\newif\ifiantheo
%% TeX format
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
%% package name
\ProvidesPackage{iantheo}[2016/11/10]
%% options
\newif\ifsectionintheo
\DeclareOption{section_in_theo}{\sectionintheotrue}
\DeclareOption{no_section_in_theo}{\sectionintheofalse}
\newif\ifsubsectionintheo
\DeclareOption{subsection_in_theo}{\subsectionintheotrue}
\DeclareOption{no_subsection_in_theo}{\subsectionintheofalse}
\def\iantheo@defaultoptions{
\ExecuteOptions{section_in_theo, no_subsection_in_theo}
\ProcessOptions
%%% reset at every new section
\ifsectionintheo
\let\iantheo@oldsection\section
\gdef\section{\setcounter{theocount}{0}\iantheo@oldsection}
\fi
%% reset at every new subsection
\ifsubsectionintheo
\let\iantheo@oldsubsection\subsection
\gdef\subsection{\setcounter{theocount}{0}\iantheo@oldsubsection}
\fi
}
%% delimiters
\def\delimtitle#1{
\par%
\leavevmode%
\raise.3em\hbox to\hsize{%
\lower0.3em\hbox{\vrule height0.3em}%
\hrulefill%
\ \lower.3em\hbox{#1}\ %
\hrulefill%
\lower0.3em\hbox{\vrule height0.3em}%
}%
\par\penalty10000%
}
%% callable by ref
\def\delimtitleref#1{
\par%
%
\ifdefined\ianclass%
% hyperref anchor%
\hrefanchor%
% define tag (for \label)%
\xdef\tag{#1}%
\fi%
%
\leavevmode%
\raise.3em\hbox to\hsize{%
\lower0.3em\hbox{\vrule height0.3em}%
\hrulefill%
\ \lower.3em\hbox{\bf #1}\ %
\hrulefill%
\lower0.3em\hbox{\vrule height0.3em}%
}%
\par\penalty10000%
}
%% no title
\def\delim{
\par%
\leavevmode\raise.3em\hbox to\hsize{%
\lower0.3em\hbox{\vrule height0.3em}%
\hrulefill%
\lower0.3em\hbox{\vrule height0.3em}%
}%
\par\penalty10000%
}
%% end delim
\def\enddelim{
\par\penalty10000%
\leavevmode%
\raise.3em\hbox to\hsize{%
\vrule height0.3em\hrulefill\vrule height0.3em%
}%
\par%
}
%% theorem
% counter
\newcounter{theocount}
% booleans (write section or subsection in equation number)
\def\theo#1{
\stepcounter{theocount}
\ifdefined\ianclass
% hyperref anchor
\hrefanchor
\fi
% the number
\def\formattheo{\thetheocount}
% add subsection number
\ifsubsectionintheo
\let\tmp\formattheo
\edef\formattheo{\thesubsectioncount.\tmp}
\fi
% add section number
\ifsectionintheo
\let\tmp\formattheo
\edef\formattheo{\sectionprefix\thesectioncount.\tmp}
\fi
% define tag (for \label)
\xdef\tag{\formattheo}
% write
\delimtitle{\bf #1 \formattheo}
}
\let\endtheo\enddelim
%% theorem headers with name
\def\theoname#1#2{
\theo{#1}\hfil({\it #2})\par\penalty10000\medskip%
}
%% qed symbol
\def\qedsymbol{$\square$}
\def\qed{\penalty10000\hfill\penalty10000\qedsymbol}
%% compatibility with article class
\ifdefined\ianclasstrue
\relax
\else
\def\thesectioncount{\thesection}
\def\thesubsectioncount{\thesubsection}
\def\sectionprefix{}
\fi
%% prevent page breaks after displayed equations
\newcount\prevpostdisplaypenalty
\def\nopagebreakaftereq{
\prevpostdisplaypenalty=\postdisplaypenalty
\postdisplaypenalty=10000
}
%% back to previous value
\def\restorepagebreakaftereq{
\postdisplaypenalty=\prevpostdisplaypenalty
}
%% end
\iantheo@defaultoptions
\endinput

19
libs/largearray.sty Normal file
View File

@ -0,0 +1,19 @@
%%
%% largearray package:
%% Array spanning the entire line
%%
%% TeX format
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
%% package name
\ProvidesPackage{largearray}[2016/11/10]
\RequirePackage{array}
%% array spanning the entire line
\newlength\largearray@width
\setlength\largearray@width\textwidth
\addtolength\largearray@width{-10pt}
\def\largearray{\begin{array}{@{}>{\displaystyle}l@{}}\hphantom{\hspace{\largearray@width}}\\[-.5cm]}
\def\endlargearray{\end{array}}

106
libs/point.sty Normal file
View File

@ -0,0 +1,106 @@
%%
%% Points package:
%% \point commands
%%
%% TeX format
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
%% package name
\ProvidesPackage{point}[2017/06/13]
%% options
\newif\ifresetatsection
\DeclareOption{reset_at_section}{\resetatsectiontrue}
\DeclareOption{no_reset_at_section}{\resetatsectionfalse}
\newif\ifresetatsubsection
\DeclareOption{reset_at_subsection}{\resetatsubsectiontrue}
\DeclareOption{no_reset_at_subsection}{\resetatsubsectionfalse}
\newif\ifresetattheo
\DeclareOption{reset_at_theo}{\resetattheotrue}
\DeclareOption{no_reset_at_theo}{\resetattheofalse}
\def\point@defaultoptions{
\ExecuteOptions{reset_at_section, reset_at_subsection, no_reset_at_theo}
\ProcessOptions
%% reset at every new section
\ifresetatsection
\let\point@oldsection\section
\gdef\section{\resetpointcounter\point@oldsection}
\fi
%% reset at every new subsection
\ifresetatsubsection
\let\point@oldsubsection\subsection
\gdef\subsection{\resetpointcounter\point@oldsubsection}
\fi
%% reset at every new theorem
\ifresetattheo
\ifdefined\iantheotrue
\let\point@oldtheo\theo
\gdef\theo{\resetpointcounter\point@oldtheo}
\fi
\fi
}
%% point
% counter
\newcounter{pointcount}
\def\point{
\stepcounter{pointcount}
\setcounter{subpointcount}{0}
% hyperref anchor (only if the class is 'ian')
\ifdefined\ifianclass
\hrefanchor
% define tag (for \label)
\xdef\tag{\thepointcount}
\fi
% header
\indent{\bf \thepointcount\ - }
}
%% subpoint
% counter
\newcounter{subpointcount}
\def\subpoint{
\stepcounter{subpointcount}
\setcounter{subsubpointcount}0
% hyperref anchor (only if the class is 'ian')
\ifdefined\ifianclass
\hrefanchor
% define tag (for \label)
\xdef\tag{\thepointcount-\thesubpointcount}
\fi
% header
\indent\hskip.5cm{\bf \thepointcount-\thesubpointcount\ - }
}
%% subsubpoint
% counter
\newcounter{subsubpointcount}
\def\subsubpoint{
\stepcounter{subsubpointcount}
% hyperref anchor (only if the class is 'ian')
\ifdefined\ifianclass
\hrefanchor
% define tag (for \label)
\xdef\tag{\thepointcount-\thesubpointcount-\thesubsubpointcount}
\fi
\indent\hskip1cm{\bf \thepointcount-\thesubpointcount-\thesubsubpointcount\ - }
}
%% reset point counters
\def\resetpointcounter{
\setcounter{pointcount}{0}
\setcounter{subpointcount}{0}
\setcounter{subsubpointcount}{0}
}
%% end
\point@defaultoptions
\endinput

120
libs/symbols.sty Normal file
View File

@ -0,0 +1,120 @@
\let\a=\alpha
\let\b=\beta
\let\g=\gamma
\let\d=\delta
\let\e=\varepsilon
\let\z=\zeta
\let\h=\eta
\let\th=\theta
\let\k=\kappa
\let\l=\lambda
\let\m=\mu
\let\n=\nu
\let\x=\xi
\let\p=\pi
\let\r=\rho
\let\s=\sigma
\let\t=\tau
\let\f=\varphi
\let\ph=\varphi
\let\c=\chi
\let\ps=\psi
\let\y=\upsilon
\let\o=\omega
\let\si=\varsigma
\let\G=\Gamma
\let\D=\Delta
\let\Th=\Theta
\let\L=\Lambda
\let\X=\Xi
\let\P=\Pi
\let\Si=\Sigma
\let\F=\Phi
\let\Ps=\Psi
\let\O=\Omega
\let\Y=\Upsilon
\def\AAA{\mathcal A}
\def\XXX{\mathcal X}
\def\PPP{\mathcal P}
\def\HHH{\mathcal H}
\def\BBB{\mathcal B}
\def\III{\mathcal I}
\def\EE{\mathcal E}
\def\MM{\mathcal M}
\def\VV{\mathcal V}
\def\CC{\mathcal C}
\def\FF{\mathcal F}
\def\WW{\mathcal W}
\def\TT{\mathcal T}
\def\NN{\mathcal N}
\def\RR{\mathcal R}
\def\LL{\mathcal L}
\def\JJ{\mathcal J}
\def\OO{\mathcal O}
\def\DD{\mathcal D}
\def\GG{\mathcal G}
\def\SS{\mathcal S}
\def\KK{\mathcal K}
\def\UU{\mathcal U}
\def\QQ{\mathcal Q}
\def\aaa{\mathbf a}
\def\bbb{\mathbf b}
\def\hhh{\mathbf h}
\def\hh{\mathbf h}
\def\HH{\mathbf H}
\def\AA{\mathbf A}
\def\qq{\mathbf q}
\def\BB{\mathbf B}
\def\YY{\mathbf Y}
\def\XX{\mathbf X}
\def\PP{\mathbf P}
\def\pp{\mathbf p}
\def\vv{\mathbf v}
\def\xx{\mathbf x}
\def\yy{\mathbf y}
\def\zz{\mathbf z}
\def\II{\mathbf I}
\def\ii{\mathbf i}
\def\jj{\mathbf j}
\def\kk{\mathbf k}
\def\bS{\mathbf S}
\def\mm{\mathbf m}
\def\Vn{\mathbf n}
\def\ch{\chi}
\def\Exp{\mathrm exp}
\def\Log{\mathrm log}
\def\Ft{\varphi}
\def\E{H}
\def\RRR{\mathbb R}
\def\ZZZ{\mathbb Z}
\def\ss{\underline{\sigma}}
\let\==\equiv
\let\io=\infty
\let\0=\noindent
\def\media#1{\left<#1\right>}
\let\dpr=\partial
\def\sign{\mathrm{sign}}
\def\const{\mathrm{const}}
\def\wt{\widetilde}
\def\wh{\widehat}
\def\Val{\mathrm{Val}}
\let\ul=\underline
\def\lis{\overline}
\let\V=\mathbf
\def\be{\begin{equation}}
\def\ee{\end{equation}}
\def\bea{\begin{eqnarray}}
\def\eea{\end{eqnarray}}
\def\nn{\nonumber}
\def\supp{\mathrm{supp}}
\def\dist{\mathrm{dist}}
\def\Ext{\mathrm{Ext}}
\def\Int{\mathrm{Int}}
\def\diam{\mathrm{diam}}