fe_stress#

Purpose

Computation of stresses and energies for given deformations.

Syntax

Result = fe_stress('Command',MODEL,DEF)
  ...  = fe_stress('Command',node,elt,pl,il, ...)
  ...  = fe_stress( ... ,mode,mdof)

Description

You can display stresses and energies directly using fecom ColorDataEner commands and use fe_stress to analyze results numerically. MODEL can be specified by four input arguments node, elt, pl and il (those used by fe_mk, see also section 7.1 and following), a data structure with fields .Node, .Elt, .pl, .il, or a database wrapper with those fields.

The deformations DEF can be specified using two arguments: mode and associated DOF definition vector mdof or a structure array with fields .def and .DOF.

Ener [m,k]ElementSelection#

Element energy computation. For a given shape, the levels of strain and kinetic energy in different elements give an indication of how much influence the modification of the element properties may have on the global system response. This knowledge is a useful analysis tool to determine regions that may need to be updated in a FE model. Accepted command options are

  • -MatDesval is used to specify the matrix type (see MatType). -MatDes 5 now correctly computes energies in pre-stressed configurations.
  • -curve should be used to obtain energies in the newer curve format. Ek.X{1} gives as columns EltId,vol,MatId,ProId,GroupId so that passage between energy and energy density can be done dynamically.
  • ElementSelection (see the element selection commands) used to compute energies in part of the model only. The default is to compute energies in all elements. A typical call to get the strain energy in a material of ID 1 would then be R1=fe_stress('Ener -MatDes1 -curve matid1',model,def);

Obsolete options are

  • m, k specify computation of kinetic or strain energies. For backward compatibility, fe_stress returns [StrainE,KinE] as two arguments if no element selection is given.
  • dens changes from the default where the element energy and not energy density is computed. This may be more appropriate when displaying energy levels for structures with uneven meshes.
  • Element energies are computed for deformations in DEF and the result is returned in the data structure RESULT with fields .data and .EltId which specifies which elements were selected. A .vol field gives the volume or mass of each element to allow switching between energy and energy density.

The strain and kinetic energies of an element are defined by

  Estraine=
1
2
φTKelementφ   and     Ekinetice=
1
2
φTMelementφ

For complex frequency responses, one integrates the response over one cycle, which corresponds to summing the energies of the real and imaginary parts and using a factor 1/4 rather than 1/2.

feplot#

feplot allows the visualization of these energies using a color coding. You should compute energies once, then select how it is displayed. Energy computation clearly require material and element properties to be defined in InitModel.

The earlier high level commands fecom ColorDataK or ColorDataM don't store the result and thus tend to lead to the need to recompute energies multiple times. The preferred strategy is illustrated below.

% Computing, storing and displaying energy data
 demosdt('LoadGartFe'); % load model,def 
 cf=feplot(model,def);cf.sel='eltname quad4';fecom ch7
 % Compute energy and store in Stack
 Ek=fe_stress('ener -MatDes 1 -curve',model,def)
 cf.Stack{'info','Ek'}=Ek;
 % Color is energy density by element
 feplot('ColorDataElt  -dens -ColorBarTitle "Ener Dens"',Ek);
 % Color by group of elements
 cf.sel={'eltname quad4', ... % Just the plates
   'ColorDataElt -ColorBarTitle "ener" -bygroup -edgealpha .1', ...
   Ek}; % Data with no need to recompute
 fecom(cf,'ColorScale One Off Tight') % Default color scaling for energies

Accepted ColorDataElt options are

  • -dens divides by element volume. Note that this can be problematic for mixed element types (in the example above, the volume of celas springs is defined as its length, which is inappropriate here).
  • -byGroup sums energies within the same element group. Similarly -byProId and -byMatId group by property identifier. When results are grouped, the fecom('InfoMass') command gives a summary of results.
  • -frac divides the result by the total energy (equal to the square of the modal frequency for normal modes).
  • -frac3 sorts elements by increasing density of energy and them by blocks of 20

The color animation mode is set to ScaleColorOne.

Stress#

out=fe_stress('stress CritFcn Options',MODEL,DEF,EltSel) returns the stresses evaluated at elements of Model selected by EltSel.

The CritFcn part of the command string is used to select a criterion. Currently supported criteria are


sI, sII, sIIIprincipal stresses from max to min. sI is the default.
misesReturns the von Mises stress (note that the plane strain case is not currently handled consistently).
-comp iReturns the stress components of index i. This component index is giving in the engineering rather than tensor notation (before applying the TensorTopology transformation).

Supported command Options (to select a restitution method, ...) are

  • AtNode average stress at each node (default). Note this is not currently weighted by element volume and thus quite approximate. Result is a structure with fields .DOF and .data.
  • AtCenter stress at center or mean stress at element stress restitution points. Result is a structure with fields .EltId and .data.
  • AtInteg stress at integration points (*b family of elements).
  • Gstate returns a case with Case.GroupInfo{jGroup,5} containing the group gstate. This will be typically used to initialize stress states for non-linear computations. For multiple deformations, gstate the first nElt columns correspond to the first deformation.
  • -curve returns the output using the curve format.

The fecom ColorDataStress directly calls fe_stress and displays the result. For example, run the basic element test q4p testsurstress, then display various stresses using

% Using stress display commands
 q4p('testsurstress')
 fecom('ColorDataStress atcenter')
 fecom('ColorDataStress mises')
 fecom('ColorDataStress sII atcenter')

To obtain strain computations, use the strain material as shown below.

% Accessing stress computation data (older calls)
 [model,def]=hexa8('testload stress');
 model.pl=m_elastic('dbval 100 strain','dbval 112 strain');
 model.il=p_solid('dbval 111 d3 -3');
 data=fe_stress('stress atcenter',model,def)

CritFcn#

For stress processing, one must often distinguish the raw stress components associated with the element formulation and the desired output. CritFcn are callback functions that take a local variable r1 of dimensions (stress components × nodes × deformations) and to replace this variable with the desired stress quantity(ies). For example

% Sample declaration of a user defined stress criterium computation
 function out=first_comp(r1)
  out=squeeze(r1(1,:,:,:));

would be a function taking the first component of a computed stress. sdtweb fe_stress(''Principal''' provides stress evaluations classical for mechanics.

For example, a list of predefined CritFcn callback :

  • Von Mises : CritFcn='r1=of_mk(''StressCrit'',r1,''VonMises'');lab=''Mises'';';
  • YY component : CritFcn='r1=r1(2,:,:,:);lab=''Syy'';'

Redefining the CritFcn callback is in particular used in the StressCut functionality, see section 4.9.

See also

fe_mk, feplot, fecom