SolidBeamDemo.cpp File Reference

Functions

int main ()
 [SolidBeamDemo] More...
 

Function Documentation

◆ main()

int main ( )

[SolidBeamDemo]

Simulates a cubic rod (20mm x 2mm x 2mm) of density 2500 kg/m^3, elastic modulus 100 MPa, fixed on left side, bent by gravity

13 {
14  // Defines a SolidProblem of element type RefineableQDPVDElement<3,2>.
16  // Sets up the problem
17  problem.setName("SolidBeamUnitTest");
18  problem.setElasticModulus(1e8);
19  problem.setDensity(2500);
20  problem.setSolidCubicMesh(20, 2, 2, 0, 0.2, 0, 0.02, 0, 0.02);
21  problem.pinBoundary(problem.Boundary::X_MIN);
22  problem.setBodyForceAsGravity();
23  problem.setNewtonSolverTolerance(3e-8);
24  problem.prepareForSolve();
25  // Solve the problem
26  problem.solveSteady();
27  return 0;
28 }
Array< double, 1, 3 > e(1./3., 0.5, 2.)
Definition: SolidProblem.h:60
Constructor for SteadyAxisymAdvectionDiffusion problem
Definition: steady_axisym_advection_diffusion.cc:213

References e(), and problem.