CreateFemModel

PURPOSE ^

CREATEFEMMODEL - create a finite element model structure

SYNOPSIS ^

function m=CreateFemModel(md,solutiontype)

DESCRIPTION ^

CREATEFEMMODEL - create a finite element model structure

   returns a structure that holds the elements, the grids, the loads, the contraints
   and other parameters needed to build the stiffness matrix and load vector

   Usage:
      m=CreateFemModel(md,solutiontype)

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function  m=CreateFemModel(md,solutiontype)
0002 %CREATEFEMMODEL - create a finite element model structure
0003 %
0004 %   returns a structure that holds the elements, the grids, the loads, the contraints
0005 %   and other parameters needed to build the stiffness matrix and load vector
0006 %
0007 %   Usage:
0008 %      m=CreateFemModel(md,solutiontype)
0009 
0010 global gridset
0011 
0012 disp(['   creating fem model for solution ' solutiontype]);
0013 
0014 %First, build elements,grids,loads, etc ... for horizontal model
0015 [elements,grids,loads,constraints,materials,part,tpart]=ModelProcessor(md,solutiontype);
0016     
0017 %generate degrees of freedom
0018 grids=Dof(grids); 
0019     
0020 %add constraints to grids. Create yg vector of constraint values for the entire g set.
0021 [grids yg]=SpcGrids(grids,constraints);
0022 
0023 %build Rmg for multi point constraints
0024 Rmg=MpcGrids(grids,constraints);
0025 
0026 %generate grid sets and reduce yg to ys from g-set to s-set.
0027 BuildGridSets(grids,constraints); ys=Reducevector_g(yg);
0028     
0029 Gmn = IceNormalizeconstraints(Rmg);
0030 
0031 %recover dof number
0032 dof=gridset.fsize;
0033 
0034 %setup some parameters to be passed to the core solution
0035 params=SetupParams(md);
0036 
0037 m.elements=elements;
0038 m.grids=grids;
0039 m.loads=loads;
0040 m.constraints=constraints;
0041 m.materials=materials;
0042 m.part=part;
0043 m.tpart=tpart;
0044 m.ys=ys;
0045 m.gridset=gridset;
0046 m.dof=dof;
0047 m.params=params;
0048 m.Gmn=Gmn;

Generated on Sun 29-Mar-2009 20:22:55 by m2html © 2003