\documentclass[a4paper,10pt]{report}
\input{../macros_docu} % Customizations 

% ---- format de page A4
	\setlength{\textwidth }{16cm}	% largeur de ligne
	\setlength{\textheight}{23cm}   % hauteur du texte
	\setlength{\oddsidemargin}{0cm} % marge pages impaires
	\setlength{\evensidemargin}{0cm}% marge pages paires
	\setlength{\topmargin}{0cm} 	

% Title Page
\title{Sofa Documentation\\
\vspace{10mm}\normalsize{Also See \bf{http://www.sofa-framework.org/documentation} } }
\author{The Sofa Team}




\begin{document}
\maketitle

\begin{abstract}	
\sofa{} (Simulation Open Framework Architecture) is an open-source C++ library primarily  targeted at interactive medical simulation.
\sofa{} facilitates collaborations between specialists from various domains, by decomposing complex simulators into components designed independently and organized in a scenegraph data structure.
Each component encapsulates one of the aspects of a simulation, such as the degrees of freedom, the forces and constraints, the differential equations, the main loop algorithms, the linear solvers, the collision detection algorithms or the interaction devices. The simulated objects can be represented using several models, each of them optimized for a different task such as the computation of elastic forces, collision detection, haptics or visual display. To ensure a consistent simulation, these models are synchronized during the simulation using a mapping mechanism.
CPU and GPU implementations can be transparently combined to exploit the computational power of modern hardware architectures.
%Simulations descriptions files can be read from and written to xml files.
As a result of this flexible and efficient architecture, \sofa{} can be used as a test-bed to compare models and algorithms, or as a basis for the development of complex, high-performance simulators.

\end{abstract}

\tableofcontents

\part{Foundation of SOFA}

% This chapter is borrowed from a stand-alone document defined in directory introduction/
\chapter{Introduction to \sofa}

\graphicspath{{../introduction/}}  % to include images
\input{../introduction/introduction_body}

\chapter{Multi-Model approach}
\graphicspath{{../multimodel/}}  % to include images
\input{../multimodel/multimodel_body}
\input{../multimodel/mappingsIntro_body}


\chapter{Data Structure}
The organization of simulation data is a complex issue. We have identified three relevant levels, and proposed different solutions for each of them.
The coarsest structure is the scenegraph, used to hierarchically organize the groups of objects and their multi-models.
At a finer scale, the attributes of the components can be linked by relations.
Finally, the geometrical models and the topological changes deserve a special attention.
\graphicspath{{../datastructure/}}  % to include images
\input{../datastructure/scenegraph}
\input{../datastructure/visitors}
\input{../datastructure/engines}
\input{../datastructure/meshTopologies}
%%%%%%%%%%%%%%%%%%%% COMPONENTS%%%%%%%%%
%1 STATES
\chapter{States}
\graphicspath{{../states/}}  % to include images
\input{../states/states}


%2 MECA FORCES
\chapter{Mechanical forces}
\emph{to be completed}
\section{ForceField components}

\section{Interaction ForceField}
\label{sec:interactionforcefield}

\section{Mass and inertial forces}

%3 MAPPING
\chapter{Mappings}
\input{../mappings/mappings_body}
\section{Barycentric Mapping}
\section{Rigid Mapping}
\section{Identity Mapping}
\section{Skinning Mapping}


%4 SOLVERS
\chapter{Solvers}
\label{chap:solvers}
\graphicspath{{../solvers/}} 
\input{../solvers/solvers}



%5 COLLISION
\chapter{Collision detection}
\graphicspath{{../collision/}} 
\input{../collision/collision}
\vspace{1cm}
\emph{to be completed}


%6 VISUAL
\chapter{Visual Rendering}


%7 HAPTIC
\chapter{Haptic Rendering}
\label{chap:haptic}
\graphicspath{{../haptic/}} 
\input{../haptic/hapticRendering}

\pagebreak
\part{Design and Development}
\pagebreak

%%%%%%%%%%%%%%% OLD CHAPTERS %%%%%%%%%%%
% This chapter is borrowed from a stand-alone document defined in directory design/
\chapter{Design}
\graphicspath{{../design/}}  % to include images
\input{../design/design_body}


\chapter{Modules}
\graphicspath{{../modules/}}  % to include images
In this document we explain the usage and the functionalities of the modules developped using the Core Sofa Framework.
\input{../modules/modules_body}

\part{Practical guide}

\chapter{How To}
\graphicspath{{../HowTo/}}  % to include images
In this document we will try to give small tutorials on various topics you should encounter during your experience with SOFA.
\input{../HowTo/howto_body}



% This chapter is defined here
\chapter{How to contribute to this documentation}
\section{Document structure}
This document gathers the content of other documents located in different subdirectories. These documents can also be compiled as stand-alone documents.
The structure can be illustrated as follows:
\begin{itemize}
 \item \texttt{sofaDocumentation/sofadocumentation.tex} : the root document.
 \item \texttt{macros\_docu.tex} : custom commands and macros. This file is included by the root document.
 \item \texttt{introduction} : a subdirectory containing a chapter of this document.
\begin{itemize}
 \item \texttt{introduction.tex} : a stand-alone article containing the same. This file may include \texttt{../macros\_docu.tex} to use the common custom commands.
 \item \texttt{introduction\_body.tex} : the text of the chapter/article. This file is included as a chapter by \texttt{sofadocumentation.tex}, and included as full article text by \texttt{introduction.tex}.
\end{itemize}
 \item there could (and hopefully will !) be other subdirectories with a similar structure.
\end{itemize}

\section{Compiling the document}
\subsection{File formats}
The graphics are handled by: \texttt{\textbackslash usepackage[pdftex]\{graphicx\}}. This allows the inclusion of \texttt{.png} images rather than \texttt{.eps}, which makes the image files much smaller, and compilation of \texttt{html} faster. The result of the compilation is a \texttt{.pdf} rather than a \texttt{.dvi} file.

\subsection{Include paths}
The root document includes files in the subdirectories, which in turn include files too. The path from the subdirectory (used when compiling a stand-alone article) is the same as from the parent directory (used when compiling the whole report).

\subsection{HTML}
HTML can be generated using the following command:\\
\texttt{latex2html sofadocumentation.tex -mkdir -dir ./html -show\_section\_numbers -split 1}
\\
Currently, the listings do not appear in html.

\bibliographystyle{plain}
\bibliography{../biblio}



\end{document}          
