Changeset 13941
- Timestamp:
- 11/12/12 14:01:38 (12 years ago)
- Location:
- issm/trunk-jpl/src/c
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/classes/FemModel.cpp
r13939 r13941 353 353 Vector<IssmDouble> *df = NULL; 354 354 355 bool oldalloc= true;355 bool oldalloc=false; 356 356 357 357 /*retrieve parameters: */ … … 594 594 /*Initialize Jacobian Matrix*/ 595 595 this->AllocateSystemMatrices(&Jff,NULL,NULL,NULL); 596 Jff=new Matrix<IssmDouble>(fsize,fsize,connectivity,numberofdofspernode);597 596 598 597 /*Create and assemble matrix*/ -
issm/trunk-jpl/src/c/modules/CreateNodalConstraintsx/CreateNodalConstraintsx.cpp
r13622 r13941 12 12 void CreateNodalConstraintsx( Vector<IssmDouble>** pys, Nodes* nodes,int configuration_type){ 13 13 14 int i; 15 16 /*intermediary: */ 17 int numberofdofs; 14 bool oldalloc = false; 18 15 19 16 /*output: */ … … 21 18 22 19 /*figure out how many dofs we have: */ 23 numberofdofs=nodes->NumberOfDofs(configuration_type,SsetEnum); 20 int ssize=nodes->NumberOfDofs(configuration_type,SsetEnum); 21 int slocalsize = nodes->NumberOfDofsLocal(configuration_type,SsetEnum); 24 22 25 23 /*allocate:*/ 26 ys=new Vector<IssmDouble>(numberofdofs); 24 if(oldalloc) 25 ys=new Vector<IssmDouble>(ssize); 26 else 27 ys=new Vector<IssmDouble>(slocalsize,ssize); 27 28 28 29 /*go through all nodes, and for the ones corresponding to this configuration_type, fill the 29 30 * constraints vector with the constraint values: */ 30 for (i=0;i<nodes->Size();i++){31 for(int i=0;i<nodes->Size();i++){ 31 32 Node* node=(Node*)nodes->GetObjectByOffset(i); 32 33 if (node->InAnalysis(configuration_type)){ -
issm/trunk-jpl/src/c/modules/Reduceloadx/Reduceloadx.cpp
r13939 r13941 20 20 int global_m,global_n; 21 21 bool fromlocalsize = true; 22 bool oldalloc = true;22 bool oldalloc = false; 23 23 24 24 if(VerboseModule()) _pprintLine_(" Dirichlet lifting applied to load vector"); -
issm/trunk-jpl/src/c/modules/Reducevectorgtofx/Reducevectorgtofx.cpp
r13939 r13941 15 15 int fsize; 16 16 IssmDouble *ug_serial = NULL; 17 bool oldalloc = true;17 bool oldalloc = false; 18 18 19 19 /*first figure out fsize: */ -
issm/trunk-jpl/src/c/modules/Reducevectorgtosx/Reducevectorgtosx.cpp
r13220 r13941 21 21 ssize=nodes->NumberOfDofs(configuration_type,SsetEnum); 22 22 23 int analysis_type; 24 parameters->FindParam(&analysis_type,AnalysisTypeEnum); 25 int slocalsize = nodes->NumberOfDofsLocal(analysis_type,SsetEnum); 26 27 bool oldalloc = false; 28 23 29 if(ssize==0){ 24 30 ys=NULL; … … 26 32 else{ 27 33 /*allocate: */ 28 ys=new Vector<IssmDouble>(ssize); 34 if(oldalloc) 35 ys=new Vector<IssmDouble>(ssize); 36 else 37 ys=new Vector<IssmDouble>(slocalsize,ssize); 29 38 30 39 if(nodes->NumberOfNodes(configuration_type)){
Note:
See TracChangeset
for help on using the changeset viewer.