102 vec [ i ] += m(i, i) * u [ i ];
169 if ( nMethod == NULL ) {
170 OOFEM_ERROR(
"linear solver creation failed for lstype %d", solverType);
180 resetEquationNumberings();
189 Domain *domain = this->giveDomain(
id);
190 TimeStep *currStep = this->giveCurrentStep();
192 this->domainNeqs.at(
id) = 0;
193 this->domainPrescribedNeqs.at(
id) = 0;
197 for (
Dof *jDof: *dman ) {
199 if ( ( type == V_u ) || ( type == V_v ) || ( type == V_w ) ) {
200 jDof->askNewEquationNumber(currStep);
206 pns.init(domain, currStep);
209 return domainNeqs.at(
id);
232 alphaShapeCoef = 1.0;
244 particleRemovalRatio = 0.0;
249 printVolumeReport = ( val == 1 );
266 if ( mode == VM_Intermediate ) {
267 if ( AuxVelocity.isNotEmpty() ) {
268 int index = avns.giveDofEquationNumber(dof);
269 if ( index > 0 && index <= AuxVelocity.giveSize() ) {
270 return AuxVelocity.at(index);
278 if ( this->requiresUnknownsDictionaryUpdate() ) {
279 int hash = this->giveUnknownDictHashIndx(mode, tStep);
296 if ( !stepWhenIcApply ) {
297 stepWhenIcApply.reset(
new TimeStep(giveNumberOfTimeStepWhenIcApply(),
this, 0, 0.0, deltaT, 0) );
300 return stepWhenIcApply.get();
306 Domain *domain = this->giveDomain(1);
319 element->checkConsistency();
321 for (
int j = 1; j <= element->giveNumberOfDofManagers(); j++ ) {
322 dynamic_cast< PFEMParticle *
>( element->giveDofManager(j) )->setFree(
false);
330 for (
Dof *jDof: *dman ) {
332 if ( ( type == V_u ) || ( type == V_v ) || ( type == V_w ) ) {
333 if ( jDof->giveBcId() ) {
334 dynamic_cast< PFEMParticle *
>( dman.get() )->setFree(
false);
345 int istep = this->giveNumberOfFirstStep();
346 double totalTime = 0;
348 Domain *domain = this->giveDomain(1);
350 if ( !currentStep ) {
352 currentStep.reset(
new TimeStep( * giveSolutionStepWhenIcApply() ) );
354 istep = currentStep->giveNumber() + 1;
355 counter = currentStep->giveSolutionStateCounter() + 1;
358 previousStep = std :: move(currentStep);
364 double ndt =
dynamic_cast< PFEMElement *
>( domain->
giveElement(1) )->computeCriticalTimeStep( previousStep.get() );
376 ndt =
min(ndt, deltaT);
378 totalTime = previousStep->giveTargetTime() + ndt;
380 currentStep.reset(
new TimeStep(istep,
this, 1, totalTime, ndt, counter) );
383 OOFEM_LOG_INFO(
"SolutionStep %d : t = %e, dt = %e\n", istep, totalTime * this->giveVariableScale(
VST_Time), ndt * this->giveVariableScale(
VST_Time) );
384 if ( printVolumeReport ) {
385 OOFEM_LOG_INFO(
"Volume leakage: %.3f%%\n", ( 1.0 - ( volume / domainVolume ) ) * 100.0);
388 return currentStep.get();
394 int auxmomneq = this->giveNumberOfDomainEquations(1, avns);
395 int momneq = this->giveNumberOfDomainEquations(1, vns);
396 int presneq = this->giveNumberOfDomainEquations(1, pns);
403 double d_pnorm = 1.0;
404 double d_vnorm = 1.0;
406 AuxVelocity.resize(auxmomneq);
409 avLhs.resize(auxmomneq);
415 OOFEM_ERROR(
"solveYourselfAt: sparse matrix creation failed");
418 pLhs->buildInternalStructure(
this, 1, pns);
431 if ( tStep->
giveNumber() == giveNumberOfFirstStep() ) {
433 this->applyIC(stepWhenIcApply);
436 if ( VelocityField.giveActualStepNumber() < tStep->
giveNumber() ) {
437 VelocityField.advanceSolution(tStep);
440 if ( PressureField.giveActualStepNumber() < tStep->
giveNumber() ) {
441 PressureField.advanceSolution(tStep);
444 FloatArray *velocityVector = VelocityField.giveSolutionVector(tStep);
445 FloatArray *pressureVector = PressureField.giveSolutionVector(tStep);
447 FloatArray velocityVectorThisStep(* velocityVector);
448 FloatArray velocityVectorLastStep(* velocityVector);
450 FloatArray pressureVectorThisStep(* pressureVector);
451 FloatArray pressureVectorLastStep(* pressureVector);
454 for (
int i = 1; i <= this->giveDomain(1)->giveNumberOfDofManagers(); i++ ) {
455 this->updateDofUnknownsDictionary(this->giveDomain(1)->giveDofManager(i), tStep);
460 externalForces.
resize(auxmomneq);
461 this->assembleVector( externalForces, tStep,
ExternalForceAssembler(), VM_Total, avns, this->giveDomain(1) );
467 velocityVectorLastStep = velocityVectorThisStep;
468 pressureVectorLastStep = pressureVectorThisStep;
475 if ( discretizationScheme == 1 ) {
476 if ( iteration > 1 ) {
479 }
else if ( discretizationScheme == 0 ) {
486 rhs.
add(externalForces);
501 AuxVelocity.resize( rhs.
giveSize() );
502 for (
int i = 1; i <= auxmomneq; i++ ) {
503 AuxVelocity.at(i) = rhs.
at(i) / avLhs.at(i);
514 pressureVector->
resize(presneq);
515 nMethod->solve(* pLhs, rhs, * pressureVector);
517 for (
auto &dman : this->giveDomain(1)->giveDofManagers() ) {
518 this->updateDofUnknownsDictionaryPressure(dman.get(), tStep);
527 velocityVector->
resize(momneq);
534 for (
int i = 1; i <= momneq; i++ ) {
535 velocityVector->
at(i) = rhs.
at(i) / vLhs.at(i);
538 for (
int i = 1; i <= this->giveDomain(1)->giveNumberOfDofManagers(); i++ ) {
540 this->updateDofUnknownsDictionaryVelocities(particle, tStep);
543 velocityVectorThisStep = * velocityVector;
544 pressureVectorThisStep = * pressureVector;
546 if ( iteration == 1 ) {
550 FloatArray diffVelocity = velocityVectorThisStep;
551 diffVelocity.
subtract(velocityVectorLastStep);
554 for (
int i = 1; i <= diffVelocity.
giveSize(); i++ ) {
555 d_vnorm =
max(d_vnorm, fabs( diffVelocity.
at(i) ) > 1.e-6 ? fabs( diffVelocity.
at(i) / velocityVectorLastStep.
at(i) ) : 0);
558 FloatArray diffPressure = pressureVectorThisStep;
559 diffPressure.
subtract(pressureVectorLastStep);
561 for (
int i = 1; i <= diffPressure.
giveSize(); i++ ) {
563 d_pnorm =
max(d_pnorm, fabs( diffPressure.
at(i) ) > 1.e-6 ? fabs( diffPressure.
at(i) / pressureVectorLastStep.
at(i) ) : 0);
566 }
while ( discretizationScheme == 1 && ( d_vnorm > rtolv || d_pnorm > rtolp ) && iteration < maxiter );
568 if ( iteration > maxiter ) {
576 Domain *d = this->giveDomain(1);
581 for (
Dof *dof : *particle ) {
583 if ( type == V_u || type == V_v || type == V_w ) {
584 int eqnum = dof->giveEquationNumber(vns);
586 double previousValue = dof->giveUnknown( VM_Total, tStep->
givePreviousStep() );
590 previousValue += gVector [ type - V_w ] * deltaT;
591 velocityVector->
at(eqnum) = previousValue;
604 this->updateInternalState(stepN);
607 this->deactivateTooCloseParticles();
615 for (
auto &domain : this->domainList ) {
616 if ( requiresUnknownsDictionaryUpdate() ) {
617 for (
auto &dman : domain->giveDofManagers() ) {
618 this->updateDofUnknownsDictionary(dman.get(), stepN);
622 for (
auto &elem : domain->giveElements() ) {
623 elem->updateInternalState(stepN);
631 if ( ( stepN == this->giveCurrentStep() ) || ( stepN == this->givePreviousStep() ) ) {
632 int index = ( stepN->
giveNumber() % 2 ) * 100 + mode;
635 OOFEM_ERROR(
"giveUnknownDictHashIndx: unsupported solution step");
644 for (
Dof *iDof: *inode ) {
647 if ( iDof->hasBc(tStep) ) {
648 val = iDof->giveBcValue(VM_Total, tStep);
650 if ( iDof->giveDofID() == P_f ) {
651 eqNum = pns.giveDofEquationNumber(iDof);
652 FloatArray *vect = PressureField.giveSolutionVector(tStep);
654 val = vect->
at(eqNum);
657 eqNum = iDof->__giveEquationNumber();
658 FloatArray *vect = VelocityField.giveSolutionVector(tStep);
660 val = vect->
at(eqNum);
665 iDof->updateUnknownsDictionary(tStep, VM_Total, val);
674 if ( iDof->
hasBc(tStep) ) {
677 int eqNum = pns.giveDofEquationNumber(iDof);
678 FloatArray *vect = PressureField.giveSolutionVector(tStep);
679 val = vect->
at(eqNum);
688 for (
Dof *iDof : *inode ) {
690 if ( type == V_u || type == V_v || type == V_w ) {
693 if ( iDof->hasBc(tStep) ) {
694 val = iDof->giveBcValue(VM_Total, tStep);
696 eqNum = iDof->__giveEquationNumber();
697 FloatArray *vect = VelocityField.giveSolutionVector(tStep);
699 val = vect->
at(eqNum);
702 iDof->updateUnknownsDictionary(tStep, VM_Total, val);
718 if ( ( iores = PressureField.saveContext(stream, mode) ) !=
CIO_OK ) {
722 if ( ( iores = VelocityField.saveContext(stream, mode) ) !=
CIO_OK ) {
740 if ( ( iores = PressureField.restoreContext(stream, mode) ) !=
CIO_OK ) {
744 if ( ( iores = VelocityField.restoreContext(stream, mode) ) !=
CIO_OK ) {
755 Domain *domain = this->giveDomain(1);
759 if ( !dynamic_cast< PFEMElement * >( elem.get() ) ) {
760 OOFEM_WARNING(
"Element %d has no PFEM base", elem->giveLabel() );
773 if ( ( type == V_u ) || ( type == V_v ) || ( type == V_w ) ) {
779 double coordinate = 0.0;
782 case V_u: dofNumber = 1;
784 case V_v: dofNumber = 2;
786 case V_w: dofNumber = 3;
791 fprintf(stream,
" dof %d c % .8e\n", dofNumber, coordinate);
792 }
else if ( ( type == P_f ) ) {
795 OOFEM_ERROR(
"printDofOutputAt: unsupported dof type");
802 Domain *domain = this->giveDomain(1);
803 int mbneq = this->giveNumberOfDomainEquations(1, vns);
804 int pdneq = this->giveNumberOfDomainEquations(1, pns);
811 int velocityFieldStepNumber = VelocityField.giveActualStepNumber();
813 if ( velocityFieldStepNumber < stepWhenIcApply->giveNumber() ) {
814 VelocityField.advanceSolution(stepWhenIcApply);
816 velocityVector = VelocityField.giveSolutionVector(stepWhenIcApply);
817 velocityVector->
resize(mbneq);
818 velocityVector->
zero();
820 int pressureFieldStepNumber = PressureField.giveActualStepNumber();
821 if ( pressureFieldStepNumber < stepWhenIcApply->giveNumber() ) {
822 PressureField.advanceSolution(stepWhenIcApply);
824 pressureVector = PressureField.giveSolutionVector(stepWhenIcApply);
825 pressureVector->
resize(pdneq);
826 pressureVector->
zero();
834 if ( !iDof->isPrimaryDof() ) {
838 int jj = iDof->__giveEquationNumber();
842 if ( ( type == V_u ) || ( type == V_v ) || ( type == V_w ) ) {
843 velocityVector->
at(jj) = iDof->giveUnknown(VM_Total, stepWhenIcApply);
845 pressureVector->
at(jj) = iDof->giveUnknown(VM_Total, stepWhenIcApply);
863 if ( (
id == V_u ) || (
id == V_v ) || (
id == V_w ) ) {
864 return this->vns.askNewEquationNumber();
866 OOFEM_ERROR(
"giveNewEquationNumber:: Unknown DofIDItem");
875 if ( (
id == V_u ) || (
id == V_v ) || (
id == V_w ) ) {
876 return prescribedVns.askNewEquationNumber();
878 OOFEM_ERROR(
"giveNewPrescribedEquationNumber:: Unknown DofIDItem");
891 if ( !equationNumberingCompleted ) {
903 prescribedVns.reset();
911 Domain *d = this->giveDomain(1);
913 if ( particleRemovalRatio > 1.e-6 ) {
925 double maxLength =
max( l12,
max(l23, l31) );
926 double minLength =
min( l12,
min(l23, l31) );
928 if ( minLength / maxLength < particleRemovalRatio ) {
929 if ( fabs(l12 - minLength) < 1.e-6 ) {
931 bool isSupported =
false;
933 for (
Dof *jDof: *particle1 ) {
935 if ( ( type == V_u ) || ( type == V_v ) || ( type == V_w ) ) {
936 if ( jDof->giveBcId() ) {
941 if ( isSupported ==
false ) {
942 particle1->deactivate();
946 }
else if ( particle1->
isActive() ==
false || particle2->
isActive() == false ) {
953 if ( fabs(l23 - minLength) < 1.e-6 ) {
955 bool isSupported =
false;
957 for (
Dof *jDof : *particle2 ) {
959 if ( ( type == V_u ) || ( type == V_v ) || ( type == V_w ) ) {
960 if ( jDof->giveBcId() ) {
965 if ( isSupported ==
false ) {
966 particle2->deactivate();
970 }
else if ( particle2->
isActive() ==
false || particle3->
isActive() == false ) {
977 if ( fabs(l31 - minLength) < 1.e-6 ) {
979 bool isSupported =
false;
980 for (
Dof *jDof : *particle3 ) {
982 if ( ( type == V_u ) || ( type == V_v ) || ( type == V_w ) ) {
983 if ( jDof->giveBcId() ) {
988 if ( isSupported ==
false ) {
989 particle3->deactivate();
993 }
else if ( particle3->
isActive() ==
false || particle1->
isActive() == false ) {
LinSystSolverType
The values of this type should be related not to specific solvers, but more to specific packages that...
int giveNumberOfColumns() const
Returns number of columns of receiver.
void updateDofUnknownsDictionaryPressure(DofManager *inode, TimeStep *tStep)
Writes pressures into the dof unknown dictionaries.
void subtract(const FloatArray &src)
Subtracts array src to receiver.
Implementation of callback class for assembling right-hand side vector of laplacian multiplied by vel...
Implementation of callback class for assembling right-hand side of velocity equations.
#define _IFT_PFEM_maxiter
virtual void computeDiagonalMassMtrx(FloatArray &answer, TimeStep *)=0
Calculates diagonal mass matrix as vector.
virtual void locationFromElement(IntArray &loc, Element &element, const UnknownNumberingScheme &s, IntArray *dofIds=nullptr) const
Default implementation takes all the DOF IDs.
This class is the implementation of triangular PFEM element with linear (and equal order) interpolati...
void computeVectorOf(ValueModeType u, TimeStep *tStep, FloatArray &answer)
Returns local vector of unknowns.
#define _IFT_PFEM_discretizationScheme
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description in input reader.
virtual contextIOResultType saveContext(DataStream &stream, ContextMode mode)
Stores the state of model to output stream.
SparseMtrx * createSparseMtrx(SparseMtrxType type)
Creates new instance of sparse matrix corresponding to given keyword.
virtual void vectorFromElement(FloatArray &vec, Element &element, TimeStep *tStep, ValueModeType mode) const
void resetEquationNumberings()
Resets the equation numberings as the mesh is recreated in each time step.
The purpose of DataStream abstract class is to allow to store/restore context to different streams...
void updateDofUnknownsDictionaryVelocities(DofManager *inode, TimeStep *tStep)
Writes velocities into the dof unknown dictionaries.
virtual int giveNumberOfDomainEquations(int, const UnknownNumberingScheme &num)
Returns number of equations for given domain in active (current time step) time step.
Callback class for assembling pressure laplacian matrix.
double & at(int i)
Coefficient access function.
int max(int i, int j)
Returns bigger value form two given decimals.
ValueModeType
Type representing the mode of UnknownType or CharType, or similar types.
long StateCounterType
StateCounterType type used to indicate solution state.
TimeStep * giveNextStep()
Returns next time step (next to current step) of receiver.
This base class is an abstraction for numerical algorithm.
virtual bool isFree()
Returns the free-propery flag.
void solveYourselfAt(TimeStep *)
Solves problem for given time step.
#define _IFT_PFEM_particalRemovalRatio
virtual void computePrescribedRhsVector(FloatArray &answer, TimeStep *tStep, ValueModeType mode)=0
Calculates the prescribed velocity vector for the right hand side of the pressure equation...
virtual void updateYourself(TimeStep *tStep)
Updates element state after equilibrium in time step has been reached.
virtual int giveUnknownDictHashIndx(ValueModeType mode, TimeStep *stepN)
This method is responsible for computing unique dictionary id (ie hash value) from given valueModeTyp...
void incrementStateCounter()
Updates solution state counter.
Implementation of callback class for assembling right-hand side of pressure equations.
Abstract base class for all finite elements.
virtual void updateInternalState(TimeStep *tStep)
Updates element state after equilibrium in time step has been reached.
void generateMesh()
Main call.
Base class for dof managers.
std::vector< std::unique_ptr< DofManager > > & giveDofManagers()
int giveNumberOfElements() const
Returns number of elements in domain.
virtual void computeComponentArrayAt(FloatArray &answer, TimeStep *tStep, ValueModeType mode)
Computes boundary condition value - its components values at given time.
virtual bool isActive()
Returns the activeFlag.
REGISTER_EngngModel(ProblemSequence)
Class implementing an array of integers.
virtual void computePressureLaplacianMatrix(FloatMatrix &answer, TimeStep *atTime)=0
Calculates the pressure laplacian matrix.
void giveCharacteristicMatrix(FloatMatrix &answer, CharType, TimeStep *)
Computes characteristic matrix of receiver of requested type in given time step.
virtual void giveUnknowns(FloatArray &masterUnknowns, ValueModeType mode, TimeStep *tStep)
The key method of class Dof.
IRResultType initializeFrom(InputRecord *ir)
Initialization from given input record.
virtual void preInitializeNextStep()
Removes all elements and call DelaunayTriangulator to build up new mesh with new recognized boundary...
virtual void vectorFromElement(FloatArray &vec, Element &element, TimeStep *tStep, ValueModeType mode) const
void updateInternalState(TimeStep *)
Updates nodal values (calls also this->updateDofUnknownsDictionary for updating dofs unknowns diction...
This abstract class represent a general base element class for fluid dynamic problems solved using PF...
Implementation of callback class for assembling right-hand side vector of mass matrix multiplied by v...
double giveUnknownComponent(ValueModeType mode, TimeStep *tStep, Domain *d, Dof *dof)
Returns requested unknown.
double giveTimeIncrement()
Returns solution step associated time increment.
bool isTheFirstStep()
Check if receiver is first step.
virtual void computeGradientMatrix(FloatMatrix &answer, TimeStep *atTime)=0
Calculates the pressure gradient matrix.
double distance(const FloatArray &x) const
Computes the distance between position represented by receiver and position given as parameter...
virtual void computeVectorOfPressures(ValueModeType mode, TimeStep *tStep, FloatArray &pressures)
#define VERBOSE_PRINTS(str, str1)
virtual void matrixFromElement(FloatMatrix &mat, Element &element, TimeStep *tStep) const
void applyIC(TimeStep *)
Initializes velocity and pressure fields in the first step with prescribed values.
int giveNumber()
Returns receiver's number.
#define OOFEM_LOG_INFO(...)
Element * giveElement(int n)
Service for accessing particular domain fe element.
NumericalMethod * giveNumericalMethod(MetaStep *)
Returns reference to receiver's numerical method.
virtual void computeVectorOfVelocities(ValueModeType mode, TimeStep *tStep, FloatArray &velocities)
#define _IFT_EngngModel_smtype
DofIDItem
Type representing particular dof type.
virtual void updateUnknownsDictionary(TimeStep *tStep, ValueModeType mode, double dofValue)
Abstract function, allowing Dof to store its unknowns in its own private dictionary.
SparseMtrxType
Enumerative type used to identify the sparse matrix type.
TimeStep * giveSolutionStepWhenIcApply()
Implementation for assembling external forces vectors in standard monolithic FE-problems.
void giveLocationArray(IntArray &locationArray, const UnknownNumberingScheme &s, IntArray *dofIds=NULL) const
Returns the location array (array of code numbers) of receiver for given numbering scheme...
Abstract base class allowing to control the way, how equations are assigned to individual DOFs...
virtual void updateYourself(TimeStep *tStep)
Updates internal state after finishing time step.
DofIDItem giveDofID() const
Returns DofID value of receiver, which determines type of of unknown connected to receiver (e...
virtual void vectorFromElement(FloatArray &vec, Element &element, TimeStep *tStep, ValueModeType mode) const
virtual void updateYourself(TimeStep *tStep)
Updates nodal values (calls also this->updateDofUnknownsDictionary for updating dofs unknowns diction...
void beProductOf(const FloatMatrix &aMatrix, const FloatArray &anArray)
Receiver becomes the result of the product of aMatrix and anArray.
#define _IFT_PFEM_associatedMaterial
TimeStep * givePreviousStep()
Returns pointer to previous solution step.
virtual contextIOResultType restoreContext(DataStream &stream, ContextMode mode)
Restores the state of model from output stream.
virtual void vectorFromElement(FloatArray &vec, Element &element, TimeStep *tStep, ValueModeType mode) const
void clearElements()
Clear all elements.
virtual contextIOResultType saveContext(DataStream &stream, ContextMode mode)
Stores the state of model to output stream.
virtual int forceEquationNumbering()
Forces equation renumbering on all domains associated to engng model.
Initializes the variable VERBOSE, in order to get a few intermediate messages on screen: beginning an...
virtual void locationFromElement(IntArray &loc, Element &element, const UnknownNumberingScheme &s, IntArray *dofIds=nullptr) const
Default implementation takes all the DOF IDs.
#define _IFT_PFEM_printVolumeReport
Class representing vector of real numbers.
SparseLinearSystemNM * createSparseLinSolver(LinSystSolverType st, Domain *d, EngngModel *m)
Creates new instance of SparseLinearSystemNM corresponding to given type.
virtual double computeCriticalTimeStep(TimeStep *tStep)
Calculates critical time step.
virtual int checkConsistency()
Allows programmer to test some receiver's internal data, before computation begins.
virtual void updateDofUnknownsDictionary(DofManager *inode, TimeStep *tStep)
Updates necessary values in Dofs unknown dictionaries.
Implementation of matrix containing floating point numbers.
#define _IFT_EngngModel_lstype
IRResultType
Type defining the return values of InputRecord reading operations.
virtual int giveRequiredNumberOfDomainEquation() const
Returns required number of domain equation.
#define _IFT_PFEM_mindeltat
virtual double computeArea()
Computes the area (zero for all but 2d geometries).
Implementation for assembling lumped mass matrix (diagonal components) in vector form.
virtual void deactivate()
Sets the activeFlag to false.
void assemble(const FloatArray &fe, const IntArray &loc)
Assembles the array fe (typically, the load vector of a finite element) into the receiver, using loc as location array.
int giveMetaStepNumber()
Returns receiver's meta step number.
double computeNorm() const
Computes the norm (or length) of the vector.
virtual int checkConsistency()
Allows programmer to test some receiver's internal data, before computation begins.
#define _IFT_PFEM_alphashapecoef
virtual void printDofOutputAt(FILE *stream, Dof *iDof, TimeStep *atTime)
DOF printing routine.
virtual void locationFromElement(IntArray &loc, Element &element, const UnknownNumberingScheme &s, IntArray *dofIds=nullptr) const
Dof * giveDofWithID(int dofID) const
Returns DOF with given dofID; issues error if not present.
virtual double giveBcValue(ValueModeType mode, TimeStep *tStep)
Returns value of boundary condition of dof if it is prescribed.
void zero()
Zeroes all coefficients of receiver.
virtual void setFree(bool newFlag=true)
Sets the free-property flag.
virtual void computeStiffnessMatrix(FloatMatrix &answer, MatResponseMode mode, TimeStep *atTime)=0
Calculates the stiffness matrix.
void times(double s)
Multiplies receiver with scalar.
#define _IFT_PFEM_associatedCrossSection
virtual const IntArray & givePressureDofMask() const =0
Returns mask of pressure Dofs.
ClassFactory & classFactory
long ContextMode
Context mode (mask), defining the type of information written/read to/from context.
virtual FloatArray * giveCoordinates()
virtual bool hasBc(TimeStep *tStep)=0
Test if Dof has active boundary condition.
Mesh generator for the PFEM problem, using Bowyer-Watson algorithm of the Delaunay triangulation of a...
Particle class being used in PFEM computations.
int min(int i, int j)
Returns smaller value from two given decimals.
std::vector< std::unique_ptr< Element > > & giveElements()
virtual int giveNewEquationNumber(int domain, DofIDItem)
Increases number of equations of receiver's domain and returns newly created equation number...
Load is base abstract class for all loads.
DofManager * giveDofManager() const
int giveSize() const
Returns the size of receiver.
virtual double giveCoordinate(int i)
virtual contextIOResultType restoreContext(DataStream &stream, ContextMode mode)
Restores the state of model from output stream.
the oofem namespace is to define a context or scope in which all oofem names are defined.
Abstract class Dof represents Degree Of Freedom in finite element mesh.
void negated()
Switches the sign of every coefficient of receiver.
Node * giveNode(int i) const
Returns reference to the i-th node of element.
Load * giveLoad(int n)
Service for accessing particular domain load.
virtual void locationFromElement(IntArray &loc, Element &element, const UnknownNumberingScheme &s, IntArray *dofIds=nullptr) const
Default implementation takes all the DOF IDs.
#define OOFEM_WARNING(...)
#define _IFT_PFEM_pressureBC
Class representing solution step.
void add(const FloatArray &src)
Adds array src to receiver.
virtual void printSingleOutputAt(FILE *file, TimeStep *tStep, char ch, ValueModeType mode, double scale=1.0)
Prints Dof output (it prints value of unknown related to dof at given timeStep).
virtual int giveNewPrescribedEquationNumber(int domain, DofIDItem)
Increases number of prescribed equations of receiver's domain and returns newly created equation numb...
const char * __ValueModeTypeToString(ValueModeType _value)
void resize(int s)
Resizes receiver towards requested size.
void deactivateTooCloseParticles()
Deactivates particles upon the particalRemovalRatio.