Commit ba4f4702 authored by Mark van Turnhout's avatar Mark van Turnhout
Browse files

documentation up to assembly, including screenshots

parent bc9386b8
......@@ -286,7 +286,7 @@ for b = 1:numel(basil)
fprintf(fid,'\n# assist disc to help partitioning of skin for contact\n');
fprintf(fid,'myModel.Part(name=''assistDisc'', dimensionality=THREE_D, type=ANALYTIC_RIGID_SURFACE)\n');
fprintf(fid,'s1 = myModel.ConstrainedSketch(name=''discSketch'', sheetSize=10.0)\n');
fprintf(fid,'s1.Line(point1=(%1.1f, -%f), point2=(%1.1f, -%f))\n',param.ri*[4 -1 4.5 -1]);
fprintf(fid,'s1.Line(point1=(%1.1f, %f), point2=(%1.1f, %f))\n',param.ri*[4 -1 4.5 1]);
fprintf(fid,'s1.ConstructionLine(point1=(0.0, -%1.1f), point2=(0.0, 0.0))\n',param.ri);
fprintf(fid,'p = myModel.parts[''assistDisc'']\n');
fprintf(fid,'p.AnalyticRigidSurfRevolve(sketch=s1)\n');
......
......@@ -309,7 +309,7 @@ myPart.Set(referencePoints=lastRP, name='boneRP')
\end{lstlisting}
The definition of the material parameters for the soft tissue is straightforward:
\begin{lstlisting}[language=apython]
\begin{lstlisting}[language=apython, numbers=none]
# define material
import material
myModel.Material(name='softTissue')
......@@ -317,7 +317,7 @@ myModel.materials['softTissue'].Density(table=((1e-9, ), ))
myModel.materials['softTissue'].Hyperelastic(testData=OFF, type=OGDEN, volumetricResponse=VOLUMETRIC_DATA, table=((0.003600, 5.000000, 57.471264), ))
\end{lstlisting}
Finally, we define a (homogeneous solid) `section' for the soft tissue (leg) with the material properties that we have just defined (line \texttt{4}). The volume that represents the soft tissue is assigned to a new set (lines \texttt{5--7}), and this set is assigned to the `section' (lines \texttt{8--9}):
\begin{lstlisting}[language=apython]
# section and material assignment
import section
......@@ -328,4 +328,124 @@ c = p.cells
p.Set(cells=c, name='softTissue')
region = p.sets['softTissue']
p.SectionAssignment(region=region, sectionName='tissueSection', offset=0.0, offsetType=MIDDLE_SURFACE, offsetField='', thicknessAssignment=FROM_SECTION)
\end{lstlisting}
\ No newline at end of file
\end{lstlisting}
\subsection{The indenter}
The indenter is modelled in a new \texttt{part} as a analytical rigid surface: it will not be meshed and it requires a reference point to apply boundary conditions. Because the geometry of the indenter is known (given `shape' with `size' \texttt{param.ri}) we can draw it in the Abaqus `sketch' module:
\begin{lstlisting}[language=apython]
# build indenter
import sketch
myModel.Part(name='indenter', dimensionality=THREE_D, type=ANALYTIC_RIGID_SURFACE)
s1 = myModel.ConstrainedSketch(name='indenterSketch', sheetSize=10.0)
s1.ArcByCenterEnds(center=(0.0, -1.5), point1=(0.0, 0.0), point2=(1.5, -1.5), direction=CLOCKWISE)
s1.Line(point1=(1.5, -1.5), point2=(1.5, -4.5))
s1.ConstructionLine(point1=(0.0, -4.5), point2=(0.0, 0.0))
p = myModel.parts['indenter']
p.AnalyticRigidSurfRevolve(sketch=s1)
myModel.parts['indenter'].ReferencePoint(point=(0, 0, 0))
\end{lstlisting}
The sketch itself (lines \texttt{5--7}, figure \ref{indentersketch}) is axisymmetric and is rotated around it's symmetry axis (line \texttt{7}) when it is imported into the \texttt{part} (lines \texttt{8--9}, figure \ref{indenterpart}).
\begin{figure}[h!]
\subfloat[\label{indentersketch}]{%
\includegraphics[width=\linewidth]{abaqus_indenterSketch.png}}\\
\subfloat[\label{indenterpart}]{%
\includegraphics[width=\linewidth]{abaqus_indenterPart.png}}\\
\caption{The indenter in Abaqus: \textbf{(a)} the 2D axisymmetric sketch; and \textbf{(b)} the rigid surface part. \label{abaqusindenter}}
\end{figure}
Next, we assign a surface to the indenter \texttt{part} for contact modelling later on:
\begin{lstlisting}[language=apython, numbers=none]
# indenter to surface
p = myModel.parts['indenter']
s = p.faces
side2Faces = s.getSequenceFromMask(mask=('[#3 ]', ), )
p.Surface(side1Faces=side2Faces, name='indenter')
\end{lstlisting}
and we assign the indenter's reference point to a set for easy future reference:
\begin{lstlisting}[language=apython, numbers=none]
p = myModel.parts['indenter']
r = p.referencePoints
refPoints=(r[2], )
p.Set(referencePoints=refPoints, name='indenterRP')
\end{lstlisting}
\noindent Note that the indenter is not yet at it's correct position: it is oriented in the \texttt{(0, 1, 0)}-direction with the tip at \texttt{(0, 0, 0)} (figure \ref{abaqusindenter}). Positioning af the indenter \texttt{part} relative to the leg part will be done later when we `instance' the model.
\subsection{The `assist-disc'}
The `assist-disc' has no role at all in the actual simulation and is only used during the building of the model. In the assembly of the model, the edges of the (repositioned) assist-disc are projected onto the skin surface. The contour of that projection will be used to define the area on the skin that is modelled with contact boundary conditions.
The size of the assist-disc scales with the size of the indenter (\texttt{param.ri}, since \bas{buildFEM} does the book-keeping). The assist-disc gets an inner radius of 4\,\texttt{param.ri} and an outer radius of 4.5\,\texttt{param.ri}. It is represented in the 2D sketch as a line at a `height' of \texttt{y = 1\,param.ri}:
\begin{lstlisting}[language=apython, numbers=none]
# assist disc to help partitioning of skin for contact
myModel.Part(name='assistDisc', dimensionality=THREE_D, type=ANALYTIC_RIGID_SURFACE)
s1 = myModel.ConstrainedSketch(name='discSketch', sheetSize=10.0)
s1.Line(point1=(6.0, 1.500000), point2=(6.8, 1.500000))
s1.ConstructionLine(point1=(0.0, -1.5), point2=(0.0, 0.0))
p = myModel.parts['assistDisc']
p.AnalyticRigidSurfRevolve(sketch=s1)
p.ReferencePoint(point=(0, 0, 0))
\end{lstlisting}
\noindent The assis disc is not assigned any properties. It will affect the simulation only by the appearance of a warning in your \texttt{basil<basilid>.dat\index{basil<basilid>.dat@\texttt{basil<basilid>.dat}}}-file:
\begin{lstlisting}[numbers=none]
***WARNING: NODE SET ASSEMBLY_ASSISTDISC-1_ASSISTDISC-1-REFPT_ HAS NO MEMBERS
AND WILL BE IGNORED. NODES DEFINED IN THIS SET MAY HAVE BEEN
DELETED BECAUSE THEY WERE NOT CONNECTED TO ANY ELEMENTS.
\end{lstlisting}
\subsection{Assemble the parts}
We are now going to assemble model: collect the three parts (leg, indenter and assist-disc) and position them relative to each other. A \texttt{part} that is imported into the \texttt{assembly} is called an \texttt{instance}, in Abaqus:
\begin{lstlisting}[language=apython, numbers=none]
# assemble
import assembly
a1 = myModel.rootAssembly
a1.DatumCsysByDefault(CARTESIAN)
p = myModel.parts['leg']
a1.Instance(name='leg-1', part=p, dependent=OFF)
\end{lstlisting}
The leg is positioned (instanced) `as is'. The indenter needs to be rotated and translated to the correct position:
\begin{lstlisting}[language=apython]
p = myModel.parts['indenter']
a1.Instance(name='indenter-1', part=p, dependent=OFF)
# position indenter
a1 = myModel.rootAssembly
# rotate indenter to align with z-axis (instead of y)
a1.rotate(instanceList=('indenter-1', ), axisPoint=(0.0, 0.0, 0.0), axisDirection=(1, 0, 0), angle=90)
# rotate indenter to final orientation
a1.rotate(instanceList=('indenter-1', ), axisPoint=(0.0, 0.0, 0.0), axisDirection=(-0.930502, 0.291364, 0.000000), angle=98.401170)
# translate indenter to correct initial position
a1 = myModel.rootAssembly
a1.translate(instanceList=('indenter-1', ), vector=(-4.811105, -5.031821, 0.552060))
\end{lstlisting}
The indenter is first rotated from \texttt{(0, 1, 0)} to \texttt{(0, 0, 1)} (line \texttt{6}). Next, \bas{buildFEM} does the book-keeping to rotate the indenter to the correct orientation from \texttt{(0, 0, 1)} (line \texttt{8}); and to translate it to the correct position for indentation (line \texttt{11}). Note that \bas{buildFEM} uses the rotation matrix stored in \texttt{Indenter\_tipNR.txt\index{Indenter\_tipNR.txt@\texttt{Indenter\_tipNR.txt}}} and the \gibbon-function \gib{rot2VecAngle} to calculate the \texttt{AxisDirection} and \texttt{angle} for the \texttt{rotate}-command for Abaqus (lines \texttt{6} and \texttt{8}).
The orientation of the assist-disc depends on the local curvature of the leg close to the indenter. The function \bas{buildFEM} looks for the point in the skin contour definition that is closest to the indenter tip start position. It then finds the closest point on the same contour, and the closest point on an adjacent contour. With these three points, \bas{buildFEM} estimates the local normal vector of the leg underneath the indenter. The assist-disc is therefore positioned 'parallel to the skin':
\begin{lstlisting}[language=apython, numbers=none]
# instance and position assist disc
a1 = myModel.rootAssembly
p = myModel.parts['assistDisc']
a1.Instance(name='assistDisc-1', part=p, dependent=OFF)
# rotate wire to align with z-axis (instead of y)
a1.rotate(instanceList=('assistDisc-1', ), axisPoint=(0.0, 0.0, 0.0), axisDirection=(1, 0, 0), angle=90)
# rotate wire to final orientation
a1.rotate(instanceList=('assistDisc-1', ), axisPoint=(0.0, 0.0, 0.0), axisDirection=(0.934263, -0.356583, 0.000000), angle=89.561412)
# translate wire to correct initial position
a1 = myModel.rootAssembly
a1.translate(instanceList=('assistDisc-1', ), vector=(-4.811105, -5.031821, 0.552060))
\end{lstlisting}
The translation vector (last line) is the same as that for the indenter. However, because we sketched the assist-disc at \texttt{y = 1\,param.ri}, the centre of the disc will not end up at the tip of the indenter, but one indenter radius `higher' instead.\\
\noindent If you run the main \texttt{basil<basilid>\-\_job\-.py\index{basil<basilid>\_job.py@\texttt{basil<basilid>\_job.py}}}-script up until this point, Abaqus should display something like figure \eqref{abaqus_assemblyNoCast}.
\begin{figure}[h!]
\subfloat[\label{abaqus_assemblyNoCastDefault}]{%
\includegraphics[width=\linewidth]{abaqus_assemblyNoCastDefault.png}}\\
\subfloat[\label{abaqus_assemblyNoCastRot}]{%
\includegraphics[width=\linewidth]{abaqus_assemblyNoCastRot.png}}
\caption{The model assembled in Abaqus. The yellow lines are the symmetry axis af the indenter and assist-disc (construction lines in the sketches), RP's are the reference points for the indenter and bone. With \textbf{(a)} the default view with the indenter hidden behind the leg; and \textbf{(b)} a rotated view. \label{abaqus_assemblyNoCast}}
\end{figure}
......@@ -39,14 +39,39 @@ morekeywords = {WireSpline,
table,
HomogeneousSolidSection,
thickness,
SectionAssigment,
SectionAssignment,
region,
sectionName,
offset,
offsetType,
offsetField,
thicknessAssignment,
mask}}
mask,
sets,
cells,
parts,
ConstrainedSketch,
ArcByCenterEnds,
center,
direction,,
point1,
point2,
Line,
ConstructionLine,
AnalyticRigidSurfRevolve,
sketch,
point,
sheetSize,
Surface,
rootAssembly,
Instance,
rotate,
instanceList,
vector,
axisPoint,
axisDirection,
DatumCsysByDefault,
dependent}}
\lst@definelanguage{basillab}
{alsolanguage = Octave,
keywordsprefix = {bas_},
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment