Commit 7077afe7 authored by Christoph Otto's avatar Christoph Otto
Browse files

Initial commit beta version of documentation OCN-SIM-FLEX

parents
[Dolphin]
Timestamp=2017,2,2,11,10,36
Version=3
[Settings]
HiddenFilesShown=true
# ignore all latex internal files
*.aux
*.bbl
*.blg
*.log
*.nav
*.out
*.snm
*.gz
*.toc
%==============================================================================
% Beamer style for the poster template posted at
% http://www.nathanieljohnston.com/2009/08/latex-poster-template/
%
% Created by the Computational Physics and Biophysics Group at Jacobs University
% https://teamwork.jacobs-university.de:8443/confluence/display/CoPandBiG/LaTeX+Poster
% Modified by Nathaniel Johnston (nathaniel@nathanieljohnston.com) in August 2009
% =============================================================================
\ProvidesPackage{beamerthemeconfposter}
\RequirePackage[T1]{fontenc}
\RequirePackage{lmodern}
\RequirePackage{amsmath,amssymb}
\RequirePackage{ragged2e}
\RequirePackage{tabularx}
% Requirement: Lato font for latex. On Ubuntu, it's e.g. contained in texlive-fonts-extra.
% In a terminal, do: sudo apt-get install texlive-fonts-extra.
% If you don't want to install the lato font for latex, just comment the line below.
% However, you're no longer corporate-identity-compliant then.
% Set sans serif font to lato in accordance with logo. hardest task was to figure
% out the font's name. compare:
% http://tex.stackexchange.com/questions/25249/how-do-i-use-a-particular-font-for-a-small-section-of-text-in-my-document/25251
\renewcommand{\sfdefault}{fla}
% Include this package in order to prevent latex beamer class from overwriting
% the neat math font we are used to in latex. Compare e.g.:
% http://tex.stackexchange.com/questions/193278/how-to-change-the-font-family-to-default-for-math-codes-in-beamer
\usefonttheme{professionalfonts}
% If we don't do this, strangely there will be no figure numbering and no correct
% style, i.e. setbeamercolor/setbeamerfont don't work for element "structure"
\usecaptiontemplate{\structure{\insertcaptionname~\insertcaptionnumber: }\insertcaption}
%==============================================================================
% CUSTOM COMMANDS
%==============================================================================
% An empty spacer column. Width is configured in this package's WIDTHS section.
\newcommand{\OCNSpacerCol}{\begin{column}{\sepwid}\end{column}}
% Defines columns environment in a frame and automatically adds emty spacer column at the end
\newenvironment{OCNCols}{\begin{columns}\ignorespaces}{\OCNSpacerCol\end{columns}\ignorespacesafterend}
% Defines col with single width automatically adds emty spacer column
\newenvironment{OCNSingleCol}{\OCNSpacerCol\begin{column}{\onecolwid}\ignorespaces}{\end{column}\ignorespacesafterend}
% Defines col with double width automatically adds emty spacer column
\newenvironment{OCNDoubleCol}{\OCNSpacerCol\begin{column}{\twocolwid}\ignorespaces}{\end{column}}
% Used for setting sub headings in blocks
\newcommand{\OCNHeadingInBlock}[1]{\textsf{\textbf{#1}}}
% Small parskip
\newcommand{\OCNSmallSkip}{\vspace{\vskiplength}}
% Tikz: Draws an arc specified by it's center.
% Parameters:
% 1: options in [] braces for draw command
% 2: center specified as (x,y) value pair
% 3: angle 1
% 4: angle 2
% 5: radius
\def\OCNCenterArc[#1](#2)(#3:#4:#5)%
{ \draw[#1] ($(#2)+({#5*cos(#3)},{#5*sin(#3)})$) arc (#3:#4:#5); }
% Tikz: Draw an icon box holding text. Two the left, there is a square area for
% an icon separated by a vertical line on the left
% Parameters:
% 1: x
% 2: y
% 3: width
% 4: height
% 5: text
\def\OCNTikzIconBox(#1,#2,#3,#4)(#5){%
\draw[line width=0.5mm, color=tSBI, rounded corners=0.1cm] (#1,#2) rectangle ($ ({#1+#3}, {#2+#4}) $);
\draw[line width=0.5mm, color=tSBI] ($ (#1+#4, #2) $) -- ($ (#1+#4, #2+#4) $);
\node[align=center] at ($ (#1+0.5*#4+0.5*#3, #2+#4*0.5) $) {#5};
}
% Vertical version
\def\OCNTikzIconBoxV(#1,#2,#3,#4)(#5){%
\draw[line width=0.5mm, color=tSBI, rounded corners=0.1cm] (#1,#2) rectangle ($ ({#1+#3}, {#2+#4}) $);
\draw[line width=0.5mm, color=tSBI] ($ (#1, #2+#4-#3) $) -- ($ (#1+#3, #2+#4-#3) $);
\node[align=center,rotate=90] at ($ (#1+0.5*#3, #2+0.5*#4-0.5*#3) $) {#5};
}
% Tikz: draw an arrow conforming to OCN Academy standards
% Parameters:
% 1: optinoal arguments (color, etc.)
% 2: starting point
% 3: ending point
\def\OCNTikzArrow[#1](#2)(#3)%
{ \draw[-{Triangle[length=2.5mm, width=1.5mm]}, line width=0.5mm, line cap=round, #1] (#2) -- (#3);}
%==============================================================================
% WIDTHS
%==============================================================================
\newlength{\sepwid}
\newlength{\onecolwid}
\newlength{\twocolwid}
\newlength{\contentWidth}
\newlength{\vskiplength}
\newlength{\bskiplength}
\setlength{\sepwid} {0.025\paperwidth} % Separation between columns
\setlength{\onecolwid} {0.3\paperwidth} % width of one column
\setlength{\twocolwid} {0.625\paperwidth} % width of two columns
\setlength{\contentWidth}{0.95\paperwidth} % width of content
\setlength{\vskiplength} {1.5ex} % Seperation inserted by custom \cskip command defined below
\setlength{\bskiplength} {2ex} % Space below blocks (normal blocks and alert blocks)
% Spacing
\setlength{\headsep}{-0.5cm} % Move all the columns upwards and closer to the header
\setbeamersize{description width=0.3cm} % Reduce indentation of descriptions
%==============================================================================
% Colours
%==============================================================================
\definecolor{tSBI} {HTML}{729FCF} % tango skyblue 1
\definecolor{tSBII}{RGB} {52,101,164} % tango skyblue 2
\definecolor{tCIII}{HTML}{4E9A06} % tango cameleon 3
\definecolor{ubOr} {RGB} {233,84,32 } % Ubuntu orange
% Captions of figures, tables, etc.
\setbeamercolor{structure}{fg=tSBII}
% Block
\setbeamercolor{block title} {fg=white,bg=ubOr} % Colors of the block titles
\setbeamercolor{block body} {fg=black,bg=white} % Colors of the body of blocks
% Alert block
\setbeamercolor{block alerted title} {fg=white,bg=tSBII} % Colors of the highlighted block titles
% Bibliography
\setbeamercolor{bibliography item} {fg=black,bg=white} % Reference in brackets [xx]
\setbeamercolor{bibliography entry author} {fg=black,bg=white}
\setbeamercolor{bibliography entry journal} {fg=black,bg=white}
\setbeamercolor{bibliography entry note} {fg=black,bg=white}
\setbeamercolor{bibliography entry location} {fg=black,bg=white}
% Itemize/enumerate
\setbeamercolor{item}{fg=tSBII}
% Description
\setbeamercolor{description item}{fg=black}
\setbeamerfont{description item}{series=\bfseries}
%==============================================================================
% Fonts
%==============================================================================
\setbeamerfont{block title}{series=\bfseries}
\setbeamerfont{block title}{family=\sffamily}
\setbeamerfont{block title}{size=\normalsize}
\setbeamerfont{block body}{family=\rmfamily}
\setbeamerfont{frametitle}{family=\sffamily}
\setbeamerfont{frametitle}{size=\Huge}
\setbeamerfont{structure}{series=\bfseries}
%==============================================================================
% Other theme options
%==============================================================================
% set bibliography style
\setbeamertemplate{bibliography item}[text]
% Remove navigation symbols
\beamertemplatenavigationsymbolsempty
% define some length variables that are used by the template
\newlength{\inboxwd}
\newlength{\iinboxwd}
%==============================================================================
% Header
%==============================================================================
\setbeamertemplate{headline}{
\leavevmode
\begin{center}
% Footer contents. The @{} removes the margins in front of the first and behind the last column
\begin{tabularx}{\contentWidth}{@{}lXr@{}}
\usebeamerfont{frametitle}\color{tSBII}\inserttitle
&&
\includegraphics[width=0.8\onecolwid]{pic/Logo.pdf}
\end{tabularx}
\\ \vspace{0.1cm}
\textcolor{tSBII}{\rule{\contentWidth}{0.05cm}}
\end{center}
}
%==============================================================================
% Footer
%==============================================================================
\setbeamertemplate{footline}{
\leavevmode
\begin{center}
% Ruler for seperation
\textcolor{tSBII}{\rule{\contentWidth}{0.05cm}}
\vspace{0.1cm} \\
% Footer contents. The @{} removes the margins in front of the first and behind the last column
\begin{tabularx}{\contentWidth}{@{}lXr@{}}
\normalsize \textbf{\insertsubtitle} ~|~ \insertauthor~|~christoph@ocnacademy.org && \normalsize \thepage
\end{tabularx}
\end{center}
}
%==============================================================================
% Block
% Since spacing in beamercolorboxes appears to be a little bit messy to
% me, I had to start playing around with minipages. Not the best thing
% to do, but hey...
%==============================================================================
\setbeamertemplate{block begin}{
% --- Header ---
\begin{beamercolorbox}[center]{block title}
\begin{minipage}[c][3.5ex][c]{\linewidth}
\centering
\usebeamerfont{block title}\insertblocktitle
\end{minipage}
\end{beamercolorbox}
% --- Block content ---
\usebeamerfont{block body}
\vspace{\vskiplength}
\justifying
}
\setbeamertemplate{block end}{
\vspace{\bskiplength}
}
%==============================================================================
% Alert block
% Refer to comment given above in "Block"
%==============================================================================
\setbeamertemplate{block alerted begin}{
\begin{beamercolorbox}[center]{block alerted title}
% --- Header ---
% Easy peasy...
\begin{minipage}[c][3.5ex][c]{\linewidth}
\centering
{\usebeamerfont{block title}\insertblocktitle}
\end{minipage}
% Calc the widths of the embedded boxes
\setlength{\inboxwd}{\linewidth}
\addtolength{\inboxwd}{-0.1cm}
\setlength{\iinboxwd}{\inboxwd}
\addtolength{\iinboxwd}{-0.4cm}
% --- Block content ---
% We have to use a minipage, since somehow we can't manage to align
% the embedded beamercolorbox centered in the containing box. However,
% minipage behaves well and politely centers itself.
\begin{minipage}{\inboxwd}
% Inner box to get the color right
\begin{beamercolorbox}[wd=\inboxwd,center]{block body}
% Another minipage as to get the margins right. Didn't manage
% to get proper left/right margins for the text otherwise
\begin{minipage}{\iinboxwd}
\usebeamerfont{block body}
\vspace{0.5\vskiplength}
}
\setbeamertemplate{block alerted end}
{
\vspace{0.5\vskiplength}
\end{minipage}
\end{beamercolorbox}
\vspace{0.05cm}
\end{minipage}
\end{beamercolorbox}
\vspace{\bskiplength}
}
\ No newline at end of file
# Case name ====================================================================
# ==============================================================================
nameOfCase = example # This will be the name of the output folder
# Solver configuration =========================================================
# Solver types (solType)
# 1 - Lagrangian dynamics - explicit Euler-method
# 2 - Lagrangian dynamics - velocity-Verlet integration
# 3 - Reconstructed reaction forces formulation type I
# 4 - Reconstructed reaction forces formulation type II
# 5 - Reconstructed reaction forces formulation type III -- recommmended
# for most applications
# ==============================================================================
solType = 5 # Type of solver according to listing above
nSteps = 4000 # Number of timesteps
nOut = 100 # Write every nOut-th step to disk
tStep = 0.005 # Size of timestep
# Global configuration =========================================================
# ==============================================================================
# G-vector
gx = 0.0 # x-component of g-vector
gy = 0.0 # y-component of g-vector
gz = -9.81 # z-component of g-vector
# Fluid model data =============================================================
# ==============================================================================
fluidModel = example.fld
# Multibody structural configuration ===========================================
# ==============================================================================
multibodyData = example.mbd
# Multibody solver configuration ===============================================
# ==============================================================================
# Coefficients for PID-controlled constraints
constr_kp = 100
constr_ki = 100
constr_kd = 100
# Common properties=============================================================
# ==============================================================================
# Fluid density [kg/m^3]
rho = 1000.0
# Type of velocity field calculation============================================
# Types of velocity fields (fieldType)
# 1 - Non-moving fluid
# 2 - Constant, uniform velocity field
# ==============================================================================
fieldType = 2
u = 1.0
v = 0.0
w = 0.0
# Hydrodynamic forces===========================================================
# ==============================================================================
# Apply simple, mass-proportional damping fD = vRel*m*dampFac . 1:true, 0:false.
# Use only for simple testing purposes.
simpDamp = 0
#dampFac = 20.0
# Coefficient tables ===========================================================
# ==============================================================================
nCTables = 1 # List format as used in multibody data file.
iCTable = 1
fName = ropeCoeffs.matr
\ No newline at end of file
# Inertial frames ==============================================================
# Here, we define fixed markers in the inertial coordinate system (CSYS0),
# to which we will be able to attach further elements (Ropes, Springs, etc).
# Each marker has three translational coordinates. Rotations of markers
# cannot be defined. In order to attach, for instance, a rope rotated by an
# initial angle, give the corresponding joint of the rope an initial angle
# alpha0 or beta0 (compare below).
# ==============================================================================
CSYS0__nMarkers = 2
CSYS0__iMarker = 1
x = 0.0
y = 0.0
z = 0.0
CSYS0__iMarker = 2
x = 0.0
y = 20.0
z = 0.0
# Ropes ========================================================================
# Local longitudinal axis: z!
# ==============================================================================
nRopes = 6 # Total number of ropes
iRope = 1 # Number of current rope. Numbers need to be in ascending order and complete. 1,2,3,...,nRopes
length = 20.0 # Length of the rope
diam = 0.02 # Diameter
rho = 1500.0 # Density
nElems = 20 # Number of elements
iPred = 0 # Predecessor body ID. 0: if rope is attached to marker in CSYS0; >0: if rope is attached to another rope
mPred = 1 # Marker on predecessor body. In CSYS0, this equals the marker, on another rope it equals the n-th element of the rope and must thus be <=nElems(iPred)
alpha0 = -180.0 # Initial joint angle alpha in terms of xyz-Kardan angles.
beta0 = 90.0 # Initial joint angle beta in terms of xyz-Kardan angles
IDCTable = 1 # ID of hydrodynamic coefficient table. Tables are defined in fluidModel file, which is in turn specified in the load case main file.
iRope = 2
length = 20.0
diam = 0.02
rho = 1.5e+3
nElems = 20
iPred = 0
mPred = 2
alpha0 = -180.0
beta0 = 90.0
IDCTable = 1
iRope = 3
length = 10.0
diam = 0.02
rho = 800.0
nElems = 10
iPred = 1
mPred = 10
alpha0 = 90.0
beta0 = 0.0
IDCTable = 1
iRope = 4
length = 10.0
diam = 0.02
rho = 800.0
nElems = 10
iPred = 2
mPred = 10
alpha0 = -90.0
beta0 = 0.0
IDCTable = 1
iRope = 5
length = 10.0
diam = 0.02
rho = 2500
nElems = 10
iPred = 1
mPred = 5
alpha0 = 90.0
beta0 = 0.0
IDCTable = 1
iRope = 6
length = 10.0
diam = 0.02
rho = 2500
nElems = 10
iPred = 2
mPred = 5
alpha0 = -90.0
beta0 = 0.0
IDCTable = 1
# Rigid bodies =================================================================
# ==============================================================================
nRigids = 2 # Total number of rigid bodies in system.
# --- Example rigid body number 1 ---
iRigid = 1 # ID of rigid body. Numbers need to be in ascending order. 1,2,3,...,nRigids.
mass = 1001.0 # Mass
vol = 1.0 # Volume
# Initial pose. Defined in general matrix format, i.e. preceded by number of rows and columns. Always needs to be nRows=1, nCols=7.
# Unlike ropes, rigid bodies are not attached to other bodies by joints. They are rather connected by force elements, as e.g. springs.
# In consequence, the initial pose needs to be physically consistent, i.e. if they are connected to other elements by a spring, the
# initial elongation should be such, that initial accelerations are not too high. Typically, the initial pose is chosen such, that the
# initial elongation of attached spring elements is zero.
# The initial pose is determined by 3 translational coordinates in CSYS0 plus four Euler-parameters defining the rotational
# orientation w.r.t. CSYS0. Compare e.g. http://mathworld.wolfram.com/EulerParameters.html.
# In consequence, we have
#
# [r_x r_y r_z e_0 e_1 e_2 e_3]
#
# defining the initial pose with r_x/y/z being the translational and e_0..3 the Euler-parameters
nRows = 1
nCols = 7
20.0 1.0 1.0 1.0 0.0 0.0 0.0
# Local markers. Defines marker translational positions in local coordinate system. Markers are used e.g. to attach force elements
# like springs, etc. The 3 translational marker positions are defined columnwise in standard matrix format. Consequently, nRows
# always needs to be nRows=3. For instance, for four local markers, we have
#
# r1_x r2_x r3_x r4_x
# r1_y r2_y r3_y r4_y
# r1_z r2_z r3_z r4_z
#
# with ri_x/y/z defining the x-,y- and z-position of node i.
nRows = 3
nCols = 4
0.0 0.0 0.0 0.0
-1.0 1.0 1.0 -1.0
-1.0 -1.0 1.0 1.0
# --- Example rigid body number 2 ---
iRigid = 2
mass = 1001.0
vol = 1.0
# Initial pose
nRows = 1
nCols = 7
20.0 19.0 1.0 1.0 0.0 0.0 0.0
# Local markers
nRows = 3
nCols = 4
0.0 0.0 0.0 0.0
-1.0 1.0 1.0 -1.0
-1.0 -1.0 1.0 1.0
# Implicit constraints between ropes ===========================================
# Loop closing constraints are defined here. In the current implementation,
# they are realised by sort of cheating by using PID-Controllers instead
# of calculating the corresponding Lagrange multipliers in terms of classical
# Lagrangian dynamics. The corresponding PID-parameters are solver options
# and thus to be found in the main loadcase file.
#
# IMPLICT CONSTRAINTS ONLY ACT BETWEEN ROPES. If you want to connect a rope
# to a marker in CSYS0 use a joint or a force element. If you want to connect
# to a rigid body,use a force element.
#
# ==============================================================================
nConstr = 2 # Total number of implicit loop closing constraints in the system.
iConstr = 1 # ID of constraint. Numbers need to be in ascending order. 1,2,3,...,nConstr
i1 = 3 # ID of first rope involved
m1 = 10 # ID of marker on first rope. Equals the element number and must thus be <=nElems(i1)
i2 = 4 # ID of second rope involved
m2 = 10 # ID of marker on second rope. Equals the element number and must thus be <=nElems(i2)
iConstr = 2
i1 = 5
m1 = 10
i2 = 6
m2 = 10
# Force elements ===============================================================
# Unlike constraints, springs can act on ropes, markers in CSYS0 and markers on rigid bodies
# ==============================================================================
nSprings = 2 # Total number of springs in the system
iSpring = 1 # ID of spring. Numbers need to be in ascending order. 1,2,3,...,nSprings
c = 100.0 # Stiffness
d = 50.0 # Damping constant
i1 = 1 # ID of first target involved. <0: rigid body; 0: CSYS0; >0: rope
m1 = 20 # Marker ID on first target. Compare comments on mPred for the ropes.
i2 = -1 # ID of second target.
m2 = 1 # Marker ID in second target
iSpring = 2
c = 100.0
d = 50.0
i1 = 2
m1 = 20
i2 = -2
m2 = 2
%----------------------------------------------------------------------------------------
% PACKAGES AND OTHER DOCUMENT CONFIGURATIONS
%----------------------------------------------------------------------------------------
\documentclass[t,10pt]{beamer}
% Could have also used beamerposter package, however, this somehow screws
% up my desired font size
\geometry{a4paper,landscape}
\usetheme{confposter}
\usepackage{listings}
\usepackage{graphicx} % Required for including images
\usepackage[english]{babel}
\usepackage{capt-of}
% Everything we need for tikz
\usepackage{tikz}
\usetikzlibrary{patterns,calc,arrows.meta}
%==============================================================================
% AUTHOR
%==============================================================================
\author{Christoph Otto}
%==============================================================================
% LET THE GAMES BEGIN
%==============================================================================
\begin{document}
%----------------------------------------------------------------------------------------
% PREDEFINE SOURCE CODE TO BE DISPLAYED
%----------------------------------------------------------------------------------------
% Accoring to http://tex.stackexchange.com/questions/68085/how-to-put-c-source-code-into-beamer-slides
% we have to predefine verbatims, because the frame environment can't handle lstlistings otherwise.
\defverbatim[colored]\lstI{
\lstinputlisting[language=Python,basicstyle=\ttfamily,keywordstyle=\color{tSBII}\bfseries,commentstyle=\color{tCIII}]{example.conf}
}
%----------------------------------------------------------------------------------------
% AN INTRO TO OCN-SIM FLEX
%----------------------------------------------------------------------------------------
\title{An Intro to OCN-SIM Flex}
\subtitle{Introduction and General Information}
\begin{frame}\begin{OCNCols}
% --- First col ---
\begin{OCNSingleCol}