\documentstyle[12pt]{article}
\author{Yu.M.Burman}
\title{Triangulations of surfaces with boundary and the homotopy principle
for functions without critical points}
\date{December 13, 1997}
\begin{document}
% emlines.sty  Marz 1990, Georg Horn / Eberhard Mattes.
%
% Makros zum Zeichnen von Linien mit beliebiger Steigung.
% Nur bei Verwendung der DVI-Treiber von Eberhard Mattes.
%
% Der Makro \emline#1#2#3#4#5#6 setzt an die Koordinaten (#1,#2) den
% Punkt #3 und an die Koordinaten (#4,#5) den Punkt #6. Diese beiden
% Punkte werden dann verbunden.
%
% TeXcad erzeugt Aufrufe dieses Makros fur mit eingeschalteter
% EMLines-Option gezeichnete Linien.
% (z.B. \emline{0.0}{0.0}{1}{17.0}{4.0}{2}).
%
% Der Makro \newpic#1 definiert den Makro \emline so, dass den
% Punktnummern ##3 und ##6 die Ziffer #1 vorangestellt wird.
% Dies ist notwendig, wenn mehr als ein Bild auf einer Seite
% des Dokuments eingefuegt wird.
%
\def\newpic#1{%
   \def\emline##1##2##3##4##5##6{%
      \put(##1,##2){\special{em:point #1##3}}%
      \put(##4,##5){\special{em:point #1##6}}%
      \special{em:line #1##3,#1##6}}}
%
% Standarddefinition von \emline herstellen
%
\newpic{}
%
% Beispiel:
% \input bild1.pic
% \newpic{1} \input bild2.pic
%

%ADD.STY Version 2.63e (English)

%New theorem-like environments
% ------------------Numbered-------------------

\newcommand{\theoremName}{Theorem}
\newcommand{\lemmaName}{Lemma}
\newcommand{\corollaryName}{Corollary}
\newcommand{\statementName}{Statement}
\newcommand{\remarkName}{Remark}
\newcommand{\theremark}{\arabic{remark}}
\newcommand{\exampleName}{Example}
\newcommand{\theexample}{\arabic{example}}
\newcommand{\definitionName}{Definition}
\newcommand{\thedefinition}{\arabic{definition}}
\newcommand{\problemName}{Problem}
\newcommand{\theproblem}{\arabic{problem}}

\newtheorem {theorem}{\theoremName}
\newtheorem {lemma}{\lemmaName}
\newtheorem {corollary}{\corollaryName}
\newtheorem {statement}{\statementName}
\newcounter {remark}
\newenvironment {remark} {\refstepcounter{remark}\par\medskip\noindent{\bf
\remarkName\ \theremark\,\,} }{\par}
\newcounter {example}
\newenvironment {example} {\refstepcounter{example}\par\medskip\noindent{\bf
\exampleName\ \theexample\,\,} }{\par}
\newcounter {definition}
\newenvironment {definition} {\refstepcounter{definition}\par\medskip%
\noindent{\bf \definitionName\ \thedefinition\,\,}} {\par}
\newcounter {problem}
\newenvironment {problem} {\refstepcounter{problem}\par\medskip\noindent{\bf
\problemName\ \theproblem\,\,} }{\par}

% -----------------Not numbered---------------

\newcommand{\proofName}{Proof}
\newcommand{\answerName}{Answer}
\newcommand{\hintName}{Hint}

\newtheorem {Theorem}{\theoremName}
\newtheorem {Lemma}{\lemmaName}
\newtheorem {Corollary}{\corollaryName}
\newtheorem {Statement}{\statementName}
\newenvironment {Remark} {\par\medskip\noindent{\bf \remarkName\,\,}}
{\par}
\newenvironment {Example} {\par\medskip\noindent{\bf \exampleName\,\,}}
{\par}
\newenvironment {Problem} {\par\medskip\noindent{\bf \problemName\,\,}}
{\par}
\renewcommand \theTheorem {}
\renewcommand \theLemma {}
\renewcommand \theCorollary {}
\renewcommand \theStatement {}

\newenvironment {proof} {\par\medskip\noindent{\bf \proofName\,\,}}
{\qed\par}
\newenvironment {Proof} {\par\medskip\noindent{\bf \proofName\,\,}}
{\par}
\newenvironment {Definition} {\par\medskip\noindent{\bf
\definitionName\,\,}}{\par}
\newenvironment {Answer} {\par\medskip\noindent{\bf \answerName\,\,}}
{\par}
\newenvironment {Hint} {\par\medskip\noindent{\bf \hintName\,\,}} {\par}

% ------------------ An environment for lists with long items ---------
\newenvironment{stages}[1]{\csname @definecounter\endcsname{cnt#1}%
\def\nextstage{\refstepcounter{cnt#1}\par #1\space
\arabic{cnt#1}.\space}}{}

% ------------------ Apparent symbols -----------------

\def \Real {{I\!\!R}}
\def \Integer {{Z\!\!\!Z}}
\def \Natural {{I\!\!\!N}} %for compatibility with the Russian version
\def \Complex {{\,\prime\mskip-2.5\thinmuskip C}}
\def \Rational {{\,\prime\mskip-2.5\thinmuskip Q}}
\def \Quat {{I\!\!H}}
\def \Field {{I\!\!F}}
\def \Torus {{T\!\!\!T}}

% ------------------ Norm and absolute value ------------

\def \lnorm#1\rnorm {\vphantom{#1}\left\|\smash{#1}\right\|}
\def \lmod#1\rmod {\vphantom{#1}\left|\smash{#1}\right|}

% ------------------- More symbols ----------------------

\newcommand \bydef {\stackrel{\mbox{\scriptsize def}}{=}}
\newcommand \qed {\,\rule[-.23ex]{1.6ex}{1.6ex}}
\newcommand \Planck {{h^{\mskip-4.5\thinmuskip{-}}}}
\renewcommand \iff {$\Leftrightarrow$\space}

% ------------------ Tools ------------------------------
\newcommand \name[1] {\mathop{\rm #1}\nolimits}

% ------------------ Style conventions ------------------

\newcommand \eps {\varepsilon}
%\renewcommand \kappa {\varkappa}
\renewcommand \phi {\varphi}
\renewcommand \rho {\varrho}
%\renewcommand \emptyset {\varnothing}


\maketitle

\setcounter{totalnumber}{1}

\def \Chord {{\cal C}}
\def \Face {{\cal F}}
\def \Tria {{\cal T}}
\def \Cycle {{\cal Z}}
\def \Conn {{\cal U}}
\def \Map {{\cal X}}
\def \Graph {{\cal G}}
\def \Forms {\widetilde{\Omega^1}}
\def \Triv {\name{Triv}}
\def \Func {\widetilde{\Omega^0}}
\def \Diag {\name{Diag}}
\def \dM {{\partial M}}
\def \tM {{\widetilde M}}
\def \iff {\Leftrightarrow}

\begin{abstract}
We consider triangulations of surfaces with boundary and marked points.
These triangulations are classified with respect to flip equivalence. The
results obtained are applied to the homotopy classification of functions
without critical points on $2$-manifolds. It is shown that the set of such
functions satisfies the one-parametric {\em h}-principle.

{\em Key words:} triangulations, flip equivalence, homotopy principle.
\end{abstract}

\section*{Introduction}
Triangulations of surfaces have interested mathematicians since the early
days of the topology. More recently, remarkable connections were found
between triangulations and moduli space of Euclidean structures on the
sphere with conical singularities (W.Thurston \cite{ShPoly}), bifurcation
diagrams of quadratic differentials (Yu.Baryshnikov \cite{QuaDiff}), the
structure of Teichm\"uller spaces (R.C.Penner \cite{TeichmSp}), the
complexity of fiber bundles (S.S.Anisov \cite{Disser}), and many other
topics.

This article is devoted to triangulations of compact surfaces $G$ with
marked points regarded as vertices. In general, we allow $G$ to have a
boundary. This means that we must modify the concept of triangulation so
that some of the faces will not actually be triangles. Also we allow (as in
\cite{Disser}, \cite{FlipEq}, \cite{IUM}) some vertices and sides of the
same triangle to coincide, and some sides to collapse to points.

Our study of triangulations is motivated by the homotopy classification
problem for functions without critical points on topologically finite
$2$-manifolds. The set of such functions is denoted by $\Func(M)$. The
topological finiteness of a manifold $M$ means that $\pi_1(M)$ is finitely
generated or, equivalently, that there exists a compact surface $G$ with
boundary $\partial G$ and a finite set of marked points $V \subset G$ such
that $M = G \setminus V$. Consider two spaces, $\Func(M)$ and $\Forms(M)$.
The elements of $\Func(M)$ are smooth functions $f:M \to \Real$ having no
critical points and locally constant on the boundary $\dM$. The elements of
$\Forms(M)$ are $1$-forms $\nu$ on $M$ having no zeros and normal to $\dM$.
The exterior differentiation $d$ maps $\Func(M)$ to $\Forms(M)$. The main
result of the article is

\begin{theorem}\label{Th:HomPr}
The mapping $d_*:\pi_0(\Func(M)) \to \pi_0(\Forms(M))$ of the sets of
connected components is one-to-one.
\end{theorem}
In the terminology of the book \cite{PDR}, this means that the
one-parametric homotopy principle holds for $\Func(M)$. A similar result
was proved in \cite{Crit} for a special manifold (a disk with $n$ punctures
on its boundary).

The article has the following structure. In Section \ref{Sec:Tria} we
consider triangulations of compact surfaces with boundary and marked
points. Their elementary transformations (called {\em flips}) are defined,
and it is proved (Theorem \ref{Th:FlipEquiv}) that any two triangulations
can be connected by a finite sequence of flips (are {\em flip equivalent}).
Section \ref{Sec:TMV} is devoted to triangulations supplied with an
additional structure, that of marked vertices (one vertex of every triangle
is marked). For such triangulations flips can also be defined, but there
exist triangulations that are not flip equivalent. There is a flip
invariant with values in some lattice $L$ in the space of $1$-cochains of
the manifold $G \setminus V$ modulo boundary. We prove (Theorem
\ref{Th:FlipEqTMV}) that this invariant is complete.

Theorem \ref{Th:HomPr} is proved by using separate descriptions of the
connected components of the spaces $\Forms(M)$ and $\Func(M)$.  In Section
\ref{Sec:Forms} we consider the space $\Forms(M)$ and the space $\Triv(M)$
of trivializations of the tangent bundle $TM$ that at the same time
trivialize the bundle $T\dM$. It is shown that these two spaces are
homotopy equivalent. The connected components of spaces $\Forms(M)$ and
$\Triv(M)$ are put into one-to-one correspondence (Theorem
\ref{Th:HomTypeForm}) with the points of a lattice $L'$. The lattice $L'$
is isomorphic to $L$ if $M$ has no boundary, and to $L \times \Integer_2$
there is a nonempty boundary.

In Section \ref{Sec:Func} a generic function $f \in \Func(M)$ is associated
with each triangulation of $(G,V)$ with marked vertices. If a function
undergoes a homotopy within $\Func(M)$ then the associated triangulation
also undergoes a homotopy, and at some moments undergoes flips. Thus the
homotopy classification of functions without critical points is reduced to
the description of triangulations with marked vertices up to homotopy and
flips. This classification, obtained in Section \ref{Sec:TMV}, allows to
prove Theorem \ref{Th:HomPr}.

The article is concluded by a brief discussion of some unsolved problems.

\subsection*{Acknowledgments}

I am grateful to M.Kontsevich and S.Lando for stimulating discussions. I am
especially indebted to S.Anisov who pointed out some important errors in
the original text of the paper. A.Felikson and P.Tumarkin helped me greatly
by explaining many things about triangulations and acquainting me with the
excellent preprint \cite{ShPoly}. I am also grateful to D.Zvonkin for
valuable remarks he made concerning an earlier version of the paper. I
express my most sincere gratitude to A.Sossinsky who suggested many
improvements in the language of the article.

\section{Triangulations}\label{Sec:Tria}

\subsection{Webs and triangulations}\label{Subsec:Webs}
Consider a compact connected oriented surface $G$ with boundary and a
nonempty finite set of marked points $V = \{v_1,\dots,v_n\} \subset G$.
The cases $v_i \in \partial G$ and $v_i \in \name{int}G$ are both possible.
The term {\em side} (of $G$) will denote either a connected component of
$\partial G$ containing no marked points or a segment of $\partial G$
bounded by marked points.

A finite system $\Chord = \{\gamma_1,\dots,\gamma_n\}$ of smooth
nonselfintersecting curves $\gamma_i \subset G$ is called a {\em web} on
$(G,V)$ if it has the following properties:

\begin{enumerate}
\item all the sides of $G$ belong to $\Chord$;
\item each $\gamma_i$ is either a closed side or has two endpoints;
\item endpoints of the curves $\gamma_i$ belong to $V$;
\item different curves $\gamma_i$ do not intersect;
\item\label{It:Complete} if a smooth nonselfintersecting curve $\gamma$
does not intersect all the $\gamma_i \in \Chord$, then it is homotopic to
some $\gamma_i$ in $G \setminus V$.
\end{enumerate}
Curves $\gamma_i$ will be called {\em filaments} of the web. Note that
different filaments $\gamma_i$ may be homotopic to one another in $G
\setminus V$ (be ``parallel''). We will always consider webs up to isotopy.

{\em Triangulation} of $(G,V)$ is defined as a decomposition of $G$ into a
finite union of faces: $G = \bigcup \Face_i$. Each face is supplied with a
{\em characteristic mapping} $f_i: D_i \to \Face_i$ where $D_i$ is either a
triangle (such faces are called $A$-faces) or an annulus with a marked
point (vertex) on its outer boundary ($B$-faces). The set of characteristic
mappings should have the following properties:

\begin{enumerate}
\item if $D_i$ is an annulus, then $f_i$ is a smooth embedding;
\item for any $i$ the restriction $\left.f_i\right|_{\name{int} D_i}$ is a
smooth embedding, and the images of $\left.f_i\right|_{\name{int} D_i}$ for
different $i$ do not intersect each other;
\item for every (open) side $s$ of $D_i$ the restriction $\left.f\right|_s$
is either a smooth embedding or a mapping to a point;
\item images of sides of different $D_i$ and images of different sides of
the same $D_i$ either do not intersect or coincide;
\item vertices of $D_i$ are mapped to marked points $v_j \in V$.
\end{enumerate}
Images of the sides of $D_i$ are called {\em edges} of the triangulation.
As for webs, we do not distinguish isotopic triangulations.

\begin{figure}
\begin{center}
%\input facetype.pic
%TexCad Options
%\grade{\on}
%\emlines{\on}
%\beziermacro{\off}
%\reduce{\on}
%\snapping{\off}
%\quality{2.00}
%\graddiff{0.01}
%\snapasp{1}
%\zoom{1.00}
\special{em:linewidth 0.4pt}
\unitlength 1.00mm
\linethickness{0.4pt}
\begin{picture}(136.00,17.01)
\emline{2.88}{5.10}{1}{9.33}{14.66}{2}
\emline{9.33}{14.66}{3}{16.00}{4.88}{4}
\emline{16.00}{4.88}{5}{2.88}{4.88}{6}
\put(2.66,4.88){\circle*{0.88}}
\put(9.33,14.44){\circle*{0.88}}
\put(16.00,4.88){\circle*{0.88}}
\put(9.11,2.22){\makebox(0,0)[cc]{$A_1$}}
\emline{23.67}{11.00}{7}{26.34}{11.00}{8}
\emline{23.67}{10.00}{9}{26.00}{10.00}{10}
\emline{26.00}{9.00}{11}{26.00}{9.00}{12}
\put(25.33,16.00){\circle*{1.33}}
\put(25.00,7.33){\circle*{1.33}}
\put(25.00,3.00){\makebox(0,0)[cc]{$A_2$}}
%\bezier{36}(25.34,7.33)(22.00,12.00)(25.34,12.33)
\emline{25.34}{7.33}{13}{24.00}{9.59}{14}
\emline{24.00}{9.59}{15}{23.69}{11.18}{16}
\emline{23.69}{11.18}{17}{25.34}{12.33}{18}
%\end
%\bezier{36}(25.00,7.33)(28.34,12.00)(25.00,12.33)
\emline{25.00}{7.33}{19}{26.34}{9.59}{20}
\emline{26.34}{9.59}{21}{26.65}{11.18}{22}
\emline{26.65}{11.18}{23}{25.00}{12.33}{24}
%\end
\put(40.99,7.33){\circle*{1.33}}
%\bezier{36}(41.00,7.34)(36.00,9.34)(37.66,12.67)
\emline{41.00}{7.34}{25}{38.74}{8.55}{26}
\emline{38.74}{8.55}{27}{37.50}{9.97}{28}
\emline{37.50}{9.97}{29}{37.66}{12.67}{30}
%\end
%\bezier{44}(40.66,7.34)(43.00,12.67)(37.33,12.34)
\emline{40.66}{7.34}{31}{41.31}{9.47}{32}
\emline{41.31}{9.47}{33}{41.13}{11.02}{34}
\emline{41.13}{11.02}{35}{40.13}{11.98}{36}
\emline{40.13}{11.98}{37}{37.33}{12.34}{38}
%\end
%\bezier{40}(41.00,7.34)(46.00,7.34)(44.33,12.34)
\emline{41.00}{7.34}{39}{43.08}{7.65}{40}
\emline{43.08}{7.65}{41}{44.33}{8.59}{42}
\emline{44.33}{8.59}{43}{44.33}{12.34}{44}
%\end
%\bezier{32}(41.33,7.67)(41.66,12.34)(45.00,11.67)
\emline{41.33}{7.67}{45}{41.83}{10.07}{46}
\emline{41.83}{10.07}{47}{42.92}{11.42}{48}
\emline{42.92}{11.42}{49}{45.00}{11.67}{50}
%\end
\emline{37.33}{11.67}{51}{40.00}{11.67}{52}
\emline{37.33}{10.67}{53}{40.33}{10.67}{54}
\emline{37.66}{9.67}{55}{41.33}{9.67}{56}
\emline{39.00}{8.67}{57}{41.00}{8.67}{58}
\emline{42.66}{10.67}{59}{45.00}{10.67}{60}
\emline{42.00}{10.00}{61}{44.66}{10.00}{62}
\emline{42.33}{9.00}{63}{45.00}{9.00}{64}
\put(40.66,3.00){\makebox(0,0)[cc]{$A_3$}}
\put(56.33,8.33){\circle*{1.33}}
\put(56.33,4.00){\makebox(0,0)[cc]{$A_4$}}
%\bezier{60}(24.67,16.33)(18.67,12.67)(25.00,7.33)
\emline{24.67}{16.33}{65}{23.01}{15.06}{66}
\emline{23.01}{15.06}{67}{22.04}{13.70}{68}
\emline{22.04}{13.70}{69}{21.75}{12.25}{70}
\emline{21.75}{12.25}{71}{22.15}{10.70}{72}
\emline{22.15}{10.70}{73}{23.23}{9.06}{74}
\emline{23.23}{9.06}{75}{25.00}{7.33}{76}
%\end
%\bezier{64}(25.67,16.00)(32.00,11.67)(25.00,7.33)
\emline{25.67}{16.00}{77}{27.32}{14.65}{78}
\emline{27.32}{14.65}{79}{28.32}{13.29}{80}
\emline{28.32}{13.29}{81}{28.68}{11.94}{82}
\emline{28.68}{11.94}{83}{28.38}{10.58}{84}
\emline{28.38}{10.58}{85}{27.42}{9.23}{86}
\emline{27.42}{9.23}{87}{25.00}{7.33}{88}
%\end
%\bezier{60}(55.67,16.33)(49.67,12.67)(56.00,7.33)
\emline{55.67}{16.33}{89}{54.01}{15.06}{90}
\emline{54.01}{15.06}{91}{53.04}{13.70}{92}
\emline{53.04}{13.70}{93}{52.75}{12.25}{94}
\emline{52.75}{12.25}{95}{53.15}{10.70}{96}
\emline{53.15}{10.70}{97}{54.23}{9.06}{98}
\emline{54.23}{9.06}{99}{56.00}{7.33}{100}
%\end
%\bezier{64}(56.67,16.00)(63.00,11.67)(56.00,7.33)
\emline{56.67}{16.00}{101}{58.32}{14.65}{102}
\emline{58.32}{14.65}{103}{59.32}{13.29}{104}
\emline{59.32}{13.29}{105}{59.68}{11.94}{106}
\emline{59.68}{11.94}{107}{59.38}{10.58}{108}
\emline{59.38}{10.58}{109}{58.42}{9.23}{110}
\emline{58.42}{9.23}{111}{56.00}{7.33}{112}
%\end
\put(56.33,12.67){\circle*{1.33}}
\emline{56.33}{12.33}{113}{56.33}{8.00}{114}
\put(68.00,16.34){\circle*{1.33}}
\put(68.00,8.33){\circle*{1.33}}
\put(68.00,4.00){\makebox(0,0)[cc]{$A_5$}}
%\bezier{60}(67.33,16.33)(61.33,12.67)(67.67,7.33)
\emline{67.33}{16.33}{115}{65.67}{15.06}{116}
\emline{65.67}{15.06}{117}{64.70}{13.70}{118}
\emline{64.70}{13.70}{119}{64.42}{12.25}{120}
\emline{64.42}{12.25}{121}{64.81}{10.70}{122}
\emline{64.81}{10.70}{123}{65.90}{9.06}{124}
\emline{65.90}{9.06}{125}{67.67}{7.33}{126}
%\end
%\bezier{64}(68.33,16.00)(74.67,11.67)(67.67,7.33)
\emline{68.33}{16.00}{127}{69.99}{14.65}{128}
\emline{69.99}{14.65}{129}{70.99}{13.29}{130}
\emline{70.99}{13.29}{131}{71.34}{11.94}{132}
\emline{71.34}{11.94}{133}{71.04}{10.58}{134}
\emline{71.04}{10.58}{135}{70.09}{9.23}{136}
\emline{70.09}{9.23}{137}{67.67}{7.33}{138}
%\end
\put(83.33,6.66){\circle*{1.33}}
\put(83.00,2.33){\makebox(0,0)[cc]{$A_6$}}
%\bezier{48}(83.33,6.67)(79.33,13.00)(83.67,12.33)
\emline{83.33}{6.67}{139}{82.03}{9.00}{140}
\emline{82.03}{9.00}{141}{81.44}{10.73}{142}
\emline{81.44}{10.73}{143}{81.59}{11.85}{144}
\emline{81.59}{11.85}{145}{83.67}{12.33}{146}
%\end
%\bezier{44}(83.67,6.67)(87.33,12.33)(83.33,12.33)
\emline{83.67}{6.67}{147}{84.94}{8.95}{148}
\emline{84.94}{8.95}{149}{85.41}{10.65}{150}
\emline{85.41}{10.65}{151}{85.10}{11.76}{152}
\emline{85.10}{11.76}{153}{83.33}{12.33}{154}
%\end
\put(131.33,6.33){\circle*{1.33}}
\put(131.33,2.67){\makebox(0,0)[cc]{$B$}}
\put(131.34,12.67){\circle*{2.75}}
%\bezier{96}(41.00,7.33)(30.33,14.67)(41.00,16.33)
\emline{41.00}{7.33}{155}{39.01}{8.80}{156}
\emline{39.01}{8.80}{157}{37.48}{10.14}{158}
\emline{37.48}{10.14}{159}{36.42}{11.36}{160}
\emline{36.42}{11.36}{161}{35.81}{12.46}{162}
\emline{35.81}{12.46}{163}{35.67}{13.44}{164}
\emline{35.67}{13.44}{165}{36.00}{14.29}{166}
\emline{36.00}{14.29}{167}{36.79}{15.01}{168}
\emline{36.79}{15.01}{169}{38.04}{15.62}{170}
\emline{38.04}{15.62}{171}{41.00}{16.33}{172}
%\end
%\bezier{104}(41.00,7.33)(53.00,13.33)(41.00,16.33)
\emline{41.00}{7.33}{173}{43.09}{8.46}{174}
\emline{43.09}{8.46}{175}{44.73}{9.53}{176}
\emline{44.73}{9.53}{177}{45.93}{10.54}{178}
\emline{45.93}{10.54}{179}{46.68}{11.50}{180}
\emline{46.68}{11.50}{181}{46.99}{12.41}{182}
\emline{46.99}{12.41}{183}{46.86}{13.25}{184}
\emline{46.86}{13.25}{185}{46.28}{14.05}{186}
\emline{46.28}{14.05}{187}{45.26}{14.79}{188}
\emline{45.26}{14.79}{189}{43.80}{15.47}{190}
\emline{43.80}{15.47}{191}{41.00}{16.33}{192}
%\end
%\bezier{96}(82.67,7.33)(72.00,14.67)(82.67,16.33)
\emline{82.67}{7.33}{193}{80.68}{8.80}{194}
\emline{80.68}{8.80}{195}{79.15}{10.14}{196}
\emline{79.15}{10.14}{197}{78.09}{11.36}{198}
\emline{78.09}{11.36}{199}{77.48}{12.46}{200}
\emline{77.48}{12.46}{201}{77.34}{13.44}{202}
\emline{77.34}{13.44}{203}{77.67}{14.29}{204}
\emline{77.67}{14.29}{205}{78.46}{15.01}{206}
\emline{78.46}{15.01}{207}{79.71}{15.62}{208}
\emline{79.71}{15.62}{209}{82.67}{16.33}{210}
%\end
%\bezier{104}(82.67,7.33)(94.67,13.33)(82.67,16.33)
\emline{82.67}{7.33}{211}{84.76}{8.46}{212}
\emline{84.76}{8.46}{213}{86.40}{9.53}{214}
\emline{86.40}{9.53}{215}{87.60}{10.54}{216}
\emline{87.60}{10.54}{217}{88.35}{11.50}{218}
\emline{88.35}{11.50}{219}{88.66}{12.41}{220}
\emline{88.66}{12.41}{221}{88.53}{13.25}{222}
\emline{88.53}{13.25}{223}{87.95}{14.05}{224}
\emline{87.95}{14.05}{225}{86.93}{14.79}{226}
\emline{86.93}{14.79}{227}{85.47}{15.47}{228}
\emline{85.47}{15.47}{229}{82.67}{16.33}{230}
%\end
\emline{82.00}{11.67}{231}{85.00}{11.67}{232}
\emline{81.33}{11.00}{233}{85.67}{11.00}{234}
\emline{81.33}{10.00}{235}{85.00}{10.00}{236}
\emline{82.67}{9.33}{237}{84.33}{9.33}{238}
\emline{82.67}{8.67}{239}{84.33}{8.67}{240}
\put(103.33,6.33){\circle*{1.33}}
\put(103.00,2.00){\makebox(0,0)[cc]{$A_7$}}
%\bezier{96}(102.67,7.00)(92.00,14.34)(102.67,16.00)
\emline{102.67}{7.00}{241}{100.68}{8.46}{242}
\emline{100.68}{8.46}{243}{99.15}{9.81}{244}
\emline{99.15}{9.81}{245}{98.09}{11.03}{246}
\emline{98.09}{11.03}{247}{97.48}{12.13}{248}
\emline{97.48}{12.13}{249}{97.34}{13.10}{250}
\emline{97.34}{13.10}{251}{97.67}{13.95}{252}
\emline{97.67}{13.95}{253}{98.46}{14.68}{254}
\emline{98.46}{14.68}{255}{99.71}{15.29}{256}
\emline{99.71}{15.29}{257}{102.67}{16.00}{258}
%\end
%\bezier{104}(102.67,7.00)(114.67,13.00)(102.67,16.00)
\emline{102.67}{7.00}{259}{104.76}{8.12}{260}
\emline{104.76}{8.12}{261}{106.40}{9.19}{262}
\emline{106.40}{9.19}{263}{107.60}{10.21}{264}
\emline{107.60}{10.21}{265}{108.35}{11.17}{266}
\emline{108.35}{11.17}{267}{108.66}{12.07}{268}
\emline{108.66}{12.07}{269}{108.53}{12.92}{270}
\emline{108.53}{12.92}{271}{107.95}{13.71}{272}
\emline{107.95}{13.71}{273}{106.93}{14.45}{274}
\emline{106.93}{14.45}{275}{105.47}{15.13}{276}
\emline{105.47}{15.13}{277}{102.67}{16.00}{278}
%\end
\put(118.33,11.00){\circle{10.69}}
\put(119.00,8.33){\circle*{1.33}}
\put(119.00,12.67){\circle*{1.33}}
\emline{119.00}{12.33}{279}{119.00}{8.00}{280}
\put(118.33,2.00){\makebox(0,0)[cc]{$A_8$}}
\put(131.33,11.00){\circle{9.33}}
\end{picture}
\end{center}
\caption{Types of faces}\label{Fig:FaceType}
\end{figure}

\begin{statement}\label{St:CDToTria}
Edges of any triangulation $\Tria$ form a web. For every web $\Chord$ there
exists a triangulation $\Tria$ such that its filaments are edges of
$\Chord$.
\end{statement}
\begin{proof}
The first assertion is obvious. To prove the second one, take a web
$\Chord$ and observe that its filaments divide $G$ to parts, whose
topological types are enumerated in Fig. \ref{Fig:FaceType}. In this Figure
bold points denote vertices, and the shaded areas do not belong to the
faces. The face $A_8$ is a sphere with two marked points. If it exists,
then it is the only face of the web.

For any part of the types $A_1$--$A_8$, $B$ a characteristic mapping is
easily constructed.
\end{proof}

For a triangulation $\Tria$ consider its dual graph $\Graph(\Tria)$. Its
vertices are faces of $\Tria$, and its edges correspond to noncontracted
edges of $\Tria$. If an edge $\gamma$ of $\Tria$ does not separate two
faces, then it corresponds to a loop in $\Graph(\Tria)$. Vertices of
$\Graph(\Tria)$ have valences $1$, $2$, or $3$.

\subsection{Flips, cancellations, and flip equivalence}\label{Subsec:Flip}

\begin{figure}
\begin{center}
%\input flips.pic
%TexCad Options
%\grade{\on}
%\emlines{\on}
%\beziermacro{\off}
%\reduce{\on}
%\snapping{\off}
%\quality{2.00}
%\graddiff{0.01}
%\snapasp{1}
%\zoom{1.00}
\special{em:linewidth 0.4pt}
\unitlength 1mm
\linethickness{0.4pt}
\begin{picture}(106.33,32.33)
\emline{27.67}{2.33}{1}{14.67}{14.00}{2}
\emline{14.67}{14.00}{3}{27.33}{25.33}{4}
\emline{27.33}{25.33}{5}{39.00}{13.67}{6}
\emline{39.00}{13.67}{7}{27.00}{2.67}{8}
\emline{27.00}{2.67}{9}{27.00}{25.00}{10}
\emline{14.67}{14.00}{11}{38.67}{13.67}{12}
\put(27.00,25.00){\circle*{1.33}}
\put(15.00,14.00){\circle*{1.33}}
\put(27.00,2.67){\circle*{1.33}}
\put(38.67,13.67){\circle*{1.33}}
\put(20.00,15.67){\makebox(0,0)[cc]{$\ell$}}
\put(29.33,20.33){\makebox(0,0)[cc]{$\ell'$}}
%\vector(45.33,32.33)(51.33,27.67)
\put(51.33,27.67){\vector(4,-3){0.2}}
\emline{45.33}{32.33}{13}{51.33}{27.67}{14}
%\end
%\vector(52.33,27.00)(52.33,21.00)
\put(52.33,21.00){\vector(0,-1){0.2}}
\emline{52.33}{27.00}{15}{52.33}{21.00}{16}
%\end
%\vector(52.33,21.00)(46.33,18.00)
\put(46.33,18.00){\vector(-2,-1){0.2}}
\emline{52.33}{21.00}{17}{46.33}{18.00}{18}
%\end
%\vector(58.00,31.33)(53.00,27.67)
\put(53.00,27.67){\vector(-4,-3){0.2}}
\emline{58.00}{31.33}{19}{53.00}{27.67}{20}
%\end
%\vector(53.00,27.67)(53.00,27.67)
\put(53.00,27.67){\vector(0,1){0.2}}
\emline{53.00}{27.67}{21}{53.00}{27.67}{22}
%\end
%\vector(53.00,21.00)(58.67,17.33)
\put(58.67,17.33){\vector(3,-2){0.2}}
\emline{53.00}{21.00}{23}{58.67}{17.33}{24}
%\end
%\vector(43.00,10.67)(49.00,6.00)
\put(49.00,6.00){\vector(4,-3){0.2}}
\emline{43.00}{10.67}{25}{49.00}{6.00}{26}
%\end
%\vector(49.00,6.00)(43.00,3.00)
\put(43.00,3.00){\vector(-2,-1){0.2}}
\emline{49.00}{6.00}{27}{43.00}{3.00}{28}
%\end
%\vector(60.67,9.67)(55.67,6.00)
\put(55.67,6.00){\vector(-4,-3){0.2}}
\emline{60.67}{9.67}{29}{55.67}{6.00}{30}
%\end
%\vector(56.00,6.33)(61.67,2.67)
\put(61.67,2.67){\vector(3,-2){0.2}}
\emline{56.00}{6.33}{31}{61.67}{2.67}{32}
%\end
%\vector(55.00,6.00)(49.00,6.00)
\put(49.00,6.00){\vector(-1,0){0.2}}
\emline{55.00}{6.00}{33}{49.00}{6.00}{34}
%\end
\emline{52.33}{14.67}{35}{49.67}{12.67}{36}
\emline{49.67}{12.67}{37}{51.33}{12.67}{38}
\emline{51.33}{12.67}{39}{51.33}{11.00}{40}
\emline{51.33}{11.00}{41}{50.00}{11.00}{42}
\emline{50.00}{11.00}{43}{52.33}{10.00}{44}
\emline{52.33}{10.00}{45}{54.00}{10.67}{46}
\emline{54.00}{10.67}{47}{53.00}{10.67}{48}
\emline{53.00}{10.67}{49}{53.00}{12.67}{50}
\emline{53.00}{12.67}{51}{54.00}{12.67}{52}
\emline{54.00}{12.67}{53}{52.33}{14.00}{54}
\put(89.00,25.00){\circle*{1.33}}
\put(89.00,2.67){\circle*{1.33}}
%\bezier{168}(89.00,25.00)(71.00,15.33)(89.00,3.00)
\emline{89.00}{25.00}{55}{86.98}{23.84}{56}
\emline{86.98}{23.84}{57}{85.22}{22.66}{58}
\emline{85.22}{22.66}{59}{83.72}{21.46}{60}
\emline{83.72}{21.46}{61}{82.47}{20.25}{62}
\emline{82.47}{20.25}{63}{81.47}{19.01}{64}
\emline{81.47}{19.01}{65}{80.73}{17.76}{66}
\emline{80.73}{17.76}{67}{80.25}{16.48}{68}
\emline{80.25}{16.48}{69}{80.02}{15.19}{70}
\emline{80.02}{15.19}{71}{80.05}{13.88}{72}
\emline{80.05}{13.88}{73}{80.33}{12.55}{74}
\emline{80.33}{12.55}{75}{80.86}{11.20}{76}
\emline{80.86}{11.20}{77}{81.65}{9.83}{78}
\emline{81.65}{9.83}{79}{82.70}{8.44}{80}
\emline{82.70}{8.44}{81}{84.00}{7.04}{82}
\emline{84.00}{7.04}{83}{85.56}{5.61}{84}
\emline{85.56}{5.61}{85}{89.00}{3.00}{86}
%\end
%\bezier{164}(89.33,25.00)(106.33,12.00)(88.67,2.67)
\emline{89.33}{25.00}{87}{91.28}{23.43}{88}
\emline{91.28}{23.43}{89}{92.96}{21.88}{90}
\emline{92.96}{21.88}{91}{94.39}{20.37}{92}
\emline{94.39}{20.37}{93}{95.56}{18.88}{94}
\emline{95.56}{18.88}{95}{96.48}{17.41}{96}
\emline{96.48}{17.41}{97}{97.13}{15.98}{98}
\emline{97.13}{15.98}{99}{97.53}{14.57}{100}
\emline{97.53}{14.57}{101}{97.67}{13.19}{102}
\emline{97.67}{13.19}{103}{97.55}{11.84}{104}
\emline{97.55}{11.84}{105}{97.18}{10.51}{106}
\emline{97.18}{10.51}{107}{96.54}{9.21}{108}
\emline{96.54}{9.21}{109}{95.65}{7.94}{110}
\emline{95.65}{7.94}{111}{94.50}{6.69}{112}
\emline{94.50}{6.69}{113}{93.09}{5.48}{114}
\emline{93.09}{5.48}{115}{91.43}{4.29}{116}
\emline{91.43}{4.29}{117}{88.67}{2.67}{118}
%\end
\put(89.00,13.00){\circle*{4.00}}
%\bezier{104}(89.33,2.67)(80.33,17.67)(88.67,19.00)
\emline{89.33}{2.67}{119}{87.76}{5.42}{120}
\emline{87.76}{5.42}{121}{86.51}{7.93}{122}
\emline{86.51}{7.93}{123}{85.58}{10.18}{124}
\emline{85.58}{10.18}{125}{84.97}{12.18}{126}
\emline{84.97}{12.18}{127}{84.69}{13.93}{128}
\emline{84.69}{13.93}{129}{84.72}{15.43}{130}
\emline{84.72}{15.43}{131}{85.07}{16.67}{132}
\emline{85.07}{16.67}{133}{85.74}{17.66}{134}
\emline{85.74}{17.66}{135}{86.74}{18.39}{136}
\emline{86.74}{18.39}{137}{88.67}{19.00}{138}
%\end
%\bezier{96}(88.67,2.67)(96.67,15.67)(88.67,19.00)
\emline{88.67}{2.67}{139}{90.16}{5.27}{140}
\emline{90.16}{5.27}{141}{91.31}{7.66}{142}
\emline{91.31}{7.66}{143}{92.10}{9.85}{144}
\emline{92.10}{9.85}{145}{92.56}{11.82}{146}
\emline{92.56}{11.82}{147}{92.66}{13.59}{148}
\emline{92.66}{13.59}{149}{92.42}{15.14}{150}
\emline{92.42}{15.14}{151}{91.83}{16.49}{152}
\emline{91.83}{16.49}{153}{90.89}{17.62}{154}
\emline{90.89}{17.62}{155}{88.67}{19.00}{156}
%\end
%\bezier{112}(88.67,24.67)(78.00,10.67)(88.67,8.67)
\emline{88.67}{24.67}{157}{86.93}{22.26}{158}
\emline{86.93}{22.26}{159}{85.54}{20.05}{160}
\emline{85.54}{20.05}{161}{84.48}{18.03}{162}
\emline{84.48}{18.03}{163}{83.77}{16.20}{164}
\emline{83.77}{16.20}{165}{83.39}{14.56}{166}
\emline{83.39}{14.56}{167}{83.36}{13.11}{168}
\emline{83.36}{13.11}{169}{83.67}{11.85}{170}
\emline{83.67}{11.85}{171}{84.31}{10.79}{172}
\emline{84.31}{10.79}{173}{85.30}{9.92}{174}
\emline{85.30}{9.92}{175}{86.63}{9.23}{176}
\emline{86.63}{9.23}{177}{88.67}{8.67}{178}
%\end
%\bezier{116}(89.00,24.67)(99.67,10.00)(89.00,8.33)
\emline{89.00}{24.67}{179}{90.68}{22.23}{180}
\emline{90.68}{22.23}{181}{92.04}{20.00}{182}
\emline{92.04}{20.00}{183}{93.09}{17.95}{184}
\emline{93.09}{17.95}{185}{93.82}{16.10}{186}
\emline{93.82}{16.10}{187}{94.23}{14.44}{188}
\emline{94.23}{14.44}{189}{94.33}{12.97}{190}
\emline{94.33}{12.97}{191}{94.11}{11.70}{192}
\emline{94.11}{11.70}{193}{93.57}{10.62}{194}
\emline{93.57}{10.62}{195}{92.71}{9.73}{196}
\emline{92.71}{9.73}{197}{91.54}{9.04}{198}
\emline{91.54}{9.04}{199}{89.00}{8.33}{200}
%\end
\put(89.00,6.67){\makebox(0,0)[cc]{$\ell$}}
\put(90.00,20.33){\makebox(0,0)[cc]{$\ell'$}}
\end{picture}
\end{center}
\caption{Flips}\label{Fig:Flips}
\end{figure}

A {\em flip} is an elementary transformation of the triangulation affecting
two faces $\Face_i$ and $\Face_j$. The faces $\Face_i$ and $\Face_j$ must
be adjacent (i.e., have a common edge $\gamma$), and at least one of them
must be an $A$-face. The characteristic mappings $f_i:D_i \to \Face_i$ and
$f_j:D_j \to \Face_j$ may be considered as restrictions of some mapping
$f:D \to \Face_i \cup \Face_j$ where $D$ is $D_i$ and $D_j$ glued as
follows: $x \sim y \iff f_i(x) = f_j(y) \in \gamma$. $D$ is either a
quadrilateral (if both $\Face_i$ and $\Face_j$ are $A$-faces), or a
triangle with a hole (if one of the faces is a $B$-face). In both cases
flip consists in the change of the edge $\gamma = f(\ell)$ by the edge
$\gamma' = f(\ell')$ where $\ell'$ is shown in Fig.  \ref{Fig:Flips}. The
mapping $f$ remains the same (it is only necessary to smoothen it near
$\ell$), and the new characteristic mappings are its restrictions to the
parts of $D$ separated by $\ell'$.

Note that flips of two $B$-faces do not exist but are unnecessary. Indeed,
two $B$-faces may be adjacent only if the triangulation contains no more
faces at all. In this case the surface $G$ is an annulus with a marked
point in its interior. Such $G$ allows only one triangulation.

Another elementary transformation of the triangulation is a {\em
cancellation}: if an edge $\gamma$ separates two faces such that one of
them is $A_5$, $A_6$, or $A_7$, then it can be erased. We consider the
inverse operation (drawing of a new edge), too.

\begin{theorem}\label{Th:FlipEquiv}
Any two triangulations of $(G,V)$ are flip equivalent, i.e. can be joined
by a finite sequence of flips, cancellations, and inverse operations.
\end{theorem}

Recall that we consider triangulations up to homotopy.

\begin{proof}
The correspondence between triangulations and webs given by Statement
\ref{St:CDToTria} is not unique, even up to homotopy. The obstacle is
formed by the biangular faces $A_5$: it is possible to contract a side of
the triangle $D_i$ to either vertex. But if this vertex is fixed, then the
web determines the triangulation uniquely. Therefore two triangulations
with the same edges are flip equivalent, because all the biangular faces
can be cancelled and then restored.

Consider two triangulations, $\Tria_0$ and $\Tria$, and let $\Chord_0 =
\{\gamma_1^0,\dots,\gamma_{n_0}^0\}$ and $\Chord =
\{\gamma_1,\dots,\gamma_n\}$ be corresponding webs. It is sufficient to
find a sequence of flips, cancellations, and inverse operations that
converts $\Chord_0$ to $\Chord$.

To do this, take the filament $\gamma_1$ joining vertices $v_0$ and $v_1$.
For a generic web $\Chord$ the filament $\gamma_1$ intersects filaments of
the web $\Chord_0$ transversely in a finite number of points. Of all the
curves homotopic to $\gamma_1$ we always choose such one that the number
$k$ of intersection points is as small as possible. If $k$ is not zero,
then take the first intersected filament and flip it. Then take the next
filament, etc. To prove that the process of flipping is finite, consider
the incidence number $c$ of the vertex $v_0$, i.e. number of {\em filament
ends} adjacent to $v_0$. The number $c$ changes in the course of flipping,
giving the sequence $c_0, c_1, \dots$.  Assume that the process of flipping
is infinite. Then there holds

\begin{lemma}\label{Lm:Finite}
For any $i$ there exists $j > i$ such that $c_j > c_i$.
\end{lemma}
{\def \proofName {Proof of Lemma \ref{Lm:Finite}}
\begin{proof}
Let after $i$ flips $\Face_1$ be the first face intersected by $\gamma_1$,
and $\Face_2$ be the second face. A rather tedious but straightforward
enumeration of possible types of faces $\Face_1$ and $\Face_2$ shows that
$c_{i+1} = c_i + 1$ for all the cases except the following:

\begin{enumerate}
\item\label{It:A2A2} $\Face_1 = A_2, \Face_2 = A_2$, and the shaded areas
(see the $A_2$-face in Fig. \ref{Fig:FaceType}) hang on different vertices.
Here $c_{i+1} = c_i$, and after the $(i+1)$-st flip $\Face_1$ is still
$A_2$.
\item\label{It:A3A6} $\Face_1 = A_3, \Face_2 = A_6$. Here $c_{i+1} = c_i$,
and after the $(i+1)$-st flip $\Face_1$ becomes $A_2$.
\item\label{It:A3B} $\Face_1 = A_3, \Face_2 = B$. Here $c_{i+1} = c_i$, and
after the $(i+1)$-st flip $\Face_1$ becomes $A_2$.
\item\label{It:A3A2} $\Face_1 = A_3, \Face_2 = A_2$. Here $c_{i+1} =
c_i-1$, and after the $(i+1)$-st flip $\Face_1$ becomes $A_2$.
\end{enumerate}

Consider these cases separately.

Case \ref{It:A2A2}. It is the only case when $\Face_1 = A_2$ but $c_{i+1}$
is not greater than $c_i$. So, if the lemma is not true, then $\Face_2$
remains $A_2$ forever. Since the number of $A_2$-faces is finite, this
means that sooner or later $\gamma_1$ intersects some face for the second
time. It is possible only if the triangulation contains nothing except
$A_2$-faces. But in this case the flipping process is finite because the
number $k$ of intersection points of $\gamma_1$ with the filaments of
$\Chord_0$ decreases in every step. So, if $\Face_1 = A_2$, then the
assertion of the lemma holds.

Cases \ref{It:A3A6} and \ref{It:A3B}. After the flip $\Face_1 = A_2$, and
therefore it follows from the previous argument that there exists $j > i+1$
such that $c_j > c_{i+1} = c_i$.

Case \ref{It:A3A2}. Since after the flip $\Face_2$ becomes an $A_2$-face,
there exists $k > i+1$ such that $c_k = c_{i+1} + 1 = c_i$. Obviously,
before the $k$-th flip $\Face_1$ is $A_2$, and after the $k$-th flip
$\Face_1$ is either $A_1$ or $A_2$. Therefore there exists $j > k > i$ such
that $c_j > c_k = c_i$. Lemma is proved.
\end{proof}
}

Lemma \ref{Lm:Finite} implies that the flipping stops after a finite number
of steps. Indeed, the number $E$ of edges in the triangulation remains
constant (we have not used cancellations so far !). Therefore $c_i \le 2E$
for any $i$, contrary to the lemma. When the process stops, we obtain a web
which is flip equivalent to $\Chord_0$ and has no edges intersecting
$\gamma_1$. We can add $\gamma_1$ to this web (this is the operation
inverse to cancellation) to obtain the web $\Chord_1$.

Now, repeat this procedure with the filament $\gamma_2 \in \Chord$ and the
web $\Chord_1$. Note that $\gamma_1$ will not be flipped because it does
not intersect $\gamma_2$ (they both are filaments of the same web
$\Chord$). Thus we arrive to the web $\Chord_3$ having both $\gamma_1$ and
$\gamma_2$ its filaments, etc. The final result will be some web $\Chord_N$
containing all the filaments $\gamma_1, \dots, \gamma_n \in \Chord$. It can
contain other filaments also, but, by the definition of the web, such
additional filaments must be parallel to some $\gamma_i$. Therefore they
can be deleted by cancellation of the relevant biangular faces.
\end{proof}

Theorem \ref{Th:FlipEquiv} is similar to the main theorem of \cite{FlipEq}
and to Theorem 1 of \cite{Disser}, Chapter 3. The difference is that in
\cite{Disser} and \cite{FlipEq} the vertices are not fixed since no marked
points are considered.

\section{Vertex marking}\label{Sec:TMV}
\subsection{Definitions and simplification}\label{Subsec:Def}
Consider triangulations of $(G,V)$ supplied with an additional structure,
that of the marked vertices. For any $A$-face $\Face_i$ we mark one vertex
of the triangle $D_i$ (recall that $D_i$ is the domain of definition of the
characteristic mapping $f_i:D_i \to \Face_i \subset G$).  Triangulations
with marked vertices will be abbreviated as TMVs.

Let $\Face$ be a face of $\Tria$, i.e., a vertex of its dual graph
$\Graph(\Tria)$, and $v_i,v_j$ and $v_k$ be its vertices, $v_k$ marked.
Then $\Graph(\Tria)$ contains edges incident to $\Face$ and dual to
$v_iv_k$, $v_jv_k$, and $v_iv_j$; we call them $e_j$, $e_i$, and $e_k$,
respectively. An orientation of the graph $\Graph(\Tria)$ is called {\em
compatible with the vertex marking}, if $e_j$ and $e_i$ have the same
direction (both are oriented away from $\Face$, or both towards it), and
$e_k$ has the opposite direction. It is easy to see that a compatible
orientation, if exists, is unique up to reversal of all the arrows.

Flips of TMVs are defined as before (vertex markings stay unchanged). Since
each of the two faces obtained after a flip must have one vertex marked, it
is required that the marked vertices in the faces to be flipped did not
coincide (else the flip is forbidden). A similar restriction applies to
cancellations: a biangular face can be cancelled if the collapsed side
contains the marked vertex. If $\sigma$ is an orientation of
$\Graph(\Tria_1)$ compatible with the marking, and $\Tria_2$ is a TMV that
differs from $\Tria_1$ by a flip, then $\Graph(\Tria_2)$ can be assigned a
compatible orientation $\sigma_2$ (see Fig. \ref{Fig:Flips}).

Unlike ordinary triangulations, for TMV not all the biangular faces can be
cancelled. But if two such faces are ``antiparallel'' (i.e., one face has
the vertices $v_iv_jv_i$, $v_j$ marked, and the other face, $v_jv_iv_j$,
$v_i$ marked, and the edges are all parallel), then they can be deleted:
flip them and cancel the result. Call a TMV {\em simplified} if it does not
contain cancellable and antiparallel biangular faces. Any TMV $\Tria$ is
flip equivalent to a simplified TMV $\Tria_0$. If the dual graph of a
simplified TMV admits an orientation compatible with vertex marking, then
the graph has no sources and sinks, i.e., if a vertex has valence greater
than $1$, then there are both incoming and outgoing edges incident to it.

A simplified TMV $\Tria_0$ can be encoded by its {\em diagram}.  Call a TMV
{\em simple} if it does not contain any cancellable and biangular faces at
all. The diagram $\Diag(\Tria_0) \bydef \Diag(\Tria)$ is the pair
$\bigl(\Tria^*,s\bigr)$, where $\Tria^*$ is a simple TMV, and $s \in
\Cycle_1(G, V; \Integer)$. The encoding is the following: delete all the
biangular faces from $\Tria_0$ to get $\Tria^*$, and take $s = \sum_i k_i
e_i$ where $k_i$ is the number of biangular faces in $\Tria_0$ going along
the edge $e_i$ (with the fixed orientation !). The previous argument shows
that the TMV $\Tria$ can be restored from its diagram up to flip
equivalence (a simplified TMV --- uniquely). Obviously,
%*
\begin{equation}\label{Eq:NMinusN}
n_\Tria(\gamma) = n_{\Tria^*}(\gamma) + \langle s,\gamma\rangle
\end{equation}
%*
for any $\gamma \in \Cycle_1(G \setminus V, \partial G; \Integer)$; here
$\langle \cdot, \cdot \rangle$ denotes the intersection index.

Flips of TMV affect their diagrams in the following way. Cancellations do
not change $\Diag(\Tria) = \bigl(\Tria^*,s\bigr)$ at all. The $AB$-flip and
the $AA$-flip not involving biangular faces look like flips of $\Tria^*$;
the flipped edge $e$ must not enter the cycle $s$ (because the
corresponding faces are really adjacent in $\Tria$, not separated by some
biangular face). An $AA$-flip involving a biangular face (exactly one, or
else the flip is impossible) does not change edges of the triangulation
$\Tria^*$. For the flipped triangular $A$-face in $\Tria^*$ the marking
jumps from the vertex $v_i$ to the vertex $v_j$ along the edge $e$, and $s$
changes to $s - e$. We will call this operation ``moving the marking''.

\subsection{The invariant}\label{Subsec:Invar}
Let $\Tria$ be a TMV. Consider a simple smooth curve $\gamma \subset G
\setminus V$ intersecting the edges of $\Tria$ transversally. Suppose that
either $\gamma$ is closed or its endpoints belong to $\partial G$. Let
$a_1, \dots, a_k$ be the intersection points of $\gamma$ with the edges of
$\Tria$ (including endpoints if $\gamma$ has them). The segment
$[a_i,a_{i+1}] \subset \gamma$ belongs to a face $f_i:D_i \to \Face_i$ of
$\Tria$; let $p_i \bydef f_i^{-1}([a_i,a_{i+1}]) \subset D_i$. Consider the
number $n_\Tria(\gamma) = \sum_i n_i$ where $n_i$ Is defined as follows. If
$D_i$ is a triangle, then take
%*
\begin{equation}\label{Eq:DiTria}
n_i = \left\{\begin{array}{rl}
+1, &\mbox{if $p_i$ intersects two sides of $D_i$ containing the marked
vertex,} \\
&\mbox{and the vertex lies to the left of $p_i$,}\\
-1, &\mbox{if $p_i$ intersects two sides of $D_i$ containing the marked
vertex,} \\
&\mbox{and the vertex lies to the right from $p_i$,}\\
+1, &\mbox{if $p_i$ intersects only one side of $D_i$, and the marked
vertex}\\
&\mbox{lies to the right of $p_i$,}\\
-1, &\mbox{if $p_i$ intersects only one side of $D_i$, and the marked
vertex}\\
&\mbox{lies to the left of $p_i$,}\\
0 &\mbox{otherwise.}
\end{array}\right.
\end{equation}
%*
If $D_i$ is an annulus, then take
%*
\begin{equation}\label{Eq:DiAnn}
n_i = \left\{\begin{array}{rl}
+1, &\mbox{if both endpoints of $p_i$ belong to the same component} \\
& \mbox{of the boundary $\partial D_i$,} \\
&\mbox{and the vertex lies to the left from $p_i$},\\
-1, &\mbox{if both endpoints of $p_i$ belong to the same component} \\
&\mbox{of the boundary $\partial D_i$,} \\
&\mbox{and the vertex lies to the right from $p_i$},\\
0 &\mbox{otherwise.}
\end{array}\right.
\end{equation}
%*

\begin{statement}\label{St:InvFuncN}
Functional $n_\Tria$ is homotopy invariant
\end{statement}

\begin{proof}
Let $\gamma_t$ be a homotopy of smooth curves with endpoints in $\partial
G$. We can assume that it is generic. This means that the curves $\gamma_t$
intersect the edges of $\Tria$ transversally for all $t \in [0,1]$ except a
finite set $\{t_1, \dots, t_s\}$ of critical values. While $t$ remains
uncritical, equality $n_\Tria(\gamma_t) = const\,$ is obvious.  For a
critical $t = t_i$ curve $\gamma_{t_i}$ touches an edge of $\Tria$ at a
single point. It is easy to check using formulas (\ref{Eq:DiTria}) and
(\ref{Eq:DiAnn}) that $n_\Tria(\gamma_t)$ does not change when $t$ passes
through a critical value.
\end{proof}

Homotopy invariance allows to define $n_\Tria(\gamma)$ for non-generic
curves $\gamma$. By $\Integer$-linearity the functional $n_\Tria$ can be
extended to a $\Integer$-valued $1$-cochain $n_\Tria \in \Cycle^1(G
\setminus V, \partial G; \Integer)$.

\begin{statement}\label{St:PropCochN}
Values of the cochain $n_\Tria$ on the $1$-cycles $\gamma \in \Cycle_1(G
\setminus V, \partial G; \Integer)$ does not change if the TMV $\Tria$
undergoes a homotopy, a flip, or a cancellation. The differential $dn_\Tria
\bydef \Delta \in \Cycle^2(G \setminus V, \partial G; \Integer)$ does not
depend on $\Tria$.
\end{statement}

\begin{proof}
Dependence of $n_\Tria(\gamma)$ on $\Tria$ is apparently continuous. On the
other hand, $n_\Tria(\gamma) \in \Integer$, and therefore $n_\Tria(\gamma)$
is invariant under the homotopies of $\Tria$. Straightforward checking
shows that the values $n_\Tria(\gamma)$ are also flip invariant.

Show that $dn_\Tria$ does not depend on $\Tria$. By virtue of Theorem
\ref{Th:FlipEquiv} it is enough to check that $dn_\Tria$ is flip invariant
and remains constant if the vertex marking changes. Flip invariance of
$dn_\Tria$ follows from that of $n_\Tria$. Let now in some $A$-face $\Face$
the marking jump from the vertex $v_i$ to the vertex $v_j$ along the edge
$s$, converting triangulation $\Tria$ to triangulation $\Tria'$. It is easy
to see that for an arbitrary cycle $\gamma \in \Cycle_1(G \setminus V,
\partial G; \Integer)$
%*
\begin{equation}\label{Eq:InterInd}
n_\Tria(\gamma) - n_{\Tria'}(\gamma) = \langle s,\gamma\rangle
\end{equation}
%*
Thus, for a $2$-chain ${\cal H}$
%*
\begin{displaymath}
dn_\Tria({\cal H}) - dn_{\Tria'}({\cal H}) = n_\Tria(\partial {\cal H}) -
n_{\Tria'}(\partial {\cal H}) = \langle s,\partial {\cal H}\rangle = 0.
\end{displaymath}
%*
Statement is proved.
\end{proof}

\subsection{Completeness of the invariant}\label{Subsec:Compl}
Flip invariance of $n_\Tria(\gamma)$ for relative cycles $\gamma$ proves
that there exist TMV which are not flip equivalent. $n_\Tria(\gamma)$
appears, though, to be the only obstacle to the flip equivalence. More
exactly, there holds

\begin{theorem}\label{Th:FlipEqTMV}
Triangulations with marked vertices $\Tria_0$ and $\Tria_1$ are flip
equivalent if and only if $n_{\Tria_1}(\gamma) = n_{\Tria_2}(\gamma)$ for
any $\gamma \in \Cycle_1(G \setminus V, \partial G; \Integer)$. For any
$1$-cochain $n$ such that $dn = \Delta$ there exists a triangulation
$\Tria$ such that $n(\gamma) = n_\Tria(\gamma)$ for any $\gamma \in
\Cycle_1(G \setminus V, \partial G; \Integer)$.
\end{theorem}

So, flip equivalence classes of TMV form a lattice $L \subset \Cycle_1(G
\setminus V, \partial G; \Integer)$.

\begin{proof}
Let $\Diag(\Tria_1) = \bigl(\Tria_1^*,s_1\bigr)$ and $\Diag(\Tria_2) =
\bigl(\Tria_2^*,s_2\bigr)$ be two diagrams such that $n_{\Tria_1} =
n_{\Tria_2}$ on relative cycles. We wish to find a sequence of flips that
converts $\bigl(\Tria_1^*,s_1\bigr)$ to $\bigl(\Tria_2^*,s_2\bigr)$.

First, forget about vertex markings and cycles $s_i$, and consider
triangulations $\Tria_1^*$ and $\Tria_2^*$ alone. By Theorem
\ref{Th:FlipEquiv}, it is possible to convert $\Tria_1^*$ to $\Tria_2^*$ if
it is possible to make flips. The flip of faces $\Face_1$ and $\Face_2$
separated by the edge $\gamma$ is allowed if vertex markings near $\gamma$
are in right positions, and $\gamma$ does not enter the cycle $s$. Moving
the markings (see Subsection \ref{Subsec:Def}) in $\Face_1$ and $\Face_2$,
we can put them where necessary. If the marking is moved inside the same
face, say $\Face_1$, three times, then the simple TMV $\Tria'$ remains the
same, but $s$ changes to $s - \partial \Face_1$.  Doing it several times,
we can obtain the cycle $s'$ that does not contain $\gamma$. After all this
we are able to make the flip.

So, $\bigl(\Tria_1^*,s_1\bigr)$ is flip equivalent to the diagram
$\bigl(\Tria_2^*,s\bigr) \bydef \Diag(\widetilde{\Tria_2})$ for some $s$.
To convert $s$ to $s_2$ we will act as follows. Choose an initial edge
$e_1$ separating the faces $\Face_1$ and $\Face_2$. If $\partial G \ne
\emptyset$, then it is convenient to take $e_1 \subset \partial G$ and
assume $\Face_1 = \emptyset$. Suppose that $e_1$ enters the cycle $s$ with
the coefficient $\epsilon_1$, and $s_2$, with the coefficient
$\epsilon_1^{(2)}$. Moving the marking inside face $\Face_2$ we increase or
decrease $\epsilon_1$ by $1$ and do not change $\Tria_2^*$. So, in several
steps we can equalize $\epsilon_1$ and $\epsilon_1^{(2)}$. Take some points
$A_1$ and $A_2$ inside $\Face_1$ and $\Face_2$, respectively, and join them
by a segment (if $\Face_1 = \emptyset$ then take $A_1 \in e_1$). Then
choose some edge $e_2$ separating $\Face_2$ and $\Face_3$, equalize
coefficients $\epsilon_2$ and $\epsilon_2^{(2)}$ by moving the marking in
the face $\Face_3$, draw segment $A_2A_3$, etc. The process stops in two
cases: either the edge $e_N$ to be processed lies in $\partial G$ (and so,
$\Face_{N+1} = \emptyset$), or $\Face_{N+1}$ has a common edge with some
face $\Face_k$ processed earlier. In both cases we cannot process $e_N$ (in
the second case moving the markings inside $\Face_{N+1}$ spoils the results
of previous efforts). We will show, though, that it is not necessary to
process $e_N$.

To prove this take in the first case $A_{N+1} \in \gamma_N$ and draw the
segment $A_NA_{N+1}$. In the second case take $A_{N+1}$ inside
$\Face_{N+1}$ and draw $A_NA_{N+1}A_k$. So we have the line $\gamma =
A_1A_2\dots A_{N+1}$ which is either closed or has its endpoints on
$\partial G$. Thus, $\gamma$ represents a cycle from $\Cycle_1(G \setminus
V, \partial G; \Integer)$, and we can use (\ref{Eq:InterInd}) to get:
%*
\begin{displaymath}
\epsilon_{N+1} - \epsilon_{N+1}^{(2)} = \langle \gamma,e_{N+1}\rangle =
n_{\widetilde{\Tria_2}}(\gamma) - n_{\Tria_2}(\gamma) = 0.
\end{displaymath}
%*
Thus, processing the edge $e_{N+1}$ is unnecessary. If there are more edges
entering $s$ and $s_2$ with different coefficients, then repeat the process
starting from another initial edge.
\end{proof}

\section{Homotopy classification of 1-forms and
trivializations}\label{Sec:Forms}

\subsection{The invariant}\label{Subsec:FInv}
Recall that a connected oriented $2$-manifold $M$ is called {\em
topologically finite} if there exists a connected compact oriented surface
$G$ and a finite set of marked points $V \subset G$ such that $M$ is
diffeomorphic to $G \setminus V$. We will always suppose that $V \ne
\emptyset$ (and therefore $M$ is not compact). We will allow $M$ to have a
boundary. If $M$ is topologically finite, then the pair $(G,V)$ is defined
uniquely up to a homeomorphism.

Denote by $\Forms(M)$ the set of $1$-forms $\nu$ on $M$ having the following
properties:
\begin{enumerate}
\item\label{It:NonZero} $\nu(q) \ne 0 \, \forall q \in M$;
\item\label{It:NormBound} if $q \in \dM$ and $v \in T_q \dM \subset T_q M$,
then $\langle \nu(q),v\rangle = 0$.
\end{enumerate}

Since the $2$-manifold $M$ is oriented and not compact, its tangent bundle
$TM$ is trivial. The same is true for the tangent bundle $T\dM$. Denote by
$\Triv(M)$ the set of trivializations $\rho: TM \to M \times \Real^2$ which
agree with the chosen orientation of $M$ and trivialize at the same time
the bundle $T\dM$. The latter condition means that for any $q \in \dM\
\rho(T_q\dM) = \{q\} \times \ell$ where $\ell \subset \Real^2$ (``the
$x$-axis'') does not depend on $q$.

\begin{statement}\label{St:HomotEquiv}
The spaces $\Forms(M)$ and $\Triv(M)$ are homotopy equivalent (in their
compact-open topologies).
\end{statement}

\begin{proof}
Let $\nu \in \Forms(M)$. We can interpret the covector $\nu(q)$ as the
$y$-coordinate on the space $T_qM$. To fix the trivialization, i.e., the
mapping $T_qM \to \Real^2$, one should choose an $x$-coordinate. The
possible choices constitute a half-plane, and therefore $\Triv(M)$ is
fibered over $\Forms(M)$ with a contractible fiber.
\end{proof}

The space $\Forms(M)$ is not connected because there exist nontrivial
homotopy invariants of such forms. The first invariant is obvious: for $q
\in \partial M$ the covector $\nu(q)$ can look inside or outside $M$. Thus
$\nu$ defines an orientation of every connected component of $\dM$ (better
to say, a co-orientation, but it is just the same because we assume $M$
oriented). This set of orientations is, apparently, a homotopy invariant.

There exist more invariants. Let $g$ be a preimage of the standard
Riemannian metric $dx^2 + dy^2$ (on $\Real^2$) under a trivialization $\rho
\in \Triv(M)$. The form $\nu \in \Forms(M)$ that corresponds to $\rho$ (see
Statement \ref{St:HomotEquiv}) is identified by $g$ with a vector field
such that $\nu(q)$ has unit length and is directed along the $y$-axis. Take
a smooth curve $\gamma \subset M$ parametrized by $t \in [0,1]$. For any
$t$ consider two vectors from $T_{\gamma(t)}M$:  $a_t = \nu(\gamma(t))$ is
the unit vector directed along the $y$-axis, and $b_t$ is the tangent
vector to $\gamma$ (at $\gamma(t)$). Denote $\alpha_0$ the angle between
the vectors $a_0$ and $b_0$, and $\alpha_1$, the angle between the vectors
$a_1$ and $b_1$. Define the number
%*
\begin{displaymath}
m_\rho(\gamma) = 2 \times \mbox{\parbox[t]{10cm}{$(-\alpha_0 + \alpha_1 +$
the number of rotations that $b_t$ makes around $a_t$, as $t$ goes from $0$
to $1)$.}}
\end{displaymath}
%*

The functional $m_\rho$ can be extended by $\Integer$-linearity to a
$1$-cochain $m_\rho \in \Cycle^1(M, \dM; \Integer)$. Clearly, if $\gamma
\in \Cycle_1(M, \dM; \Integer)$, then $m_\rho(\gamma) \in \Integer$.

\begin{statement}\label{St:PropCochM}
If $\gamma \in \Cycle_1(M, \dM; \Integer)$, then $m_\rho(\gamma)$ does not
change under homotopies of $\rho$ and $\gamma$. The number $m_\rho(\gamma)$
is odd if and only if the curve $\gamma$ has endpoints $u_0 \in C_0$ and
$u_1 \in C_1$, and the co-orientations induced by $\rho$ on the connected
components $C_0, C_1 \subset \dM$ coincide. The differential $\Delta'
\bydef dm_\rho \in \Cycle^2(M, \dM; \Integer)$ does not depend on $\rho$.
\end{statement}

\begin{proof}
To prove the first assertion it is enough to check it for the case when
$\gamma$ is a smooth curve with endpoints in $\dM$. The integer
$m_\rho(\gamma)$ changes only if $\rho$ or $\gamma$ undergoes such a
homotopy that $b_0$ or $b_1$ pass through the $x$-axis. But this is
impossible if endpoints of $\gamma$ lie in $\dM$ due to the boundary
conditions for trivialization $\rho$. The second assertion is obvious.

\begin{figure}
\begin{center}
%\input elemch.pic
%TexCad Options
%\grade{\on}
%\emlines{\on}
%\beziermacro{\off}
%\reduce{\on}
%\snapping{\off}
%\quality{2.00}
%\graddiff{0.01}
%\snapasp{1}
%\zoom{1.00}
\special{em:linewidth 0.4pt}
\unitlength 1mm
\linethickness{0.4pt}
\begin{picture}(89.00,20.67)
\emline{42.67}{20.67}{1}{52.33}{20.67}{2}
\emline{35.33}{8.00}{3}{42.33}{2.67}{4}
\emline{60.67}{8.00}{5}{53.00}{2.67}{6}
%\bezier{80}(44.00,20.67)(43.33,8.67)(36.00,7.00)
\emline{44.00}{20.67}{7}{43.73}{17.83}{8}
\emline{43.73}{17.83}{9}{43.25}{15.31}{10}
\emline{43.25}{15.31}{11}{42.56}{13.12}{12}
\emline{42.56}{13.12}{13}{41.67}{11.25}{14}
\emline{41.67}{11.25}{15}{40.56}{9.70}{16}
\emline{40.56}{9.70}{17}{39.25}{8.48}{18}
\emline{39.25}{8.48}{19}{37.73}{7.58}{20}
\emline{37.73}{7.58}{21}{36.00}{7.00}{22}
%\end
%\bezier{60}(41.33,3.33)(48.33,7.33)(54.00,3.33)
\emline{41.33}{3.33}{23}{43.63}{4.44}{24}
\emline{43.63}{4.44}{25}{45.85}{5.11}{26}
\emline{45.85}{5.11}{27}{50.07}{5.11}{28}
\emline{50.07}{5.11}{29}{52.07}{4.44}{30}
\emline{52.07}{4.44}{31}{54.00}{3.33}{32}
%\end
%\bezier{72}(59.33,7.00)(51.33,11.33)(51.67,20.67)
\emline{59.33}{7.00}{33}{57.27}{8.30}{34}
\emline{57.27}{8.30}{35}{55.53}{9.79}{36}
\emline{55.53}{9.79}{37}{54.11}{11.48}{38}
\emline{54.11}{11.48}{39}{53.02}{13.36}{40}
\emline{53.02}{13.36}{41}{52.24}{15.43}{42}
\emline{52.24}{15.43}{43}{51.79}{17.69}{44}
\emline{51.79}{17.69}{45}{51.67}{20.67}{46}
%\end
\emline{47.00}{20.33}{47}{43.67}{17.33}{48}
\emline{49.33}{20.33}{49}{42.67}{14.67}{50}
\emline{51.67}{20.33}{51}{42.33}{12.67}{52}
\emline{51.33}{17.67}{53}{39.00}{8.00}{54}
\emline{52.33}{15.67}{55}{38.00}{5.67}{56}
\emline{52.33}{14.00}{57}{39.00}{4.67}{58}
\emline{53.00}{12.67}{59}{40.33}{4.00}{60}
\emline{54.00}{11.33}{61}{44.33}{5.33}{62}
\emline{54.67}{9.67}{63}{47.67}{5.33}{64}
\emline{56.00}{9.00}{65}{50.00}{5.00}{66}
\emline{57.67}{8.33}{67}{51.33}{4.33}{68}
\emline{78.33}{20.67}{69}{88.00}{20.67}{70}
\put(84.00,10.00){\circle{4.00}}
%\bezier{96}(79.33,20.67)(79.67,1.00)(84.00,2.67)
\emline{79.33}{20.67}{71}{79.45}{16.80}{72}
\emline{79.45}{16.80}{73}{79.65}{13.40}{74}
\emline{79.65}{13.40}{75}{79.93}{10.46}{76}
\emline{79.93}{10.46}{77}{80.31}{7.98}{78}
\emline{80.31}{7.98}{79}{80.77}{5.97}{80}
\emline{80.77}{5.97}{81}{81.31}{4.42}{82}
\emline{81.31}{4.42}{83}{81.95}{3.33}{84}
\emline{81.95}{3.33}{85}{82.67}{2.70}{86}
\emline{82.67}{2.70}{87}{84.00}{2.67}{88}
%\end
%\bezier{96}(87.67,20.67)(89.00,1.67)(83.67,2.67)
\emline{87.67}{20.67}{89}{87.87}{16.93}{90}
\emline{87.87}{16.93}{91}{87.93}{13.62}{92}
\emline{87.93}{13.62}{93}{87.85}{10.74}{94}
\emline{87.85}{10.74}{95}{87.62}{8.31}{96}
\emline{87.62}{8.31}{97}{87.25}{6.30}{98}
\emline{87.25}{6.30}{99}{86.73}{4.73}{100}
\emline{86.73}{4.73}{101}{86.07}{3.59}{102}
\emline{86.07}{3.59}{103}{85.26}{2.89}{104}
\emline{85.26}{2.89}{105}{83.67}{2.67}{106}
%\end
\emline{82.33}{20.67}{107}{80.00}{18.33}{108}
\emline{79.67}{16.33}{109}{84.00}{20.67}{110}
\emline{85.67}{20.67}{111}{79.67}{13.67}{112}
\emline{79.67}{12.00}{113}{87.33}{20.67}{114}
\emline{87.33}{18.33}{115}{79.33}{9.33}{116}
\emline{80.00}{8.00}{117}{82.00}{10.33}{118}
\emline{84.67}{12.33}{119}{87.67}{16.33}{120}
\emline{87.67}{14.33}{121}{85.33}{11.67}{122}
\emline{82.67}{8.67}{123}{81.00}{6.33}{124}
\emline{81.00}{4.67}{125}{83.67}{8.33}{126}
\emline{86.00}{10.67}{127}{88.00}{13.00}{128}
\emline{87.67}{11.00}{129}{81.67}{4.00}{130}
\emline{82.67}{3.00}{131}{87.67}{9.00}{132}
\emline{87.33}{6.33}{133}{84.33}{3.00}{134}
\end{picture}
\end{center}
\caption{``Elementary'' $2$-chains}\label{Fig:ElemCh}
\end{figure}

To prove that $dm_\rho$ does not depend on $\rho$ observe that for any
$2$-chain ${\cal G}$ there exist integers $k_1, \dots, k_n$ and
``elementary'' chains ${\cal H}_1, \dots, {\cal H}_n$ (whose possible
topological types are shown in Fig. \ref{Fig:ElemCh}) such that
%*
\begin{equation}\label{Eq:Decomp}
\partial ({\cal G} - k_1{\cal H}_1 - \dots - k_n{\cal H}_n) = 0.
\end{equation}
%*
For any elementary chain $dm_\rho({\cal H}_i) = m_\rho(\partial {\cal H}_i)
= 1$, and decomposition (\ref{Eq:Decomp}) does not depend on $\rho$.
Therefore $dm_\rho({\cal G}) = m_\rho(\partial {\cal G}) = \sum_i
m_\rho(\partial {\cal H}_i)$ does not depend on $\rho$ either.
\end{proof}

So, possible values of the cochain $m_\rho$ form a lattice $\widetilde L$.
The parity rule for $m_\rho(\gamma)$ allows to determine the co-orientation
induced by $\rho$ on all the connected components of $\dM$, if the
co-orientation of one of them is known (recall that $M$ is connected). Thus
in the case $\dM \ne \emptyset$ a connected component of the set $\Triv(M)$
(or $\Forms(M)$) can be characterized by two invariants: the cochain
$m_\rho \in \widetilde L$ and the co-orientation $\sigma \in \Integer_2$ of
the selected component of $\dM$. In the case $\dM = \emptyset$ the second
invariant does not exist. Thus, a connected component $\Conn_i$ of the set
$\Forms(M)$ (or $\Triv(M)$) corresponds to the point $\tau(\Conn_i)$ of
some lattice $L'$ isomorphic to $\widetilde L \times \Integer_2$ if $\dM
\ne \emptyset$, and to $\widetilde L$ if $\dM = \emptyset$.

\subsection{Completeness of the invariant}\label{Subsec:FComp}
The invariant $\tau$ describes the homotopy type of $\Forms(M)$ (and
$\Triv(M)$) completely:

\begin{theorem}\label{Th:HomTypeForm}
For any $\tau \in L'$ there is exactly one connected component $\Conn
\subset \Forms(M)$ such that $\tau = \tau(\Conn)$. The set $\Conn$ is
contractible.
\end{theorem}

To prove Theorem \ref{Th:HomTypeForm} we need two lemmas. Let $(G,V)$ be a
surface with the marked points such that $M = G \setminus V$. For every
marked point $v_i \in \partial G$ join two ``ends'' of connected components
of $\dM$ adjacent to $v_i$ by a smooth simple curve $\gamma_i$. For every
marked point $v_i \in \name{int}G$ draw a circumscribing closed curve
$\gamma_i$. The curves $\gamma_i$ will be referred to as {\em compactifying
curves}, because they bound the compact subset $\tM \subset M$. Restriction
map $\nu \mapsto \left.\nu\right|_\tM$ maps $\Forms(M)$ to some set $U
\subset \Omega^1(\tM)$.

\begin{lemma}\label{Lm:RestrHomEq}
The restriction map $\Forms(M) \to U$ is a homotopy equivalence.
\end{lemma}

\begin{proof}
Double a system of compactifying curves drawing for any such curve $\gamma$
a curve $\gamma'$ parallel to it and going inside $\tM$. These additional
curves bound a set $\tM' \subset \tM$. There exists a continuous family of
diffeomorphisms $D_t:M \to M$ such that $D_0 = \name{Id},\ \left.
D_t\right|_{\tM'} \equiv \name{Id}$, and $D_1(M) = \tM$.  Now if $\nu \in
\Forms(M)$, then $\nu_t \bydef D_t^*\nu$ is a continuous deformation within
$\Forms(M)$. But $\nu_1 = D_1^*\nu$ depends on $\left.  \nu\right|_\tM$
only. Thus, $D_1^*$ is a homotopy inverse to the restriction map.
\end{proof}

\begin{lemma}\label{Lm:SetsTriv}
The following sets of vector fields without zeros in $\Real^2$ are
contractible:
\begin{enumerate}
\item\label{It:TrivSegm} the set $P_n([0,1])$ of fields $X$ on the segment
$[0,1]$ of the $x$-axis such that $X(0) = X(1) = (1,0)$, and the total
rotation of $X$ on the segment is $n$;
\item\label{It:TrivCircle} the set $P_n(S^1)$ of fields $X$ on the unit
circle with the total rotation $n$;
\item\label{It:TrivDisk} the set $P_Y(D)$ of fields $X$ on the unit disk
$D$ such that $\left.X\right|_D = Y$ where $Y \in P_0(S^1)$ is the given
field on the unit circle;
\item\label{It:TrivAnn} the set $P_Y(A)$ of fields $X$ on the annulus $A$
such that on the outer boundary of $A$ the field $X = Y$ where $Y \in
P_n(S^1)$ is the given field on the unit circle;
\end{enumerate}
\end{lemma}

The proof is obvious.

{\def \proofName {Proof of Theorem \ref{Th:HomTypeForm}}
\begin{proof}
Draw a finite system $\cal A$ of simple smooth curves $\gamma \in
\Cycle_1(M,\dM;\Integer)$ cutting $\tM$ into parts whose topological types
are shown in Fig. \ref{Fig:ElemCh}. We include all the compactifying curves
into $\cal A$. Fix a $1$-cochain $m \in \widetilde L$ and an orientation
$\sigma$ of some connected component of $\dM$. Using assertions
\ref{It:TrivSegm} and \ref{It:TrivCircle} of Lemma \ref{Lm:SetsTriv}, we
show that there exists a $1$-form $\nu$ defined on all the curves $\gamma
\in \cal A$ except closed compactifying curves (that involve punctures $v_i
\in \name{int}G$) and such that $m_\nu = m$ and $\nu$ generates the
orientation $\sigma$. Moreover, the set of all such $1$-forms on $\cal A$
is contractible. Then, using assertions \ref{It:TrivDisk} and
\ref{It:TrivAnn} of Lemma \ref{Lm:SetsTriv}, we show that the form $\nu$ on
$\cal A$ can be extended to the form $\nu \in \Forms(M)$ in a homotopically
unique way.
\end{proof}
}

\section{The homotopy classification of functions}\label{Sec:Func}

\subsection{TMV associated with the functions}\label{Subsec:FTMV}

We suppose, as before, that the manifold $M$ is topologically finite, $M =
G \setminus V$. Take a compact subset $\tM \subset M$, like in Section
\ref{Sec:Forms}. It suffices to study the restrictions $\left.f\right|_\tM$
for $f \in \Func(M)$ because the restriction map is a homotopy equivalence
(the proof of this fact repeats the proof of Lemma \ref{Lm:RestrHomEq}).

\begin{figure}
\begin{center}
%\input crucial.pic
%TexCad Options
%\grade{\on}
%\emlines{\on}
%\beziermacro{\off}
%\reduce{\on}
%\snapping{\off}
%\quality{2.00}
%\graddiff{0.01}
%\snapasp{1}
%\zoom{1.00}
\special{em:linewidth 0.4pt}
\unitlength 1.00mm
\linethickness{0.4pt}
\begin{picture}(100.40,38.33)
\emline{32.67}{9.66}{1}{53.67}{9.66}{2}
%\bezier{228}(33.00,23.00)(44.67,-3.67)(51.00,23.00)
\emline{33.00}{23.00}{3}{34.09}{20.61}{4}
\emline{34.09}{20.61}{5}{35.15}{18.46}{6}
\emline{35.15}{18.46}{7}{36.19}{16.54}{8}
\emline{36.19}{16.54}{9}{37.20}{14.86}{10}
\emline{37.20}{14.86}{11}{38.19}{13.41}{12}
\emline{38.19}{13.41}{13}{39.16}{12.20}{14}
\emline{39.16}{12.20}{15}{40.11}{11.22}{16}
\emline{40.11}{11.22}{17}{41.03}{10.48}{18}
\emline{41.03}{10.48}{19}{41.92}{9.98}{20}
\emline{41.92}{9.98}{21}{42.80}{9.72}{22}
\emline{42.80}{9.72}{23}{43.65}{9.68}{24}
\emline{43.65}{9.68}{25}{44.47}{9.89}{26}
\emline{44.47}{9.89}{27}{45.27}{10.33}{28}
\emline{45.27}{10.33}{29}{46.05}{11.01}{30}
\emline{46.05}{11.01}{31}{46.81}{11.92}{32}
\emline{46.81}{11.92}{33}{47.54}{13.07}{34}
\emline{47.54}{13.07}{35}{48.25}{14.46}{36}
\emline{48.25}{14.46}{37}{48.93}{16.08}{38}
\emline{48.93}{16.08}{39}{49.59}{17.93}{40}
\emline{49.59}{17.93}{41}{50.23}{20.03}{42}
\emline{50.23}{20.03}{43}{51.00}{23.00}{44}
%\end
%\bezier{228}(32.67,27.66)(44.33,1.00)(50.67,27.66)
\emline{32.67}{27.66}{45}{33.76}{25.27}{46}
\emline{33.76}{25.27}{47}{34.82}{23.12}{48}
\emline{34.82}{23.12}{49}{35.85}{21.20}{50}
\emline{35.85}{21.20}{51}{36.87}{19.52}{52}
\emline{36.87}{19.52}{53}{37.86}{18.07}{54}
\emline{37.86}{18.07}{55}{38.83}{16.86}{56}
\emline{38.83}{16.86}{57}{39.77}{15.89}{58}
\emline{39.77}{15.89}{59}{40.69}{15.15}{60}
\emline{40.69}{15.15}{61}{41.59}{14.65}{62}
\emline{41.59}{14.65}{63}{42.46}{14.38}{64}
\emline{42.46}{14.38}{65}{43.31}{14.35}{66}
\emline{43.31}{14.35}{67}{44.14}{14.55}{68}
\emline{44.14}{14.55}{69}{44.94}{15.00}{70}
\emline{44.94}{15.00}{71}{45.72}{15.67}{72}
\emline{45.72}{15.67}{73}{46.47}{16.59}{74}
\emline{46.47}{16.59}{75}{47.21}{17.73}{76}
\emline{47.21}{17.73}{77}{47.92}{19.12}{78}
\emline{47.92}{19.12}{79}{48.60}{20.74}{80}
\emline{48.60}{20.74}{81}{49.26}{22.60}{82}
\emline{49.26}{22.60}{83}{49.90}{24.69}{84}
\emline{49.90}{24.69}{85}{50.67}{27.66}{86}
%\end
\emline{32.33}{31.00}{87}{32.33}{19.33}{88}
\emline{50.67}{31.66}{89}{50.67}{18.66}{90}
\emline{80.00}{22.66}{91}{94.33}{22.66}{92}
%\bezier{64}(82.33,26.00)(87.67,19.33)(91.67,26.00)
\emline{82.33}{26.00}{93}{83.97}{24.24}{94}
\emline{83.97}{24.24}{95}{85.54}{23.14}{96}
\emline{85.54}{23.14}{97}{87.04}{22.68}{98}
\emline{87.04}{22.68}{99}{88.48}{22.88}{100}
\emline{88.48}{22.88}{101}{89.86}{23.72}{102}
\emline{89.86}{23.72}{103}{91.67}{26.00}{104}
%\end
%\bezier{56}(76.00,22.33)(77.00,29.66)(82.00,26.00)
\emline{76.00}{22.33}{105}{76.48}{24.60}{106}
\emline{76.48}{24.60}{107}{77.22}{26.17}{108}
\emline{77.22}{26.17}{109}{78.22}{27.03}{110}
\emline{78.22}{27.03}{111}{79.47}{27.20}{112}
\emline{79.47}{27.20}{113}{82.00}{26.00}{114}
%\end
%\bezier{60}(97.67,22.33)(96.00,30.66)(91.67,25.33)
\emline{97.67}{22.33}{115}{97.04}{24.73}{116}
\emline{97.04}{24.73}{117}{96.26}{26.37}{118}
\emline{96.26}{26.37}{119}{95.34}{27.25}{120}
\emline{95.34}{27.25}{121}{94.26}{27.37}{122}
\emline{94.26}{27.37}{123}{93.04}{26.73}{124}
\emline{93.04}{26.73}{125}{91.67}{25.33}{126}
%\end
%\bezier{128}(76.00,22.00)(89.33,10.00)(97.33,22.00)
\emline{76.00}{22.00}{127}{78.05}{20.27}{128}
\emline{78.05}{20.27}{129}{80.04}{18.84}{130}
\emline{80.04}{18.84}{131}{81.96}{17.70}{132}
\emline{81.96}{17.70}{133}{83.81}{16.85}{134}
\emline{83.81}{16.85}{135}{85.60}{16.29}{136}
\emline{85.60}{16.29}{137}{87.33}{16.03}{138}
\emline{87.33}{16.03}{139}{88.99}{16.06}{140}
\emline{88.99}{16.06}{141}{90.58}{16.38}{142}
\emline{90.58}{16.38}{143}{92.11}{16.99}{144}
\emline{92.11}{16.99}{145}{93.57}{17.90}{146}
\emline{93.57}{17.90}{147}{94.97}{19.10}{148}
\emline{94.97}{19.10}{149}{97.33}{22.00}{150}
%\end
%\circle(87.33,21.00){26.14}
\emline{87.33}{34.07}{151}{90.00}{33.80}{152}
\emline{90.00}{33.80}{153}{92.56}{32.98}{154}
\emline{92.56}{32.98}{155}{94.90}{31.66}{156}
\emline{94.90}{31.66}{157}{96.91}{29.89}{158}
\emline{96.91}{29.89}{159}{98.53}{27.74}{160}
\emline{98.53}{27.74}{161}{99.67}{25.31}{162}
\emline{99.67}{25.31}{163}{100.29}{22.70}{164}
\emline{100.29}{22.70}{165}{100.36}{20.02}{166}
\emline{100.36}{20.02}{167}{99.89}{17.38}{168}
\emline{99.89}{17.38}{169}{98.88}{14.89}{170}
\emline{98.88}{14.89}{171}{97.39}{12.66}{172}
\emline{97.39}{12.66}{173}{95.47}{10.78}{174}
\emline{95.47}{10.78}{175}{93.21}{9.33}{176}
\emline{93.21}{9.33}{177}{90.70}{8.38}{178}
\emline{90.70}{8.38}{179}{88.05}{7.95}{180}
\emline{88.05}{7.95}{181}{85.37}{8.08}{182}
\emline{85.37}{8.08}{183}{82.77}{8.76}{184}
\emline{82.77}{8.76}{185}{80.36}{9.95}{186}
\emline{80.36}{9.95}{187}{78.25}{11.60}{188}
\emline{78.25}{11.60}{189}{76.52}{13.66}{190}
\emline{76.52}{13.66}{191}{75.25}{16.02}{192}
\emline{75.25}{16.02}{193}{74.48}{18.59}{194}
\emline{74.48}{18.59}{195}{74.26}{21.27}{196}
\emline{74.26}{21.27}{197}{74.59}{23.93}{198}
\emline{74.59}{23.93}{199}{75.46}{26.47}{200}
\emline{75.46}{26.47}{201}{76.83}{28.78}{202}
\emline{76.83}{28.78}{203}{78.64}{30.77}{204}
\emline{78.64}{30.77}{205}{80.82}{32.34}{206}
\emline{80.82}{32.34}{207}{83.27}{33.43}{208}
\emline{83.27}{33.43}{209}{87.33}{34.07}{210}
%\end
\put(67.00,4.00){\makebox(0,0)[cc]{crucial lines}}
\put(66.33,38.33){\makebox(0,0)[cc]{concomitant lines}}
%\vector(63.67,8.33)(48.67,12.33)
\put(48.67,12.33){\vector(-4,1){0.2}}
\emline{63.67}{8.33}{211}{48.67}{12.33}{212}
%\end
%\vector(69.67,8.33)(81.00,17.00)
\put(81.00,17.00){\vector(4,3){0.2}}
\emline{69.67}{8.33}{213}{81.00}{17.00}{214}
%\end
%\vector(66.00,33.00)(46.67,16.67)
\put(46.67,16.67){\vector(-4,-3){0.2}}
\emline{66.00}{33.00}{215}{46.67}{16.67}{216}
%\end
%\vector(68.67,32.33)(76.67,30.67)
\put(76.67,30.67){\vector(4,-1){0.2}}
\emline{68.67}{32.33}{217}{76.67}{30.67}{218}
%\end
%\vector(76.67,30.67)(76.67,30.67)
\put(76.67,30.67){\vector(0,1){0.2}}
\emline{76.67}{30.67}{219}{76.67}{30.67}{220}
%\end
\end{picture}
\end{center}
\caption{Crucial and concomitant lines}\label{Fig:Crucial}
\end{figure}

Take a function $f \in M$ and consider level lines of the restriction
$\left.f\right|_\tM$, i.e., connected components of the sets $F_a = \{q \in
\tM: f(q) = a\}$. Call such a line {\em crucial} if it contains more than
one point, does not belong to $\dM$ and touches a compactifying curve. If a
level line $\ell_a \subset \tM$ (of the level $f(q) = a$) is not crucial,
then the level lines close to $\ell_a$ are isotopic to $\ell_a$, in the
obvious sense. For a generic $f \in \Func(M)$ all its crucial lines touch
compactifying curves in a nondegenerate way and in exactly one point.
Typical crucial line and the neighboring level line are shown in Fig.
\ref{Fig:Crucial}. The neighboring line isotopic to the crucial line
$\ell_a$ will be called a {\em concomitant} line. From now on we will
always suppose that the function $f \in \Func(M)$ is generic.

\begin{figure}
\begin{center}
%\input ctmv.pic
%TexCad Options
%\grade{\on}
%\emlines{\on}
%\beziermacro{\off}
%\reduce{\on}
%\snapping{\off}
%\quality{2.00}
%\graddiff{0.01}
%\snapasp{1}
%\zoom{1.00}
\special{em:linewidth 0.4pt}
\unitlength 1.00mm
\linethickness{0.4pt}
\begin{picture}(111.33,36.33)
%\bezier{112}(25.33,30.33)(37.00,25.33)(51.67,30.67)
\emline{25.33}{30.33}{1}{27.44}{29.52}{2}
\emline{27.44}{29.52}{3}{29.60}{28.87}{4}
\emline{29.60}{28.87}{5}{31.80}{28.39}{6}
\emline{31.80}{28.39}{7}{34.05}{28.08}{8}
\emline{34.05}{28.08}{9}{36.35}{27.93}{10}
\emline{36.35}{27.93}{11}{38.70}{27.94}{12}
\emline{38.70}{27.94}{13}{41.09}{28.12}{14}
\emline{41.09}{28.12}{15}{43.54}{28.46}{16}
\emline{43.54}{28.46}{17}{46.03}{28.97}{18}
\emline{46.03}{28.97}{19}{48.56}{29.64}{20}
\emline{48.56}{29.64}{21}{51.67}{30.67}{22}
%\end
%\bezier{116}(25.00,2.00)(38.33,7.00)(52.00,2.33)
\emline{25.00}{2.00}{23}{27.30}{2.79}{24}
\emline{27.30}{2.79}{25}{29.61}{3.44}{26}
\emline{29.61}{3.44}{27}{31.92}{3.94}{28}
\emline{31.92}{3.94}{29}{34.24}{4.30}{30}
\emline{34.24}{4.30}{31}{36.56}{4.51}{32}
\emline{36.56}{4.51}{33}{41.22}{4.51}{34}
\emline{41.22}{4.51}{35}{43.55}{4.30}{36}
\emline{43.55}{4.30}{37}{45.89}{3.94}{38}
\emline{45.89}{3.94}{39}{48.24}{3.43}{40}
\emline{48.24}{3.43}{41}{52.00}{2.33}{42}
%\end
%\bezier{56}(11.67,22.67)(15.67,17.67)(11.67,11.00)
\emline{11.67}{22.67}{43}{12.85}{20.83}{44}
\emline{12.85}{20.83}{45}{13.51}{18.89}{46}
\emline{13.51}{18.89}{47}{13.66}{16.83}{48}
\emline{13.66}{16.83}{49}{13.31}{14.68}{50}
\emline{13.31}{14.68}{51}{11.67}{11.00}{52}
%\end
%\bezier{56}(66.00,23.00)(61.67,18.00)(65.67,11.67)
\emline{66.00}{23.00}{53}{64.72}{21.17}{54}
\emline{64.72}{21.17}{55}{63.97}{19.26}{56}
\emline{63.97}{19.26}{57}{63.75}{17.26}{58}
\emline{63.75}{17.26}{59}{64.07}{15.18}{60}
\emline{64.07}{15.18}{61}{65.67}{11.67}{62}
%\end
\emline{45.00}{28.67}{63}{64.33}{21.67}{64}
\emline{43.00}{4.33}{65}{64.33}{13.33}{66}
\emline{13.33}{12.67}{67}{28.67}{4.00}{68}
\emline{13.00}{21.00}{69}{31.00}{28.33}{70}
\put(57.67,17.67){\circle{3.40}}
%\bezier{344}(22.00,24.67)(68.67,36.00)(45.00,6.00)
\emline{22.00}{24.67}{71}{25.47}{25.48}{72}
\emline{25.47}{25.48}{73}{28.73}{26.16}{74}
\emline{28.73}{26.16}{75}{31.78}{26.73}{76}
\emline{31.78}{26.73}{77}{34.63}{27.17}{78}
\emline{34.63}{27.17}{79}{37.28}{27.49}{80}
\emline{37.28}{27.49}{81}{39.71}{27.69}{82}
\emline{39.71}{27.69}{83}{41.95}{27.77}{84}
\emline{41.95}{27.77}{85}{43.97}{27.73}{86}
\emline{43.97}{27.73}{87}{45.79}{27.57}{88}
\emline{45.79}{27.57}{89}{47.41}{27.29}{90}
\emline{47.41}{27.29}{91}{48.82}{26.89}{92}
\emline{48.82}{26.89}{93}{50.02}{26.37}{94}
\emline{50.02}{26.37}{95}{51.02}{25.72}{96}
\emline{51.02}{25.72}{97}{51.81}{24.96}{98}
\emline{51.81}{24.96}{99}{52.40}{24.07}{100}
\emline{52.40}{24.07}{101}{52.78}{23.06}{102}
\emline{52.78}{23.06}{103}{52.96}{21.94}{104}
\emline{52.96}{21.94}{105}{52.93}{20.69}{106}
\emline{52.93}{20.69}{107}{52.69}{19.32}{108}
\emline{52.69}{19.32}{109}{52.25}{17.83}{110}
\emline{52.25}{17.83}{111}{51.60}{16.22}{112}
\emline{51.60}{16.22}{113}{50.75}{14.49}{114}
\emline{50.75}{14.49}{115}{49.69}{12.63}{116}
\emline{49.69}{12.63}{117}{48.42}{10.66}{118}
\emline{48.42}{10.66}{119}{46.95}{8.57}{120}
\emline{46.95}{8.57}{121}{45.00}{6.00}{122}
%\end
%\bezier{220}(21.67,24.00)(13.67,1.33)(44.33,5.00)
\emline{21.67}{24.00}{123}{21.00}{21.89}{124}
\emline{21.00}{21.89}{125}{20.50}{19.90}{126}
\emline{20.50}{19.90}{127}{20.17}{18.03}{128}
\emline{20.17}{18.03}{129}{20.03}{16.28}{130}
\emline{20.03}{16.28}{131}{20.06}{14.65}{132}
\emline{20.06}{14.65}{133}{20.27}{13.15}{134}
\emline{20.27}{13.15}{135}{20.65}{11.76}{136}
\emline{20.65}{11.76}{137}{21.22}{10.50}{138}
\emline{21.22}{10.50}{139}{21.96}{9.35}{140}
\emline{21.96}{9.35}{141}{22.88}{8.33}{142}
\emline{22.88}{8.33}{143}{23.97}{7.43}{144}
\emline{23.97}{7.43}{145}{25.25}{6.64}{146}
\emline{25.25}{6.64}{147}{26.70}{5.98}{148}
\emline{26.70}{5.98}{149}{28.32}{5.44}{150}
\emline{28.32}{5.44}{151}{30.13}{5.02}{152}
\emline{30.13}{5.02}{153}{32.11}{4.72}{154}
\emline{32.11}{4.72}{155}{34.27}{4.55}{156}
\emline{34.27}{4.55}{157}{39.12}{4.55}{158}
\emline{39.12}{4.55}{159}{41.81}{4.74}{160}
\emline{41.81}{4.74}{161}{44.33}{5.00}{162}
%\end
%\bezier{188}(14.00,21.33)(19.00,-1.00)(18.67,23.00)
\emline{14.00}{21.33}{163}{14.52}{19.09}{164}
\emline{14.52}{19.09}{165}{15.01}{17.10}{166}
\emline{15.01}{17.10}{167}{15.46}{15.38}{168}
\emline{15.46}{15.38}{169}{15.89}{13.93}{170}
\emline{15.89}{13.93}{171}{16.29}{12.73}{172}
\emline{16.29}{12.73}{173}{16.65}{11.80}{174}
\emline{16.65}{11.80}{175}{16.99}{11.12}{176}
\emline{16.99}{11.12}{177}{17.29}{10.72}{178}
\emline{17.29}{10.72}{179}{17.57}{10.57}{180}
\emline{17.57}{10.57}{181}{17.81}{10.68}{182}
\emline{17.81}{10.68}{183}{18.03}{11.06}{184}
\emline{18.03}{11.06}{185}{18.21}{11.70}{186}
\emline{18.21}{11.70}{187}{18.37}{12.60}{188}
\emline{18.37}{12.60}{189}{18.49}{13.76}{190}
\emline{18.49}{13.76}{191}{18.59}{15.19}{192}
\emline{18.59}{15.19}{193}{18.65}{16.88}{194}
\emline{18.65}{16.88}{195}{18.69}{18.83}{196}
\emline{18.69}{18.83}{197}{18.67}{23.00}{198}
%\end
\emline{66.33}{17.00}{199}{68.33}{19.33}{200}
\emline{68.33}{19.33}{201}{68.67}{18.00}{202}
\emline{68.67}{18.00}{203}{72.33}{18.00}{204}
\emline{72.33}{18.00}{205}{72.33}{19.33}{206}
\emline{72.33}{19.33}{207}{74.67}{17.33}{208}
\emline{74.67}{17.33}{209}{72.33}{16.00}{210}
\emline{72.33}{16.00}{211}{72.33}{17.00}{212}
\emline{72.33}{17.00}{213}{68.67}{17.00}{214}
\emline{68.67}{17.00}{215}{68.67}{16.00}{216}
\emline{68.67}{16.00}{217}{67.00}{17.33}{218}
\emline{83.66}{29.00}{219}{111.00}{29.00}{220}
\emline{111.00}{29.00}{221}{111.00}{4.00}{222}
\emline{111.00}{4.00}{223}{83.66}{4.00}{224}
\put(106.00,19.00){\circle{3.40}}
\emline{83.66}{29.00}{225}{110.33}{4.00}{226}
%\bezier{184}(111.00,4.00)(93.66,26.00)(111.00,29.00)
\emline{111.00}{4.00}{227}{109.22}{6.33}{228}
\emline{109.22}{6.33}{229}{107.64}{8.55}{230}
\emline{107.64}{8.55}{231}{106.27}{10.67}{232}
\emline{106.27}{10.67}{233}{105.10}{12.66}{234}
\emline{105.10}{12.66}{235}{104.14}{14.55}{236}
\emline{104.14}{14.55}{237}{103.38}{16.32}{238}
\emline{103.38}{16.32}{239}{102.83}{17.99}{240}
\emline{102.83}{17.99}{241}{102.48}{19.54}{242}
\emline{102.48}{19.54}{243}{102.34}{20.97}{244}
\emline{102.34}{20.97}{245}{102.40}{22.30}{246}
\emline{102.40}{22.30}{247}{102.67}{23.51}{248}
\emline{102.67}{23.51}{249}{103.14}{24.61}{250}
\emline{103.14}{24.61}{251}{103.81}{25.60}{252}
\emline{103.81}{25.60}{253}{104.69}{26.48}{254}
\emline{104.69}{26.48}{255}{105.78}{27.24}{256}
\emline{105.78}{27.24}{257}{107.07}{27.89}{258}
\emline{107.07}{27.89}{259}{108.57}{28.43}{260}
\emline{108.57}{28.43}{261}{111.00}{29.00}{262}
%\end
\emline{22.00}{25.33}{263}{40.33}{5.00}{264}
\emline{55.67}{19.67}{265}{59.67}{19.67}{266}
%\bezier{28}(55.67,19.67)(53.33,19.67)(55.00,15.33)
\emline{55.67}{19.67}{267}{54.51}{19.11}{268}
\emline{54.51}{19.11}{269}{55.00}{15.33}{270}
%\end
%\bezier{28}(60.00,19.67)(62.33,19.67)(60.67,15.67)
\emline{60.00}{19.67}{271}{61.16}{19.16}{272}
\emline{61.16}{19.16}{273}{60.67}{15.67}{274}
%\end
%\bezier{88}(54.67,15.67)(60.33,5.67)(61.00,15.67)
\emline{54.67}{15.67}{275}{55.89}{13.65}{276}
\emline{55.89}{13.65}{277}{56.98}{12.15}{278}
\emline{56.98}{12.15}{279}{57.95}{11.17}{280}
\emline{57.95}{11.17}{281}{58.79}{10.71}{282}
\emline{58.79}{10.71}{283}{59.49}{10.76}{284}
\emline{59.49}{10.76}{285}{60.07}{11.33}{286}
\emline{60.07}{11.33}{287}{60.52}{12.41}{288}
\emline{60.52}{12.41}{289}{61.00}{15.67}{290}
%\end
%\bezier{208}(51.00,8.00)(56.00,36.33)(63.67,14.00)
\emline{51.00}{8.00}{291}{51.50}{10.67}{292}
\emline{51.50}{10.67}{293}{52.01}{13.09}{294}
\emline{52.01}{13.09}{295}{52.54}{15.27}{296}
\emline{52.54}{15.27}{297}{53.07}{17.20}{298}
\emline{53.07}{17.20}{299}{53.63}{18.88}{300}
\emline{53.63}{18.88}{301}{54.19}{20.32}{302}
\emline{54.19}{20.32}{303}{54.77}{21.52}{304}
\emline{54.77}{21.52}{305}{55.36}{22.46}{306}
\emline{55.36}{22.46}{307}{55.96}{23.16}{308}
\emline{55.96}{23.16}{309}{56.57}{23.62}{310}
\emline{56.57}{23.62}{311}{57.20}{23.83}{312}
\emline{57.20}{23.83}{313}{57.84}{23.79}{314}
\emline{57.84}{23.79}{315}{58.50}{23.51}{316}
\emline{58.50}{23.51}{317}{59.17}{22.98}{318}
\emline{59.17}{22.98}{319}{59.85}{22.21}{320}
\emline{59.85}{22.21}{321}{60.54}{21.19}{322}
\emline{60.54}{21.19}{323}{61.25}{19.92}{324}
\emline{61.25}{19.92}{325}{61.96}{18.41}{326}
\emline{61.96}{18.41}{327}{62.70}{16.65}{328}
\emline{62.70}{16.65}{329}{63.67}{14.00}{330}
%\end
\emline{53.67}{9.00}{331}{53.67}{16.00}{332}
%\bezier{36}(53.67,16.00)(54.00,22.00)(57.33,21.33)
\emline{53.67}{16.00}{333}{54.08}{18.82}{334}
\emline{54.08}{18.82}{335}{54.96}{20.61}{336}
\emline{54.96}{20.61}{337}{57.33}{21.33}{338}
%\end
%\bezier{48}(56.33,21.33)(59.67,23.33)(62.00,16.00)
\emline{56.33}{21.33}{339}{57.68}{21.76}{340}
\emline{57.68}{21.76}{341}{58.94}{21.38}{342}
\emline{58.94}{21.38}{343}{60.11}{20.19}{344}
\emline{60.11}{20.19}{345}{62.00}{16.00}{346}
%\end
\emline{62.00}{16.67}{347}{62.00}{12.00}{348}
%\bezier{120}(111.00,5.00)(98.67,22.67)(106.67,22.67)
\emline{111.00}{5.00}{349}{109.09}{7.82}{350}
\emline{109.09}{7.82}{351}{107.45}{10.40}{352}
\emline{107.45}{10.40}{353}{106.10}{12.73}{354}
\emline{106.10}{12.73}{355}{105.04}{14.81}{356}
\emline{105.04}{14.81}{357}{104.25}{16.66}{358}
\emline{104.25}{16.66}{359}{103.75}{18.25}{360}
\emline{103.75}{18.25}{361}{103.53}{19.60}{362}
\emline{103.53}{19.60}{363}{103.59}{20.70}{364}
\emline{103.59}{20.70}{365}{103.94}{21.56}{366}
\emline{103.94}{21.56}{367}{104.56}{22.18}{368}
\emline{104.56}{22.18}{369}{105.47}{22.54}{370}
\emline{105.47}{22.54}{371}{106.67}{22.67}{372}
%\end
%\bezier{96}(111.33,4.67)(110.00,24.33)(106.33,22.67)
\emline{111.33}{4.67}{373}{111.03}{8.53}{374}
\emline{111.03}{8.53}{375}{110.68}{11.94}{376}
\emline{110.68}{11.94}{377}{110.27}{14.88}{378}
\emline{110.27}{14.88}{379}{109.82}{17.35}{380}
\emline{109.82}{17.35}{381}{109.31}{19.37}{382}
\emline{109.31}{19.37}{383}{108.76}{20.92}{384}
\emline{108.76}{20.92}{385}{108.15}{22.00}{386}
\emline{108.15}{22.00}{387}{107.49}{22.63}{388}
\emline{107.49}{22.63}{389}{106.33}{22.67}{390}
%\end
%\bezier{132}(84.33,28.67)(73.33,18.33)(83.67,4.00)
\emline{84.33}{28.67}{391}{82.79}{27.08}{392}
\emline{82.79}{27.08}{393}{81.49}{25.44}{394}
\emline{81.49}{25.44}{395}{80.44}{23.76}{396}
\emline{80.44}{23.76}{397}{79.63}{22.04}{398}
\emline{79.63}{22.04}{399}{79.06}{20.26}{400}
\emline{79.06}{20.26}{401}{78.74}{18.45}{402}
\emline{78.74}{18.45}{403}{78.67}{16.58}{404}
\emline{78.67}{16.58}{405}{78.84}{14.67}{406}
\emline{78.84}{14.67}{407}{79.25}{12.72}{408}
\emline{79.25}{12.72}{409}{79.91}{10.71}{410}
\emline{79.91}{10.71}{411}{80.81}{8.67}{412}
\emline{80.81}{8.67}{413}{81.96}{6.57}{414}
\emline{81.96}{6.57}{415}{83.67}{4.00}{416}
%\end
\put(82.00,9.67){\makebox(0,0)[cc]{$*$}}
\emline{84.00}{29.00}{417}{84.00}{4.00}{418}
\put(86.67,7.00){\makebox(0,0)[cc]{$*$}}
\put(101.67,27.00){\makebox(0,0)[cc]{$*$}}
\put(109.33,25.67){\makebox(0,0)[cc]{$*$}}
\put(14.67,13.33){\makebox(0,0)[cc]{{\small R}}}
\put(19.67,11.00){\makebox(0,0)[cc]{{\small R}}}
\put(49.00,9.00){\makebox(0,0)[cc]{{\small R}}}
\put(62.67,20.33){\makebox(0,0)[cc]{{\small R}}}
\put(16.33,22.33){\circle*{1.33}}
\put(16.00,24.00){\makebox(0,0)[rc]{{\small point-line}}}
\end{picture}
\end{center}
\caption{Construction of $\Tria(f)$}\label{Fig:ConstrTMV}
\end{figure}

Choose a concomitant line $\widetilde{\ell}$ for every crucial line $\ell$
of $f$, following such rules: if two crucial lines, $\ell_1$ and $\ell_2$,
have parallel concomitant lines, then take $\widetilde{\ell_1} =
\widetilde{\ell_2}$. If a crucial line $\ell$ embraces a domain adjacent to
the boundary $\dM$ and not containing other crucial lines, then let
$\widetilde{\ell}$ be a point (see Fig. \ref{Fig:ConstrTMV}). For any
crucial line $\ell_i$ denote by $F_i \subset \tM$ the domain bounded by
$\ell_i$ and $\widetilde{\ell_i}$.

Consider now the mapping $\Map:\tM \to G$ which acts as follows:
\begin{itemize}
\item contracts every compactifying curve $\gamma_i$ into the corresponding
marked point $v_i \in V$;
\item acts diffeomorphically on the interiors of all the $F_i$;
\item contracts every domain $R \subset \tM \setminus \bigcup_i F_i$ (see
Fig. \ref{Fig:ConstrTMV}) into a line.
\end{itemize}

\begin{figure}
\begin{center}
%\input charmap.pic
%TexCad Options
%\grade{\on}
%\emlines{\on}
%\beziermacro{\off}
%\reduce{\on}
%\snapping{\off}
%\quality{2.00}
%\graddiff{0.01}
%\snapasp{1}
%\zoom{1.00}
\special{em:linewidth 0.4pt}
\unitlength 1mm
\linethickness{0.4pt}
\begin{picture}(80.67,25.34)
\emline{14.67}{2.67}{1}{36.00}{2.67}{2}
\emline{36.00}{2.67}{3}{24.67}{21.00}{4}
\emline{24.67}{21.00}{5}{15.00}{2.33}{6}
\put(24.67,17.67){\makebox(0,0)[cc]{$*$}}
%\bezier{180}(15.33,2.67)(24.67,22.67)(35.67,2.67)
\emline{15.33}{2.67}{7}{16.38}{4.77}{8}
\emline{16.38}{4.77}{9}{17.43}{6.62}{10}
\emline{17.43}{6.62}{11}{18.49}{8.22}{12}
\emline{18.49}{8.22}{13}{19.56}{9.58}{14}
\emline{19.56}{9.58}{15}{20.65}{10.69}{16}
\emline{20.65}{10.69}{17}{21.74}{11.56}{18}
\emline{21.74}{11.56}{19}{22.84}{12.17}{20}
\emline{22.84}{12.17}{21}{23.96}{12.54}{22}
\emline{23.96}{12.54}{23}{26.22}{12.54}{24}
\emline{26.22}{12.54}{25}{27.36}{12.17}{26}
\emline{27.36}{12.17}{27}{28.52}{11.56}{28}
\emline{28.52}{11.56}{29}{29.68}{10.69}{30}
\emline{29.68}{10.69}{31}{30.86}{9.58}{32}
\emline{30.86}{9.58}{33}{32.05}{8.22}{34}
\emline{32.05}{8.22}{35}{33.24}{6.62}{36}
\emline{33.24}{6.62}{37}{34.45}{4.77}{38}
\emline{34.45}{4.77}{39}{35.67}{2.67}{40}
%\end
%\bezier{120}(15.33,2.67)(24.67,14.00)(35.67,2.67)
\emline{15.33}{2.67}{41}{16.90}{4.40}{42}
\emline{16.90}{4.40}{43}{18.49}{5.81}{44}
\emline{18.49}{5.81}{45}{20.10}{6.92}{46}
\emline{20.10}{6.92}{47}{21.74}{7.70}{48}
\emline{21.74}{7.70}{49}{23.40}{8.18}{50}
\emline{23.40}{8.18}{51}{26.79}{8.18}{52}
\emline{26.79}{8.18}{53}{28.52}{7.70}{54}
\emline{28.52}{7.70}{55}{30.27}{6.92}{56}
\emline{30.27}{6.92}{57}{32.05}{5.81}{58}
\emline{32.05}{5.81}{59}{33.84}{4.40}{60}
\emline{33.84}{4.40}{61}{35.67}{2.67}{62}
%\end
%\bezier{84}(15.33,2.67)(25.00,7.33)(34.67,2.67)
\emline{15.33}{2.67}{63}{17.63}{3.65}{64}
\emline{17.63}{3.65}{65}{19.94}{4.36}{66}
\emline{19.94}{4.36}{67}{22.24}{4.81}{68}
\emline{22.24}{4.81}{69}{24.54}{4.99}{70}
\emline{24.54}{4.99}{71}{26.84}{4.92}{72}
\emline{26.84}{4.92}{73}{29.14}{4.57}{74}
\emline{29.14}{4.57}{75}{31.44}{3.96}{76}
\emline{31.44}{3.96}{77}{34.67}{2.67}{78}
%\end
%\circle(69.33,14.00){22.68}
\emline{69.33}{25.34}{79}{71.72}{25.08}{80}
\emline{71.72}{25.08}{81}{73.99}{24.34}{82}
\emline{73.99}{24.34}{83}{76.06}{23.13}{84}
\emline{76.06}{23.13}{85}{77.83}{21.51}{86}
\emline{77.83}{21.51}{87}{79.22}{19.55}{88}
\emline{79.22}{19.55}{89}{80.16}{17.35}{90}
\emline{80.16}{17.35}{91}{80.63}{15.00}{92}
\emline{80.63}{15.00}{93}{80.59}{12.60}{94}
\emline{80.59}{12.60}{95}{80.04}{10.27}{96}
\emline{80.04}{10.27}{97}{79.02}{8.10}{98}
\emline{79.02}{8.10}{99}{77.56}{6.20}{100}
\emline{77.56}{6.20}{101}{75.74}{4.64}{102}
\emline{75.74}{4.64}{103}{73.63}{3.51}{104}
\emline{73.63}{3.51}{105}{71.33}{2.84}{106}
\emline{71.33}{2.84}{107}{68.94}{2.67}{108}
\emline{68.94}{2.67}{109}{66.56}{3.01}{110}
\emline{66.56}{3.01}{111}{64.31}{3.83}{112}
\emline{64.31}{3.83}{113}{62.29}{5.12}{114}
\emline{62.29}{5.12}{115}{60.58}{6.79}{116}
\emline{60.58}{6.79}{117}{59.26}{8.80}{118}
\emline{59.26}{8.80}{119}{58.39}{11.03}{120}
\emline{58.39}{11.03}{121}{58.01}{13.40}{122}
\emline{58.01}{13.40}{123}{58.14}{15.79}{124}
\emline{58.14}{15.79}{125}{58.76}{18.10}{126}
\emline{58.76}{18.10}{127}{59.86}{20.23}{128}
\emline{59.86}{20.23}{129}{61.38}{22.08}{130}
\emline{61.38}{22.08}{131}{63.26}{23.57}{132}
\emline{63.26}{23.57}{133}{65.41}{24.64}{134}
\emline{65.41}{24.64}{135}{69.33}{25.34}{136}
%\end
%\circle(69.33,13.33){16.79}
\emline{69.33}{21.73}{137}{71.19}{21.52}{138}
\emline{71.19}{21.52}{139}{72.95}{20.91}{140}
\emline{72.95}{20.91}{141}{74.54}{19.92}{142}
\emline{74.54}{19.92}{143}{75.86}{18.61}{144}
\emline{75.86}{18.61}{145}{76.87}{17.03}{146}
\emline{76.87}{17.03}{147}{77.50}{15.28}{148}
\emline{77.50}{15.28}{149}{77.73}{13.43}{150}
\emline{77.73}{13.43}{151}{77.54}{11.57}{152}
\emline{77.54}{11.57}{153}{76.95}{9.80}{154}
\emline{76.95}{9.80}{155}{75.98}{8.20}{156}
\emline{75.98}{8.20}{157}{74.68}{6.86}{158}
\emline{74.68}{6.86}{159}{73.12}{5.84}{160}
\emline{73.12}{5.84}{161}{71.37}{5.19}{162}
\emline{71.37}{5.19}{163}{69.52}{4.94}{164}
\emline{69.52}{4.94}{165}{67.66}{5.11}{166}
\emline{67.66}{5.11}{167}{65.88}{5.68}{168}
\emline{65.88}{5.68}{169}{64.28}{6.63}{170}
\emline{64.28}{6.63}{171}{62.92}{7.92}{172}
\emline{62.92}{7.92}{173}{61.88}{9.47}{174}
\emline{61.88}{9.47}{175}{61.21}{11.21}{176}
\emline{61.21}{11.21}{177}{60.94}{13.06}{178}
\emline{60.94}{13.06}{179}{61.09}{14.92}{180}
\emline{61.09}{14.92}{181}{61.65}{16.70}{182}
\emline{61.65}{16.70}{183}{62.58}{18.32}{184}
\emline{62.58}{18.32}{185}{63.85}{19.69}{186}
\emline{63.85}{19.69}{187}{65.39}{20.74}{188}
\emline{65.39}{20.74}{189}{67.12}{21.43}{190}
\emline{67.12}{21.43}{191}{69.33}{21.73}{192}
%\end
\put(69.67,12.67){\circle{10.00}}
\put(69.67,12.00){\circle*{4.00}}
\put(70.00,2.67){\circle*{1.33}}
\put(25.00,20.33){\circle*{1.33}}
\put(15.33,3.00){\circle*{1.33}}
\put(35.67,2.67){\circle*{1.33}}
\end{picture}
\end{center}
\caption{Characteristic mapping}\label{Fig:CharMap}
\end{figure}

The surface $G$ is covered by the images $\Face_i = \Map(F_i)$ having no
common internal points. For each $F_i$ define the domain $D_i$: it is a
triangle if $\ell_i$ has two endpoints, and it is an annulus if $\ell_i$ is
closed. Define the mapping $f_i:D_i \to \Face_i$ as a composition of $\Map$
and the mapping $D_i \to F_i$ which sends the lines shown in Fig.
\ref{Fig:CharMap} to the level lines of $f$. It is easy to see that
$(f_i,\Face_i)$ define a triangulation of $G$ with marked vertices: the
vertex that corresponds to the compactifying curve touched by $\ell_i$, is
marked. This TMV will be denoted by $\Tria(f)$.

Direction of the $1$-form $df$ on crucial and concomitant lines defines a
natural orientation $\sigma(f)$ of the dual graph of the TMV $\Tria(f)$.
Obviously, $\sigma(f)$ is compatible with the vertex marking (in the sense
of Section \ref{Sec:TMV}), and contains no oriented cycles. The latter
assertion is true because $f$ defines a {\em monotone} mapping of the
oriented graph $\bigl(\Graph(\Tria(f)),\sigma(f)\bigr)$ to $\Real$.

\begin{statement}\label{St:TMVToFunc}
Let $\Tria$ be a TMV of $(G,V)$, and $\sigma$ be an orientation of
$\Graph(\Tria)$ compatible with the vertex marking containing no oriented
cycles. There exist exactly one function $f \in \Func(M)$ (up to homotopy)
such that $\Tria = \Tria(f)$ and $\sigma = \sigma(f)$. If the TMV $\Tria_1$
and $\Tria_2$ are flip equivalent, then the corresponding functions $f_1$
and $f_2$ are homotopic.
\end{statement}

\begin{proof}
The set of monotone mappings $\rho:\bigl(\Graph(\Tria),\sigma\bigr) \to
\Real$ is nonempty (because $\bigl(\Graph(\Tria),\sigma\bigr)$ does not
contain oriented cycles) and contractible (because it is a convex domain in
$\Real^{\#V}$); take some point $\rho_0$ in it. Draw a system of lines
$\ell_i \subset \tM$ such that $e_i = \Map(\ell_i)$ (where $e_i$ are edges
of $\Tria$), and if edges $e_i$ and $e_j$ go through a marked vertex $v_k$,
then $\ell_i$ and $\ell_j$ touch nondegenerately the corresponding
compactifying curve $\gamma_k$ at the same point (which is their common
endpoint). It is easy to see that the system of lines $\ell_i$ can be
restored from the triangulation $\Tria$ uniquely up to homotopy. The lines
$\ell_i$ divide $\tM$ to some parts; define the function $f$ for each of
these parts separately. To do it, let level lines of $f$ be preimages
(under $\Map$) of the curves drawn in Fig.  \ref{Fig:ConstrTMV}. The lines
$\ell_i$ become crucial and concomitant level lines of $f$. Assign the
values of $f$ on those lines monotonously and so that
$\left.f\right|_{\ell_k} = \rho(v_k)$ for concomitant lines, and
$\left.f\right|_{\ell_k} = \rho(v_k) \pm \epsilon$ for crucial lines
($\epsilon$ is small enough; recall that {\em two} crucial lines are glued
by $\Map$ into {\em one} edge of $\Tria$; signs $\pm$ for such lines are
taken appropriately). Outside the domains $F_i$ draw level lines of $f$
parallel to the relevant crucial lines. It is easy to see that the
described procedure defines $f$ in a homotopically unique way.

\begin{figure}
\begin{center}
%\input flipfunc.pic
%TexCad Options
%\grade{\on}
%\emlines{\on}
%\beziermacro{\off}
%\reduce{\on}
%\snapping{\off}
%\quality{2.00}
%\graddiff{0.01}
%\snapasp{1}
%\zoom{1.00}
\special{em:linewidth 0.4pt}
\unitlength 1mm
\linethickness{0.4pt}
\begin{picture}(119.67,66.00)
\emline{13.00}{49.33}{1}{31.67}{49.33}{2}
\emline{6.33}{42.67}{3}{6.33}{28.33}{4}
\emline{13.33}{22.67}{5}{31.33}{22.67}{6}
\emline{37.33}{41.67}{7}{37.33}{27.33}{8}
%\bezier{300}(6.33,31.67)(25.33,6.67)(16.33,49.33)
\emline{6.33}{31.67}{9}{7.84}{29.73}{10}
\emline{7.84}{29.73}{11}{9.26}{28.02}{12}
\emline{9.26}{28.02}{13}{10.58}{26.54}{14}
\emline{10.58}{26.54}{15}{11.81}{25.29}{16}
\emline{11.81}{25.29}{17}{12.94}{24.26}{18}
\emline{12.94}{24.26}{19}{13.98}{23.47}{20}
\emline{13.98}{23.47}{21}{14.93}{22.89}{22}
\emline{14.93}{22.89}{23}{15.78}{22.55}{24}
\emline{15.78}{22.55}{25}{17.20}{22.54}{26}
\emline{17.20}{22.54}{27}{17.77}{22.88}{28}
\emline{17.77}{22.88}{29}{18.25}{23.44}{30}
\emline{18.25}{23.44}{31}{18.63}{24.23}{32}
\emline{18.63}{24.23}{33}{18.92}{25.25}{34}
\emline{18.92}{25.25}{35}{19.11}{26.49}{36}
\emline{19.11}{26.49}{37}{19.21}{27.96}{38}
\emline{19.21}{27.96}{39}{19.22}{29.66}{40}
\emline{19.22}{29.66}{41}{19.13}{31.59}{42}
\emline{19.13}{31.59}{43}{18.95}{33.74}{44}
\emline{18.95}{33.74}{45}{18.67}{36.12}{46}
\emline{18.67}{36.12}{47}{18.30}{38.72}{48}
\emline{18.30}{38.72}{49}{17.84}{41.56}{50}
\emline{17.84}{41.56}{51}{17.28}{44.62}{52}
\emline{17.28}{44.62}{53}{16.33}{49.33}{54}
%\end
%\bezier{300}(26.00,22.67)(21.33,66.00)(37.00,38.67)
\emline{26.00}{22.67}{55}{25.65}{26.10}{56}
\emline{25.65}{26.10}{57}{25.37}{29.29}{58}
\emline{25.37}{29.29}{59}{25.16}{32.25}{60}
\emline{25.16}{32.25}{61}{25.02}{34.97}{62}
\emline{25.02}{34.97}{63}{24.94}{37.45}{64}
\emline{24.94}{37.45}{65}{24.93}{39.70}{66}
\emline{24.93}{39.70}{67}{25.00}{41.71}{68}
\emline{25.00}{41.71}{69}{25.12}{43.48}{70}
\emline{25.12}{43.48}{71}{25.32}{45.01}{72}
\emline{25.32}{45.01}{73}{25.59}{46.31}{74}
\emline{25.59}{46.31}{75}{25.92}{47.37}{76}
\emline{25.92}{47.37}{77}{26.32}{48.19}{78}
\emline{26.32}{48.19}{79}{26.80}{48.78}{80}
\emline{26.80}{48.78}{81}{27.33}{49.13}{82}
\emline{27.33}{49.13}{83}{27.94}{49.24}{84}
\emline{27.94}{49.24}{85}{28.62}{49.11}{86}
\emline{28.62}{49.11}{87}{29.36}{48.75}{88}
\emline{29.36}{48.75}{89}{30.17}{48.15}{90}
\emline{30.17}{48.15}{91}{31.05}{47.31}{92}
\emline{31.05}{47.31}{93}{32.00}{46.24}{94}
\emline{32.00}{46.24}{95}{33.02}{44.93}{96}
\emline{33.02}{44.93}{97}{34.10}{43.38}{98}
\emline{34.10}{43.38}{99}{35.25}{41.60}{100}
\emline{35.25}{41.60}{101}{37.00}{38.67}{102}
%\end
\emline{56.00}{48.67}{103}{74.67}{48.67}{104}
\emline{49.33}{42.00}{105}{49.33}{27.67}{106}
\emline{56.33}{22.00}{107}{74.33}{22.00}{108}
\emline{80.33}{41.00}{109}{80.33}{26.67}{110}
%\bezier{224}(50.00,33.67)(67.00,9.33)(63.33,35.67)
\emline{50.00}{33.67}{111}{51.57}{31.47}{112}
\emline{51.57}{31.47}{113}{53.04}{29.50}{114}
\emline{53.04}{29.50}{115}{54.42}{27.77}{116}
\emline{54.42}{27.77}{117}{55.71}{26.25}{118}
\emline{55.71}{26.25}{119}{56.90}{24.97}{120}
\emline{56.90}{24.97}{121}{58.01}{23.92}{122}
\emline{58.01}{23.92}{123}{59.01}{23.09}{124}
\emline{59.01}{23.09}{125}{59.93}{22.49}{126}
\emline{59.93}{22.49}{127}{60.75}{22.12}{128}
\emline{60.75}{22.12}{129}{61.48}{21.98}{130}
\emline{61.48}{21.98}{131}{62.12}{22.07}{132}
\emline{62.12}{22.07}{133}{62.66}{22.38}{134}
\emline{62.66}{22.38}{135}{63.11}{22.93}{136}
\emline{63.11}{22.93}{137}{63.47}{23.70}{138}
\emline{63.47}{23.70}{139}{63.73}{24.70}{140}
\emline{63.73}{24.70}{141}{63.90}{25.93}{142}
\emline{63.90}{25.93}{143}{63.98}{27.38}{144}
\emline{63.98}{27.38}{145}{63.96}{29.07}{146}
\emline{63.96}{29.07}{147}{63.85}{30.98}{148}
\emline{63.85}{30.98}{149}{63.65}{33.12}{150}
\emline{63.65}{33.12}{151}{63.33}{35.67}{152}
%\end
%\bezier{244}(63.67,34.67)(60.67,62.00)(80.33,34.67)
\emline{63.67}{34.67}{153}{63.44}{37.04}{154}
\emline{63.44}{37.04}{155}{63.31}{39.18}{156}
\emline{63.31}{39.18}{157}{63.27}{41.10}{158}
\emline{63.27}{41.10}{159}{63.33}{42.80}{160}
\emline{63.33}{42.80}{161}{63.47}{44.27}{162}
\emline{63.47}{44.27}{163}{63.72}{45.51}{164}
\emline{63.72}{45.51}{165}{64.05}{46.53}{166}
\emline{64.05}{46.53}{167}{64.48}{47.32}{168}
\emline{64.48}{47.32}{169}{65.01}{47.88}{170}
\emline{65.01}{47.88}{171}{65.62}{48.22}{172}
\emline{65.62}{48.22}{173}{67.14}{48.22}{174}
\emline{67.14}{48.22}{175}{68.04}{47.88}{176}
\emline{68.04}{47.88}{177}{69.03}{47.32}{178}
\emline{69.03}{47.32}{179}{70.11}{46.53}{180}
\emline{70.11}{46.53}{181}{71.29}{45.51}{182}
\emline{71.29}{45.51}{183}{72.56}{44.27}{184}
\emline{72.56}{44.27}{185}{73.93}{42.80}{186}
\emline{73.93}{42.80}{187}{75.39}{41.11}{188}
\emline{75.39}{41.11}{189}{76.94}{39.19}{190}
\emline{76.94}{39.19}{191}{78.59}{37.04}{192}
\emline{78.59}{37.04}{193}{80.33}{34.67}{194}
%\end
\emline{95.33}{48.00}{195}{114.00}{48.00}{196}
\emline{88.67}{41.33}{197}{88.67}{27.00}{198}
\emline{95.67}{21.33}{199}{113.67}{21.33}{200}
\emline{119.67}{40.33}{201}{119.67}{26.00}{202}
%\bezier{188}(88.67,31.67)(105.33,11.00)(107.67,31.67)
\emline{88.67}{31.67}{203}{90.40}{29.59}{204}
\emline{90.40}{29.59}{205}{92.05}{27.74}{206}
\emline{92.05}{27.74}{207}{93.62}{26.12}{208}
\emline{93.62}{26.12}{209}{95.11}{24.74}{210}
\emline{95.11}{24.74}{211}{96.52}{23.60}{212}
\emline{96.52}{23.60}{213}{97.85}{22.69}{214}
\emline{97.85}{22.69}{215}{99.09}{22.01}{216}
\emline{99.09}{22.01}{217}{100.26}{21.56}{218}
\emline{100.26}{21.56}{219}{101.34}{21.35}{220}
\emline{101.34}{21.35}{221}{102.34}{21.38}{222}
\emline{102.34}{21.38}{223}{103.26}{21.63}{224}
\emline{103.26}{21.63}{225}{104.10}{22.12}{226}
\emline{104.10}{22.12}{227}{104.86}{22.85}{228}
\emline{104.86}{22.85}{229}{105.54}{23.81}{230}
\emline{105.54}{23.81}{231}{106.14}{25.00}{232}
\emline{106.14}{25.00}{233}{106.65}{26.43}{234}
\emline{106.65}{26.43}{235}{107.09}{28.09}{236}
\emline{107.09}{28.09}{237}{107.67}{31.67}{238}
%\end
%\bezier{144}(107.67,31.00)(111.33,48.00)(119.00,31.33)
\emline{107.67}{31.00}{239}{108.20}{33.20}{240}
\emline{108.20}{33.20}{241}{108.76}{35.07}{242}
\emline{108.76}{35.07}{243}{109.37}{36.62}{244}
\emline{109.37}{36.62}{245}{110.01}{37.85}{246}
\emline{110.01}{37.85}{247}{110.70}{38.75}{248}
\emline{110.70}{38.75}{249}{111.42}{39.32}{250}
\emline{111.42}{39.32}{251}{112.18}{39.57}{252}
\emline{112.18}{39.57}{253}{112.98}{39.50}{254}
\emline{112.98}{39.50}{255}{113.81}{39.10}{256}
\emline{113.81}{39.10}{257}{114.69}{38.38}{258}
\emline{114.69}{38.38}{259}{115.60}{37.33}{260}
\emline{115.60}{37.33}{261}{116.56}{35.95}{262}
\emline{116.56}{35.95}{263}{117.55}{34.26}{264}
\emline{117.55}{34.26}{265}{119.00}{31.33}{266}
%\end
%\bezier{144}(88.67,34.33)(100.67,23.67)(107.33,42.33)
\emline{88.67}{34.33}{267}{90.31}{32.99}{268}
\emline{90.31}{32.99}{269}{91.90}{31.94}{270}
\emline{91.90}{31.94}{271}{93.44}{31.16}{272}
\emline{93.44}{31.16}{273}{94.92}{30.67}{274}
\emline{94.92}{30.67}{275}{96.36}{30.46}{276}
\emline{96.36}{30.46}{277}{97.74}{30.54}{278}
\emline{97.74}{30.54}{279}{99.07}{30.89}{280}
\emline{99.07}{30.89}{281}{100.35}{31.53}{282}
\emline{100.35}{31.53}{283}{101.58}{32.46}{284}
\emline{101.58}{32.46}{285}{102.76}{33.66}{286}
\emline{102.76}{33.66}{287}{103.89}{35.15}{288}
\emline{103.89}{35.15}{289}{104.96}{36.93}{290}
\emline{104.96}{36.93}{291}{105.99}{38.98}{292}
\emline{105.99}{38.98}{293}{107.33}{42.33}{294}
%\end
%\bezier{128}(107.33,41.67)(110.67,55.00)(119.33,38.67)
\emline{107.33}{41.67}{295}{107.89}{43.57}{296}
\emline{107.89}{43.57}{297}{108.51}{45.11}{298}
\emline{108.51}{45.11}{299}{109.19}{46.29}{300}
\emline{109.19}{46.29}{301}{109.94}{47.10}{302}
\emline{109.94}{47.10}{303}{110.75}{47.56}{304}
\emline{110.75}{47.56}{305}{111.63}{47.65}{306}
\emline{111.63}{47.65}{307}{112.57}{47.38}{308}
\emline{112.57}{47.38}{309}{113.58}{46.74}{310}
\emline{113.58}{46.74}{311}{114.66}{45.75}{312}
\emline{114.66}{45.75}{313}{115.80}{44.39}{314}
\emline{115.80}{44.39}{315}{117.00}{42.67}{316}
\emline{117.00}{42.67}{317}{119.33}{38.67}{318}
%\end
\emline{22.00}{18.33}{319}{12.00}{9.33}{320}
\emline{12.00}{9.33}{321}{22.00}{0.00}{322}
\emline{22.00}{0.00}{323}{30.67}{9.33}{324}
\emline{30.67}{9.33}{325}{22.00}{18.00}{326}
\emline{22.00}{18.00}{327}{22.00}{0.33}{328}
\put(20.00,4.00){\makebox(0,0)[cc]{$*$}}
\put(24.00,13.00){\makebox(0,0)[cc]{$*$}}
\emline{108.33}{17.67}{329}{98.33}{8.67}{330}
\emline{98.33}{8.67}{331}{108.33}{-0.67}{332}
\emline{108.33}{-0.67}{333}{117.00}{8.67}{334}
\emline{117.00}{8.67}{335}{108.33}{17.33}{336}
\put(106.33,3.33){\makebox(0,0)[cc]{$*$}}
\put(110.33,12.33){\makebox(0,0)[cc]{$*$}}
\emline{98.67}{8.67}{337}{116.33}{8.67}{338}
\end{picture}
\end{center}
\caption{Flip of a TMV leads to homotopic functions}\label{Fig:FlipFunc}
\end{figure}

For a proof of the second assertion see Fig. \ref{Fig:FlipFunc} (only one
case of the $AA$-flip is shown; the other cases and the $AB$-flips are
considered in a similar way).
\end{proof}

\begin{statement}\label{St:MEqN}
Let $f \in \Func(M)$ be generic. Then $n_{\Tria(f)} = m_{df}$.
\end{statement}

The proof is a straightforward comparison of the relevant definitions.

\begin{Corollary}[of Statement \ref{St:MEqN}]
The cocycles $\Delta$ from Section \ref{Sec:TMV} and $\Delta'$ from Section
\ref{Sec:Forms} coincide. The lattices $L$ from Section \ref{Sec:TMV} and
$\widetilde L$ from \ref{Sec:Forms} also coincide.
\end{Corollary}

\subsection{Proof of Theorem \ref{Th:HomPr}}\label{Subsec:MainPr}
Prove first that the mapping $d_*$ is onto. Let $\Conn$ be a connected
component of $\Forms(M)$. It is characterized by the functional $m_\Conn$
(equal to $m_\nu$ for the arbitrary $\nu \in \Conn$) and the orientation of
the boundary $\dM$ (induced by the arbitrary $\nu \in \Conn$). Take a web
on $(G,V)$ that does not contain parallel edges and every edge separates
two faces (it is easy to see that it is always possible). The dual graph
$\Graph$ of this web has univalent and trivalent vertices. There exist an
immersion of $\Graph$ to $\Real^2$ (edges are allowed to intersect) such
that no trivalent vertex and no internal point of the edge is a point of
the local extremum of $x$-coordinate. This immersion defines an orientation
$\sigma$ of the edges of $\Graph$ (the arrows are directed from left to
right with respect to the $x$-coordinate). It is easy to see that
$\bigl(\Graph,\sigma\bigr)$ contains no sources, sinks, and oriented
cycles. Therefore, the web can be supplied with a vertex marking such that
$\sigma$ is compatible with it.

Consider the obtained TMV $\Tria$. By Statement \ref{St:PropCochN},
Statement \ref{St:PropCochM}, and Corollary of Statement \ref{St:MEqN},
$d(m_\Conn - n_\Tria) = \Delta' - \Delta = 0$. By Poincar\'e duality
theorem there exists a cycle $s \in \Cycle_1(G,V;\Integer)$ such that for
any $\gamma \in \Cycle_1(G \setminus V, \partial G;\Integer) (= \Cycle_1(M,
\dM;\Integer))$
%*
\begin{equation}\label{Eq:MMinusN}
m_\Conn(\gamma) = n_\Tria(\gamma) + \langle s, \gamma\rangle.
\end{equation}
%*

Edges $e_i$ of the triangulation $\Tria$ form a system of generators for
the group $H_1(G,V;\Integer)$ (it follows from Condition \ref{It:Complete}
of the definition of web). Therefore there exists a cycle $s' = \sum_i
\epsilon_i e_i$ homologous to $s$. Since in (\ref{Eq:MMinusN}) the cycle
$s$ is defined up to addition of the boundary, one can assume simply that
$s = s'$. Consider a simplified TMV $\Tria_0$ whose diagram is $(\Tria,s)$.
It follows from (\ref{Eq:NMinusN}) and (\ref{Eq:MMinusN}) that
$n_{\Tria_0} = m_\Conn$. Consider a function $f \in \Func(M)$ such that
$\Tria(f) = \Tria_0$ (it exists by Statement \ref{St:TMVToFunc}). By
Statement \ref{St:MEqN} $m_{df} = m_\Conn$, and therefore, by Theorem
\ref{Th:HomTypeForm} $df \in \Conn$. So, $d_*$ is onto.

Suppose now that $f_1, f_2$ are generic, and $df_1,df_2 \in \Conn$. By
Statement \ref{St:PropCochM} and Statement \ref{St:MEqN}, $n_{\Tria(f_1)} =
m_{df_1} = m_{df_2} = n_{\Tria(f_2)}$. Therefore, by Theorem
\ref{Th:FlipEqTMV}, $\Tria(f_1)$ and $\Tria(f_2)$ are flip equivalent.
Apparently, $f_1$ and $f_2$ induce the same orientation on the connected
components of $\dM$. Therefore, by Statement \ref{St:TMVToFunc}, functions
$f_1$ and $f_2$ are homotopic. Thus, $d_*$ maps different connected
components of $\Func(M)$ to different connected components of $\Forms(M)$,
i.e., is one-to-one. Theorem is proved.

\subsection*{Some unsolved problems}

The most intriguing question we did not solve in the article is computation
of the higher homologies of $\Func(M)$. The connected components of the
space $\Forms(M)$ are contractible, but nothing is known about internal
structure of $\Func(M)$. In the terminology of \cite{PDR}, it is not clear
whether the one-parametric homotopy principle (Theorem \ref{Th:HomPr}) can
be extended to the multi-parametric homotopy principle. See Theorem 9 of
\cite{Crit} for illustration of the difficulties arising.

Another obscure point of our study is the definition of the lattice $L'$.
It appears in Section \ref{Sec:Forms} as $L \times \Integer_2$ (in the case
$\dM \ne \emptyset$), but this decomposition is not canonical: it depends
on the choice of the connected component of $\dM$. The author does not know
any natural geometric definition of $L'$. The same question applies to the
cocycle $\Delta$.

Functions $f \in \Func(M)$ have no critical points, but they can have {\em
critical levels}. We call the level $a \in \Real$ critical if there exists
a sequence $q_n \in M$ such that $f(q_n) \to a$ and $df(q_n) \to 0$.  The
number of critical levels is some ``complexity measure'' of the function
$f$. It would be interesting to estimate this number from below for a
function $f \in \Func(M)$ if the cochain $m_{df}$ is known. An answer would
be a sort of Morse inequality for $f \in \Func(M)$. We expect also that a
more elaborated analog of Morse theory exists for $\Func(M)$.

Possible extension of the results of the articles to manifolds of many
dimensions is a natural, tempting, but apparently a very complicated
problem.

\begin{thebibliography}{1}

\bibitem{ShPoly}
{W}. Thurston.
\newblock Shapes of polyhedra.
\newblock Preprint, June 1987.

\bibitem{QuaDiff}
Yu.Baryshnikov.
\newblock Bifurcation diagrams of quadratic differentials.
\newblock Preprint, May 1996.

\bibitem{TeichmSp}
R.C.Penner.
\newblock The {T}eichm\"uller space of a punctured surface.
\newblock {\em Comm.Math.Phys.}, 1987.

\bibitem{Disser}
{S}.{S}.{A}nisov.
\newblock Problems of topology, integral geometry, and computational complexity
  in the theory of singularities.
\newblock Ph.D.Thesis (in Russian), 1997.

\bibitem{FlipEq}
S.S.Anisov.
\newblock Flip-equivalence of triangulations of surfaces.
\newblock {\em Moscow State University Vestnik (Mathematics)}, (2):61--67,
  1994.
\newblock (in Russian).

\bibitem{IUM}
{S}.{S}.{A}nisov{,} {S}.{K}.{L}ando.
\newblock Topological complexity of {$\Torus^2$}-bundles over the circle.
\newblock In {B}.{L}.{F}eigin{,} {V}.{A}.{V}assiliev, eds., {\em Proc. IUM}.
  1998.
\newblock (to appear).

\bibitem{PDR}
{M}. Gromov.
\newblock {\em Partial differential relations}.
\newblock Birkh\"auser, Berlin, 1986.

\bibitem{Crit}
Yu.{M}.{B}urman.
\newblock Morse theory for functions of two variables without critical points.
\newblock {\em Functional Differential Equations}, 3(1--2):31, 1995.

\end{thebibliography}

\end{document}

