|
OOFEM 3.0
|
#include <surfacetensionbc.h>
Public Member Functions | |
| SurfaceTensionBoundaryCondition (int n, Domain *d) | |
| virtual | ~SurfaceTensionBoundaryCondition () |
| Destructor. | |
| void | initializeFrom (InputRecord &ir) override |
| void | assemble (SparseMtrx &answer, TimeStep *tStep, CharType type, const UnknownNumberingScheme &r_s, const UnknownNumberingScheme &c_s, double scale=1.0, void *lock=nullptr) override |
| void | assembleVector (FloatArray &answer, TimeStep *tStep, CharType type, ValueModeType mode, const UnknownNumberingScheme &s, FloatArray *eNorms=nullptr, void *lock=nullptr) override |
| void | giveLocationArrays (std ::vector< IntArray > &rows, std ::vector< IntArray > &cols, CharType type, const UnknownNumberingScheme &r_s, const UnknownNumberingScheme &c_s) override |
| const char * | giveClassName () const override |
| const char * | giveInputRecordName () const override |
| Public Member Functions inherited from oofem::ActiveBoundaryCondition | |
| ActiveBoundaryCondition (int n, Domain *d) | |
| virtual | ~ActiveBoundaryCondition () |
| Destructor. | |
| virtual void | addElementSide (int elem, int side) |
| virtual bool | requiresActiveDofs () |
| virtual bool | isPrimaryDof (ActiveDof *dof) |
| virtual double | giveBcValue (Dof *dof, ValueModeType mode, TimeStep *tStep) |
| virtual bool | hasBc (Dof *dof, TimeStep *tStep) |
| virtual int | giveNumberOfMasterDofs (ActiveDof *dof) |
| virtual Dof * | giveMasterDof (ActiveDof *dof, int mdof) |
| virtual void | computeDofTransformation (ActiveDof *dof, FloatArray &masterContribs) |
| virtual double | giveUnknown (PrimaryField &field, ValueModeType mode, TimeStep *tStep, ActiveDof *dof) |
| virtual double | giveUnknown (ValueModeType mode, TimeStep *tStep, ActiveDof *dof) |
| Public Member Functions inherited from oofem::GeneralBoundaryCondition | |
| GeneralBoundaryCondition (int n, Domain *d) | |
| virtual | ~GeneralBoundaryCondition () |
| Destructor. | |
| int | giveSetNumber () const |
| virtual int | giveNumberOfInternalDofManagers () |
| Gives the number of internal dof managers. | |
| virtual DofManager * | giveInternalDofManager (int i) |
| Gives an internal dof manager from receiver. | |
| Function * | giveTimeFunction () |
| int | getIsImposedTimeFunctionNumber () const |
| void | setIsImposedTimeFunctionNumber (int funcIndx) |
| virtual bcValType | giveBCValType () const |
| virtual bool | isImposed (TimeStep *tStep) |
| virtual const IntArray & | giveDofIDs () const |
| virtual bcType | giveType () const |
| virtual bcGeomType | giveBCGeoType () const |
| virtual void | scale (double s) |
| virtual double | giveProperty (int aProperty, TimeStep *tStep) const |
| void | giveInputRecord (DynamicInputRecord &input) override |
| void | saveContext (DataStream &stream, ContextMode mode) override |
| void | restoreContext (DataStream &stream, ContextMode mode) override |
| virtual void | updateYourself (TimeStep *tStep) |
| Public Member Functions inherited from oofem::FEMComponent | |
| FEMComponent (int n, Domain *d) | |
| virtual | ~FEMComponent ()=default |
| Virtual destructor. | |
| Domain * | giveDomain () const |
| virtual void | setDomain (Domain *d) |
| int | giveNumber () const |
| void | setNumber (int num) |
| virtual void | updateLocalNumbering (EntityRenumberingFunctor &f) |
| virtual void | initializeFrom (InputRecord &ir, int priority) |
| virtual void | initializeFinish () |
| virtual void | postInitialize () |
| Performs post initialization steps. Called after all components are created and initialized. | |
| virtual int | checkConsistency () |
| virtual void | printOutputAt (FILE *file, TimeStep *tStep) |
| virtual void | printYourself () |
| Prints receiver state on stdout. Useful for debugging. | |
| virtual Interface * | giveInterface (InterfaceType t) |
| std::string | errorInfo (const char *func) const |
| Returns string for prepending output (used by error reporting macros). | |
Protected Member Functions | |
| void | computeLoadVectorFromElement (FloatArray &answer, Element *e, int side, TimeStep *tStep) |
| void | computeTangentFromElement (FloatMatrix &answer, Element *e, int side, TimeStep *tStep) |
Private Attributes | |
| double | gamma |
| Surface tension. | |
| bool | useTangent |
| Determines if tangent should be used. | |
Additional Inherited Members | |
| Protected Attributes inherited from oofem::GeneralBoundaryCondition | |
| int | timeFunction |
| Associated load time function. | |
| bcValType | valType |
| Physical meaning of BC value. | |
| IntArray | dofs |
| Dofs that b.c. is applied to (relevant for Dirichlet type b.c.s). | |
| int | isImposedTimeFunction |
| int | set |
| Set number for boundary condition to be applied to. | |
| Protected Attributes inherited from oofem::FEMComponent | |
| int | number |
| Component number. | |
| Domain * | domain |
| Link to domain object, useful for communicating with other FEM components. | |
Computes the load (and possibly tangent) for surface tension. This boundary condition applicable to both solid and flow problems. Computing this load and tangent is involves some fairly complicated expression with lengthy derivations, especially for 3D surfaces.
Definition at line 57 of file surfacetensionbc.h.
|
inline |
Constructor. Creates boundary an active condition with given number, belonging to given domain.
| n | Boundary condition number. |
| d | Domain to which new object will belongs. |
Definition at line 68 of file surfacetensionbc.h.
References oofem::ActiveBoundaryCondition::ActiveBoundaryCondition().
|
inlinevirtual |
Destructor.
Definition at line 70 of file surfacetensionbc.h.
|
overridevirtual |
Assembles B.C. contributions to specified matrix.
| [in,out] | answer | Matrix to assemble to. |
| tStep | Active time step. | |
| tStep | Active time step. | |
| type | Type of matrix to assemble. | |
| r_s | Row numbering scheme. | |
| c_s | Column numbering scheme. | |
| scale | Scaling factor. | |
| omp_lock | optional OMP lock to ensure correct update of answer |
Reimplemented from oofem::ActiveBoundaryCondition.
Definition at line 96 of file surfacetensionbc.C.
References oofem::SparseMtrx::assemble(), oofem::IntArray::at(), oofem::FEInterpolation::boundaryGiveNodes(), computeTangentFromElement(), oofem::GeneralBoundaryCondition::dofs, oofem::Element::giveBoundaryLocationArray(), oofem::FEMComponent::giveDomain(), oofem::Element::giveGeometryType(), oofem::Element::giveInterpolation(), oofem::IntArray::giveSize(), OOFEM_ERROR, oofem::GeneralBoundaryCondition::scale(), oofem::GeneralBoundaryCondition::set, oofem::FloatMatrix::times(), and useTangent.
|
overridevirtual |
Assembles B.C. contributions to specified vector.
| [in,out] | answer | Vector to assemble to. |
| tStep | Active time step. | |
| type | Type of matrix to assemble. | |
| mode | Mode of value. | |
| s | Numbering scheme. | |
| eNorms | Norms for each dofid. | |
| omp_lock | optional OMP lock to ensure correct update of answer |
Reimplemented from oofem::ActiveBoundaryCondition.
Definition at line 134 of file surfacetensionbc.C.
References oofem::FloatArray::assemble(), oofem::FloatArray::assembleSquared(), oofem::IntArray::at(), oofem::FEInterpolation::boundaryGiveNodes(), computeLoadVectorFromElement(), oofem::GeneralBoundaryCondition::dofs, oofem::Element::giveBoundaryLocationArray(), oofem::FEMComponent::giveDomain(), oofem::Element::giveGeometryType(), oofem::Element::giveInterpolation(), oofem::IntArray::giveSize(), and oofem::GeneralBoundaryCondition::set.
|
protected |
Helper function for computing the contributions to the load vector.
Definition at line 283 of file surfacetensionbc.C.
References oofem::FloatArray::add(), oofem::FloatMatrix::at(), oofem::FloatArray::beProductOf(), oofem::FEInterpolation::boundaryEvalN(), oofem::FEInterpolation::boundaryEvalNormal(), oofem::FEInterpolation2d::boundaryGiveNodes(), oofem::FEInterpolation::boundaryGiveTransformationJacobian(), oofem::FEInterpolation::boundaryLocal2Global(), oofem::FloatArray::clear(), oofem::CS_Thickness, oofem::FEInterpolation2d::edgeEvaldNds(), gamma, oofem::CrossSection::give(), oofem::FEInterpolation::giveBoundaryIntegrationRule(), oofem::DofManager::giveCoordinate(), oofem::Element::giveCrossSection(), oofem::FEMComponent::giveDomain(), oofem::Element::giveGeometryType(), oofem::Element::giveInterpolation(), oofem::FEInterpolation::giveInterpolationOrder(), oofem::Element::giveNode(), oofem::FloatMatrix::giveNumberOfRows(), oofem::Domain::giveNumberOfSpatialDimensions(), oofem::IntArray::giveSize(), oofem::Domain::isAxisymmetric(), M_PI, N, OOFEM_ERROR, oofem::FloatArray::plusProduct(), oofem::FloatArray::resize(), oofem::FloatMatrix::resize(), oofem::FEInterpolation3d::surfaceEvaldNdx(), and oofem::Vec6().
Referenced by assembleVector().
|
protected |
Helper function for computing the tangent ( \( K = \frac{\mathrm{d}F}{\mathrm{d}u} \))
Definition at line 171 of file surfacetensionbc.C.
References oofem::FloatMatrix::at(), oofem::FloatArray::beProductOf(), oofem::FEInterpolation::boundaryEvalN(), oofem::FEInterpolation::boundaryEvalNormal(), oofem::FEInterpolation::boundaryGiveTransformationJacobian(), oofem::FEInterpolation::boundaryLocal2Global(), oofem::FloatMatrix::clear(), oofem::CS_Thickness, oofem::FEInterpolation2d::edgeEvaldNds(), gamma, oofem::CrossSection::give(), oofem::FEInterpolation::giveBoundaryIntegrationRule(), oofem::DofManager::giveCoordinate(), oofem::Element::giveCrossSection(), oofem::FEMComponent::giveDomain(), oofem::Element::giveGeometryType(), oofem::Element::giveInterpolation(), oofem::FEInterpolation::giveInterpolationOrder(), oofem::Element::giveNode(), oofem::Element::giveNumberOfNodes(), oofem::Domain::giveNumberOfSpatialDimensions(), oofem::Domain::isAxisymmetric(), M_PI, N, OOFEM_ERROR, OOFEM_WARNING, oofem::FloatMatrix::plusDyadSymmUpper(), oofem::FloatMatrix::plusDyadUnsym(), oofem::FloatMatrix::plusProductSymmUpper(), oofem::FloatMatrix::symmetrized(), and oofem::FloatMatrix::zero().
Referenced by assemble().
|
inlineoverridevirtual |
Implements oofem::FEMComponent.
Definition at line 86 of file surfacetensionbc.h.
|
inlineoverridevirtual |
Implements oofem::FEMComponent.
Definition at line 87 of file surfacetensionbc.h.
References _IFT_SurfaceTensionBoundaryCondition_Name.
|
overridevirtual |
Gives a list of location arrays that will be assembled. This should only be used to construct zero structure in sparse matrices. The rows and columns location arrays returned in tuples (stored in vector), allowing to efficiently assemble and allocate off-diagonal blocks. The nonzero entries are assembled and allocated for entries at (rows[i], cols[i]) positions.
| rows | List of location arrays for r_s. |
| cols | List of location arrays for c_s. |
| type | Type of matrix to assemble. |
| r_s | Row numbering scheme. |
| c_s | Column numbering scheme. |
Reimplemented from oofem::ActiveBoundaryCondition.
Definition at line 72 of file surfacetensionbc.C.
References oofem::IntArray::at(), oofem::FEInterpolation::boundaryGiveNodes(), oofem::GeneralBoundaryCondition::dofs, oofem::Element::giveBoundaryLocationArray(), oofem::FEMComponent::giveDomain(), oofem::Element::giveGeometryType(), oofem::Element::giveInterpolation(), oofem::IntArray::giveSize(), oofem::GeneralBoundaryCondition::set, and useTangent.
|
overridevirtual |
Initializes receiver according to object description stored in input record. This function is called immediately after creating object using constructor. Input record can be imagined as data record in component database belonging to receiver. Receiver may use value-name extracting functions to extract particular field from record. Note that initializeFrom may be called mutiple times.
| ir | Input record to initialize from. |
| priority | Priority of the input record. This is used to determine the order of initialization |
Reimplemented from oofem::ActiveBoundaryCondition.
Definition at line 63 of file surfacetensionbc.C.
References _IFT_SurfaceTensionBoundaryCondition_gamma, _IFT_SurfaceTensionBoundaryCondition_useTangent, gamma, oofem::InputRecord::hasField(), IR_GIVE_FIELD, and useTangent.
|
private |
Surface tension.
Definition at line 59 of file surfacetensionbc.h.
Referenced by computeLoadVectorFromElement(), computeTangentFromElement(), and initializeFrom().
|
private |
Determines if tangent should be used.
Definition at line 60 of file surfacetensionbc.h.
Referenced by assemble(), giveLocationArrays(), and initializeFrom().