Changeset 3685
- Timestamp:
- 05/10/10 14:38:52 (15 years ago)
- Location:
- issm/trunk/src/c
- Files:
-
- 6 deleted
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk/src/c/Bamgx/Bamgx.h
r3283 r3685 7 7 8 8 #include "../objects/objects.h" 9 #include "objects/BamgObjects.h"10 9 11 10 /* local prototypes: */ -
issm/trunk/src/c/DataSet/DataSet.cpp
r3673 r3685 1 1 /* 2 2 * \file DataSet.c 3 * \brief: implementation of the DataSet class 3 * \brief: implementation of the DataSet class, and derived classes Inputs and Parameters 4 4 */ 5 5 6 /*Headers: {{{1*/ 6 7 #ifdef HAVE_CONFIG_H 7 8 #include "config.h" … … 21 22 22 23 using namespace std; 23 24 /*}}}*/ 25 /*DataSet: {{{1*/ 24 26 /*Constructors/Destructors*/ 25 /*FUNCTION DataSet::DataSet(){{{ 1*/27 /*FUNCTION DataSet::DataSet(){{{2*/ 26 28 DataSet::DataSet(){ 27 29 … … 32 34 } 33 35 /*}}}*/ 34 /*FUNCTION DataSet::DataSet(int dataset_enum){{{ 1*/36 /*FUNCTION DataSet::DataSet(int dataset_enum){{{2*/ 35 37 DataSet::DataSet(int dataset_enum){ 36 38 enum_type=dataset_enum; … … 42 44 } 43 45 /*}}}*/ 44 /*FUNCTION DataSet::Copy{{{ 1*/46 /*FUNCTION DataSet::Copy{{{2*/ 45 47 DataSet* DataSet::Copy(void){ 46 48 … … 73 75 } 74 76 /*}}}*/ 75 /*FUNCTION DataSet::~DataSet{{{ 1*/77 /*FUNCTION DataSet::~DataSet{{{2*/ 76 78 DataSet::~DataSet(){ 77 79 clear(); … … 82 84 83 85 /*I/O*/ 84 /*FUNCTION DataSet::Marshall{{{ 1*/86 /*FUNCTION DataSet::Marshall{{{2*/ 85 87 char* DataSet::Marshall(){ 86 88 … … 129 131 } 130 132 /*}}}*/ 131 /*FUNCTION DataSet::MarshallSize{{{ 1*/133 /*FUNCTION DataSet::MarshallSize{{{2*/ 132 134 int DataSet::MarshallSize(){ 133 135 … … 150 152 } 151 153 /*}}}*/ 152 /*FUNCTION DataSet::Demarshall{{{ 1*/154 /*FUNCTION DataSet::Demarshall{{{2*/ 153 155 DataSet* DataSetDemarshall(char* marshalled_dataset){ 154 156 … … 157 159 } 158 160 /*}}}*/ 159 /*FUNCTION DataSet::DemarshallRaw{{{ 1*/161 /*FUNCTION DataSet::DemarshallRaw{{{2*/ 160 162 DataSet* DataSetDemarshallRaw(char** pmarshalled_dataset){ 161 163 … … 309 311 } 310 312 /*}}}*/ 311 /*FUNCTION DataSet::Spawn{{{ 1*/313 /*FUNCTION DataSet::Spawn{{{2*/ 312 314 DataSet* DataSet::Spawn(int* indices, int num){ 313 315 ISSMERROR(" not supported yet!"); … … 316 318 317 319 /*Specific methods*/ 318 /*FUNCTION DataSet::AddObject{{{ 1*/320 /*FUNCTION DataSet::AddObject{{{2*/ 319 321 int DataSet::AddObject(Object* object){ 320 322 … … 324 326 } 325 327 /*}}}*/ 326 /*FUNCTION DataSet::clear{{{ 1*/328 /*FUNCTION DataSet::clear{{{2*/ 327 329 void DataSet::clear(){ 328 330 … … 335 337 } 336 338 /*}}}*/ 337 /*FUNCTION DataSet::DeleteObject{{{ 1*/339 /*FUNCTION DataSet::DeleteObject{{{2*/ 338 340 int DataSet::DeleteObject(Object* object){ 339 341 … … 348 350 } 349 351 /*}}}*/ 350 /*FUNCTION DataSet::DeepEcho{{{ 1*/352 /*FUNCTION DataSet::DeepEcho{{{2*/ 351 353 void DataSet::DeepEcho(){ 352 354 … … 367 369 } 368 370 /*}}}*/ 369 /*FUNCTION DataSet::Echo{{{ 1*/371 /*FUNCTION DataSet::Echo{{{2*/ 370 372 void DataSet::Echo(){ 371 373 … … 386 388 } 387 389 /*}}}*/ 388 /*FUNCTION DataSet::FindResult(Vec* presult,char* name){{{ 1*/390 /*FUNCTION DataSet::FindResult(Vec* presult,char* name){{{2*/ 389 391 int DataSet::FindResult(Vec* presult,char* name){ 390 392 … … 416 418 } 417 419 /*}}}*/ 418 /*FUNCTION DataSet::FindResult(void* pvalue, char* name){{{ 1*/420 /*FUNCTION DataSet::FindResult(void* pvalue, char* name){{{2*/ 419 421 int DataSet::FindResult(void* pvalue, char* name){ 420 422 … … 448 450 } 449 451 /*}}}*/ 450 /*FUNCTION DataSet::GetEnum{{{ 1*/452 /*FUNCTION DataSet::GetEnum{{{2*/ 451 453 int DataSet::GetEnum(){ 452 454 return enum_type; 453 455 } 454 456 /*}}}*/ 455 /*FUNCTION DataSet::GetEnum(int offset){{{ 1*/457 /*FUNCTION DataSet::GetEnum(int offset){{{2*/ 456 458 int DataSet::GetEnum(int offset){ 457 459 … … 460 462 } 461 463 /*}}}*/ 462 /*FUNCTION DataSet::GetObjectByOffset{{{ 1*/464 /*FUNCTION DataSet::GetObjectByOffset{{{2*/ 463 465 Object* DataSet::GetObjectByOffset(int offset){ 464 466 … … 467 469 } 468 470 /*}}}*/ 469 /*FUNCTION DataSet::GetObjectById{{{ 1*/471 /*FUNCTION DataSet::GetObjectById{{{2*/ 470 472 Object* DataSet::GetObjectById(int* poffset,int eid){ 471 473 … … 491 493 } 492 494 /*}}}*/ 493 /*FUNCTION DataSet::Ranks{{{ 1*/495 /*FUNCTION DataSet::Ranks{{{2*/ 494 496 void DataSet::Ranks(int* ranks){ 495 497 … … 514 516 } 515 517 /*}}}*/ 516 /*FUNCTION DataSet::Presort{{{ 1*/518 /*FUNCTION DataSet::Presort{{{2*/ 517 519 void DataSet::Presort(){ 518 520 … … 534 536 } 535 537 /*}}}*/ 536 /*FUNCTION DataSet::SetSorting{{{ 1*/538 /*FUNCTION DataSet::SetSorting{{{2*/ 537 539 void DataSet::SetSorting(int* in_sorted_ids,int* in_id_offsets){ 538 540 … … 542 544 } 543 545 /*}}}*/ 544 /*FUNCTION DataSet::Size{{{ 1*/546 /*FUNCTION DataSet::Size{{{2*/ 545 547 int DataSet::Size(void){ 546 548 … … 548 550 } 549 551 /*}}}*/ 550 /*FUNCTION DataSet::Sort{{{ 1*/552 /*FUNCTION DataSet::Sort{{{2*/ 551 553 void DataSet::Sort(){ 552 554 … … 559 561 560 562 /*Objects methods*/ 561 /*FUNCTION DataSet::ComputeBasalStress{{{ 1*/563 /*FUNCTION DataSet::ComputeBasalStress{{{2*/ 562 564 void DataSet::ComputeBasalStress(Vec sigma_b,int analysis_type,int sub_analysis_type){ 563 565 … … 576 578 } 577 579 /*}}}*/ 578 /*FUNCTION DataSet::ComputePressure{{{ 1*/580 /*FUNCTION DataSet::ComputePressure{{{2*/ 579 581 void DataSet::ComputePressure(Vec p_g,int analysis_type,int sub_analysis_type){ 580 582 … … 593 595 } 594 596 /*}}}*/ 595 /*FUNCTION DataSet::ComputeStrainRate{{{ 1*/597 /*FUNCTION DataSet::ComputeStrainRate{{{2*/ 596 598 void DataSet::ComputeStrainRate(Vec eps,int analysis_type,int sub_analysis_type){ 597 599 … … 610 612 } 611 613 /*}}}*/ 612 /*FUNCTION DataSet::Configure{{{ 1*/614 /*FUNCTION DataSet::Configure{{{2*/ 613 615 void DataSet::Configure(DataSet* elements,DataSet* loads, DataSet* nodes, DataSet* vertices, DataSet* materials,Parameters* parameters){ 614 616 … … 638 640 } 639 641 /*}}}*/ 640 /*FUNCTION DataSet::CostFunction{{{ 1*/642 /*FUNCTION DataSet::CostFunction{{{2*/ 641 643 void DataSet::CostFunction(double* pJ,int analysis_type,int sub_analysis_type){ 642 644 … … 661 663 } 662 664 /*}}}*/ 663 /*FUNCTION DataSet::CreateKMatrix{{{ 1*/665 /*FUNCTION DataSet::CreateKMatrix{{{2*/ 664 666 void DataSet::CreateKMatrix(Mat Kgg,int analysis_type,int sub_analysis_type){ 665 667 … … 684 686 } 685 687 /*}}}*/ 686 /*FUNCTION DataSet::CreatePartitioningVector{{{ 1*/688 /*FUNCTION DataSet::CreatePartitioningVector{{{2*/ 687 689 void DataSet::CreatePartitioningVector(Vec* ppartition,int numberofobjects){ 688 690 … … 712 714 } 713 715 /*}}}*/ 714 /*FUNCTION DataSet::CreatePVector{{{ 1*/716 /*FUNCTION DataSet::CreatePVector{{{2*/ 715 717 void DataSet::CreatePVector(Vec pg,int analysis_type,int sub_analysis_type){ 716 718 … … 735 737 } 736 738 /*}}}*/ 737 /*FUNCTION DataSet::DistributeDofs{{{ 1*/739 /*FUNCTION DataSet::DistributeDofs{{{2*/ 738 740 void DataSet::DistributeDofs(int numberofobjects,int numberofdofsperobject){ 739 741 … … 817 819 } 818 820 /*}}}*/ 819 /*FUNCTION DataSet::Du{{{ 1*/821 /*FUNCTION DataSet::Du{{{2*/ 820 822 void DataSet::Du(Vec du_g,int analysis_type,int sub_analysis_type){ 821 823 … … 836 838 } 837 839 /*}}}*/ 838 /*FUNCTION DataSet::FieldAverageOntoVertices{{{ 1*/840 /*FUNCTION DataSet::FieldAverageOntoVertices{{{2*/ 839 841 void DataSet::FieldAverageOntoVertices(Vec fieldsum,Vec connectivity,double* field){ 840 842 … … 853 855 } 854 856 /*}}}*/ 855 /*FUNCTION DataSet::FieldDepthAverageAtBase{{{ 1*/857 /*FUNCTION DataSet::FieldDepthAverageAtBase{{{2*/ 856 858 void DataSet::FieldDepthAverageAtBase(Vec field,double* field_serial,char* fieldname){ 857 859 … … 870 872 } 871 873 /*}}}*/ 872 /*FUNCTION DataSet::FieldExtrude{{{ 1*/874 /*FUNCTION DataSet::FieldExtrude{{{2*/ 873 875 void DataSet::FieldExtrude(Vec field,double* field_serial,char* field_name, int collapse){ 874 876 … … 895 897 } 896 898 /*}}}*/ 897 /*FUNCTION DataSet::FlagClones{{{ 1*/899 /*FUNCTION DataSet::FlagClones{{{2*/ 898 900 void DataSet::FlagClones(int numberofobjects){ 899 901 … … 936 938 } 937 939 /*}}}*/ 938 /*FUNCTION DataSet::FlagNodeSets{{{ 1*/940 /*FUNCTION DataSet::FlagNodeSets{{{2*/ 939 941 void DataSet::FlagNodeSets(Vec pv_g, Vec pv_m, Vec pv_n, Vec pv_f, Vec pv_s){ 940 942 … … 973 975 } 974 976 /*}}}*/ 975 /*FUNCTION DataSet::Gradj{{{ 1*/977 /*FUNCTION DataSet::Gradj{{{2*/ 976 978 void DataSet::Gradj(Vec grad_g,int analysis_type,int sub_analysis_type,char* control_type){ 977 979 … … 992 994 } 993 995 /*}}}*/ 994 /*FUNCTION DataSet::MeltingIsPresent{{{ 1*/996 /*FUNCTION DataSet::MeltingIsPresent{{{2*/ 995 997 int DataSet::MeltingIsPresent(){ 996 998 … … 1017 1019 } 1018 1020 /*}}}*/ 1019 /*FUNCTION DataSet::MeltingConstraints{{{ 1*/1021 /*FUNCTION DataSet::MeltingConstraints{{{2*/ 1020 1022 void DataSet::MeltingConstraints(int* pconverged, int* pnum_unstable_constraints,int analysis_type,int sub_analysis_type){ 1021 1023 … … 1059 1061 } 1060 1062 /*}}}*/ 1061 /*FUNCTION DataSet::Misfit{{{ 1*/1063 /*FUNCTION DataSet::Misfit{{{2*/ 1062 1064 void DataSet::Misfit(double* pJ,int analysis_type,int sub_analysis_type){ 1063 1065 … … 1082 1084 } 1083 1085 /*}}}*/ 1084 /*FUNCTION DataSet::NumberOfDofs{{{ 1*/1086 /*FUNCTION DataSet::NumberOfDofs{{{2*/ 1085 1087 int DataSet::NumberOfDofs(){ 1086 1088 … … 1114 1116 } 1115 1117 /*}}}*/ 1116 /*FUNCTION DataSet::NumberOfRgbs{{{ 1*/1118 /*FUNCTION DataSet::NumberOfRgbs{{{2*/ 1117 1119 int DataSet::NumberOfRgbs(){ 1118 1120 … … 1134 1136 } 1135 1137 /*}}}*/ 1136 /*FUNCTION DataSet::OutputRifts{{{ 1*/1138 /*FUNCTION DataSet::OutputRifts{{{2*/ 1137 1139 void DataSet::OutputRifts(Vec riftproperties){ 1138 1140 … … 1153 1155 } 1154 1156 /*}}}*/ 1155 /*FUNCTION DataSet::PenaltyCreateKMatrix{{{ 1*/1157 /*FUNCTION DataSet::PenaltyCreateKMatrix{{{2*/ 1156 1158 void DataSet::PenaltyCreateKMatrix(Mat Kgg,double kmax,int analysis_type,int sub_analysis_type){ 1157 1159 … … 1170 1172 } 1171 1173 /*}}}*/ 1172 /*FUNCTION DataSet::PenaltyCreatePVector{{{ 1*/1174 /*FUNCTION DataSet::PenaltyCreatePVector{{{2*/ 1173 1175 void DataSet::PenaltyCreatePVector(Vec pg,double kmax,int analysis_type,int sub_analysis_type){ 1174 1176 … … 1187 1189 } 1188 1190 /*}}}*/ 1189 /*FUNCTION DataSet::RiftIsPresent{{{ 1*/1191 /*FUNCTION DataSet::RiftIsPresent{{{2*/ 1190 1192 int DataSet::RiftIsPresent(){ 1191 1193 … … 1215 1217 } 1216 1218 /*}}}*/ 1217 /*FUNCTION DataSet::SetupMpcs{{{ 1*/1219 /*FUNCTION DataSet::SetupMpcs{{{2*/ 1218 1220 void DataSet::SetupMpcs(Mat Rmg,DataSet* nodes){ 1219 1221 … … 1283 1285 } 1284 1286 /*}}}*/ 1285 /*FUNCTION DataSet::SetupSpcs{{{ 1*/1287 /*FUNCTION DataSet::SetupSpcs{{{2*/ 1286 1288 void DataSet::SetupSpcs(DataSet* nodes,Vec yg){ 1287 1289 … … 1322 1324 } 1323 1325 /*}}}*/ 1324 /*FUNCTION DataSet::SurfaceArea{{{ 1*/1326 /*FUNCTION DataSet::SurfaceArea{{{2*/ 1325 1327 void DataSet::SurfaceArea(double* pS,int analysis_type,int sub_analysis_type){ 1326 1328 … … 1345 1347 } 1346 1348 /*}}}*/ 1347 /*FUNCTION DataSet::UpdateInputs{{{ 1*/1349 /*FUNCTION DataSet::UpdateInputs{{{2*/ 1348 1350 void DataSet::UpdateInputs(double* solution, int analysis_type, int sub_analysis_type){ 1349 1351 … … 1362 1364 } 1363 1365 /*}}}*/ 1364 /*FUNCTION DataSet::AddInput{{{ 1*/1366 /*FUNCTION DataSet::AddInput{{{2*/ 1365 1367 void DataSet::AddInput(double value, int enum_type){ 1366 1368 … … 1379 1381 } 1380 1382 /*}}}*/ 1381 /*FUNCTION DataSet::UpdateVertexPositions{{{ 1*/1383 /*FUNCTION DataSet::UpdateVertexPositions{{{2*/ 1382 1384 void DataSet::UpdateVertexPositions(double* thickness,double* bed){ 1383 1385 … … 1395 1397 } 1396 1398 /*}}}*/ 1399 1400 /*}}}*/ 1401 /*Inputs: {{{1*/ 1402 1403 /*Object constructors and destructor*/ 1404 /*FUNCTION Inputs::Inputs(){{{2*/ 1405 Inputs::Inputs(){ 1406 return; 1407 } 1408 /*}}}*/ 1409 /*FUNCTION Inputs::Inputs(int in_enum){{{2*/ 1410 Inputs::Inputs(int in_enum): DataSet(in_enum) { 1411 //do nothing; 1412 return; 1413 } 1414 /*}}}*/ 1415 /*FUNCTION Inputs::~Inputs(){{{2*/ 1416 Inputs::~Inputs(){ 1417 return; 1418 } 1419 /*}}}*/ 1420 1421 /*Object management*/ 1422 /*FUNCTION Inputs::GetParameterValue(double* pvalue,double* gauss,int enum_type){{{2*/ 1423 void Inputs::GetParameterValue(double* pvalue,double* gauss, int enum_type){ 1424 1425 vector<Object*>::iterator object; 1426 Input* input=NULL; 1427 1428 /*Go through inputs and check whether any input with the same name is already in: */ 1429 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1430 1431 input=(Input*)(*object); 1432 if (input->EnumType()==enum_type)break; 1433 } 1434 1435 if (!input){ 1436 /*we could not find an input with the correct enum type. No defaults values were provided, 1437 * error out: */ 1438 ISSMERROR("%s%i"," could not find input with enum type ",enum_type); 1439 } 1440 1441 /*Ok, we have an input if we made it here, request the input to return the values: */ 1442 input->GetParameterValue(pvalue,gauss); 1443 1444 } 1445 /*}}}*/ 1446 /*FUNCTION Inputs::GetParameterValue(double* pvalue,double* gauss,int enum_type,double defaultvalue){{{2*/ 1447 void Inputs::GetParameterValue(double* pvalue,double* gauss, int enum_type,double defaultvalue){ 1448 1449 vector<Object*>::iterator object; 1450 Input* input=NULL; 1451 1452 /*Go through inputs and check whether any input with the same name is already in: */ 1453 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1454 1455 input=(Input*)(*object); 1456 if (input->EnumType()==enum_type)break; 1457 } 1458 1459 if (!input){ 1460 /*we could not find an input with the correct enum type. Return the default value: */ 1461 *pvalue=defaultvalue; 1462 } 1463 else{ 1464 input->GetParameterValue(pvalue,gauss); 1465 } 1466 } 1467 /*}}}*/ 1468 /*FUNCTION Inputs::GetParameterValues(double* values,double* gauss_pointers, int numgauss,int enum_type){{{2*/ 1469 void Inputs::GetParameterValues(double* values,double* gauss_pointers, int numgauss,int enum_type){ 1470 1471 vector<Object*>::iterator object; 1472 Input* input=NULL; 1473 1474 /*Go through inputs and check whether any input with the same name is already in: */ 1475 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1476 1477 input=(Input*)(*object); 1478 if (input->EnumType()==enum_type)break; 1479 } 1480 1481 if (!input){ 1482 /*we could not find an input with the correct enum type. No defaults values were provided, 1483 * error out: */ 1484 ISSMERROR("%s%i"," could not find input with enum type ",enum_type); 1485 } 1486 1487 /*Ok, we have an input if we made it here, request the input to return the values: */ 1488 input->GetParameterValues(values,gauss_pointers,numgauss); 1489 1490 } 1491 /*}}}*/ 1492 /*FUNCTION Inputs::GetParameterValue(double* pvalue, Node* node, int enum_type){{{2*/ 1493 void Inputs::GetParameterValue(double* pvalue,Node* node,int enum_type){ 1494 1495 /*given a node, instead of a gauss point, we want to recover a value: probably in an element!: */ 1496 1497 vector<Object*>::iterator object; 1498 Input* input=NULL; 1499 1500 /*Go through inputs and check whether any input with the same name is already in: */ 1501 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1502 1503 input=(Input*)(*object); 1504 if (input->EnumType()==enum_type)break; 1505 } 1506 1507 if (!input){ 1508 /*we could not find an input with the correct enum type. No defaults values were provided, 1509 * error out: */ 1510 ISSMERROR("%s%i"," could not find input with enum type ",enum_type); 1511 } 1512 1513 /*Ok, we have an input if we made it here, request the input to return the values: */ 1514 input->GetParameterValue(pvalue,node); 1515 } 1516 /*}}}*/ 1517 /*FUNCTION Inputs::GetParameterValue(double* pvalue, Node* node1, Node* node2,int enum_type){{{2*/ 1518 void Inputs::GetParameterValue(double* pvalue,Node* node1, Node* node2,double gauss_coord,int enum_type){ 1519 1520 /*given a node, instead of a gauss point, we want to recover a value: probably in an element!: */ 1521 1522 vector<Object*>::iterator object; 1523 Input* input=NULL; 1524 1525 /*Go through inputs and check whether any input with the same name is already in: */ 1526 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1527 1528 input=(Input*)(*object); 1529 if (input->EnumType()==enum_type)break; 1530 } 1531 1532 if (!input){ 1533 /*we could not find an input with the correct enum type. No defaults values were provided, 1534 * error out: */ 1535 ISSMERROR("%s%i"," could not find input with enum type ",enum_type); 1536 } 1537 1538 /*Ok, we have an input if we made it here, request the input to return the values: */ 1539 input->GetParameterValue(pvalue,node1,node2,gauss_coord); 1540 } 1541 /*}}}*/ 1542 /*FUNCTION Inputs::GetParameterValues(double* values,double* gauss_pointers, int numgauss,int enum_type,double* defaultvalues){{{2*/ 1543 void Inputs::GetParameterValues(double* values,double* gauss_pointers, int numgauss,int enum_type,double* defaultvalues){ 1544 1545 int i; 1546 vector<Object*>::iterator object; 1547 Input* input=NULL; 1548 1549 /*Go through inputs and check whether any input with the same name is already in: */ 1550 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1551 1552 input=(Input*)(*object); 1553 if (input->EnumType()==enum_type)break; 1554 } 1555 1556 if (!input){ 1557 /*we could not find an input with the correct enum type. Return the default values: */ 1558 for(i=0;i<numgauss;i++)values[i]=defaultvalues[i]; 1559 } 1560 else{ 1561 input->GetParameterValues(values,gauss_pointers,numgauss); 1562 } 1563 1564 } 1565 /*}}}*/ 1566 /*FUNCTION Inputs::GetParameterValue(bool* pvalue,int enum-type){{{2*/ 1567 void Inputs::GetParameterValue(bool* pvalue,int enum_type){ 1568 1569 vector<Object*>::iterator object; 1570 Input* input=NULL; 1571 1572 /*Go through inputs and check whether any input with the same name is already in: */ 1573 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1574 1575 input=(Input*)(*object); 1576 if (input->EnumType()==enum_type)break; 1577 } 1578 1579 if (!input){ 1580 /*we could not find an input with the correct enum type. No defaults values were provided, 1581 * error out: */ 1582 ISSMERROR("%s%i"," could not find input with enum type ",enum_type); 1583 } 1584 1585 /*Ok, we have an input if we made it here, request the input to return the value: */ 1586 input->GetParameterValue(pvalue); 1587 1588 } 1589 /*}}}*/ 1590 /*FUNCTION Inputs::GetParameterValue(int* pvalue,int enum-type){{{2*/ 1591 void Inputs::GetParameterValue(int* pvalue,int enum_type){ 1592 1593 vector<Object*>::iterator object; 1594 Input* input=NULL; 1595 1596 /*Go through inputs and check whether any input with the same name is already in: */ 1597 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1598 1599 input=(Input*)(*object); 1600 if (input->EnumType()==enum_type)break; 1601 } 1602 1603 if (!input){ 1604 /*we could not find an input with the correct enum type. No defaults values were provided, 1605 * error out: */ 1606 ISSMERROR("%s%i"," could not find input with enum type ",enum_type); 1607 } 1608 1609 /*Ok, we have an input if we made it here, request the input to return the value: */ 1610 input->GetParameterValue(pvalue); 1611 1612 } 1613 /*}}}*/ 1614 /*FUNCTION Inputs::GetParameterValue(double* pvalue,int enum-type){{{2*/ 1615 void Inputs::GetParameterValue(double* pvalue,int enum_type){ 1616 1617 vector<Object*>::iterator object; 1618 Input* input=NULL; 1619 1620 /*Go through inputs and check whether any input with the same name is already in: */ 1621 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1622 1623 input=(Input*)(*object); 1624 if (input->EnumType()==enum_type)break; 1625 } 1626 1627 if (!input){ 1628 /*we could not find an input with the correct enum type. No defaults values were provided, 1629 * error out: */ 1630 ISSMERROR("%s%i"," could not find input with enum type ",enum_type); 1631 } 1632 1633 /*Ok, we have an input if we made it here, request the input to return the value: */ 1634 input->GetParameterValue(pvalue); 1635 1636 } 1637 /*}}}*/ 1638 /*FUNCTION Inputs::GetParameterDerivativeValue(double* derivativevalues, double* xyz_list, double* gauss,int enum_type){{{2*/ 1639 void Inputs::GetParameterDerivativeValue(double* derivativevalues, double* xyz_list, double* gauss,int enum_type){ 1640 1641 vector<Object*>::iterator object; 1642 Input* input=NULL; 1643 1644 /*Go through inputs and check whether any input with the same name is already in: */ 1645 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1646 1647 input=(Input*)(*object); 1648 if (input->EnumType()==enum_type)break; 1649 } 1650 1651 if (!input){ 1652 /*we could not find an input with the correct enum type. No defaults values were provided, 1653 * error out: */ 1654 ISSMERROR("%s%i"," could not find input with enum type ",enum_type); 1655 } 1656 1657 /*Ok, we have an input if we made it here, request the input to return the value: */ 1658 input->GetParameterDerivativeValue(derivativevalues,xyz_list,gauss); 1659 } 1660 /*}}}*/ 1661 /*FUNCTION Inputs::GetStrainRate(double* epsilon,double* xyz_list, double* gauss, int xenum, int yenum){{{2*/ 1662 void Inputs::GetStrainRate(double* epsilon,double* xyz_list, double* gauss, int xenum, int yenum){ 1663 1664 vector<Object*>::iterator object; 1665 Input* xinput=NULL; 1666 Input* yinput=NULL; 1667 1668 /*Go through inputs and find data for xenum: */ 1669 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1670 xinput=(Input*)(*object); 1671 if (xinput->EnumType()==xenum)break; 1672 } 1673 /*Go through inputs and find data for yenum: */ 1674 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1675 yinput=(Input*)(*object); 1676 if (yinput->EnumType()==yenum)break; 1677 } 1678 1679 if (!xinput | !yinput){ 1680 /*we could not find one input with the correct enum type. No defaults values were provided, 1681 * error out: */ 1682 ISSMERROR("%s%i%s%i\n"," could not find input with enum type ",xenum," or enum type ",yenum); 1683 } 1684 1685 /*Ok, we have the inputs, call bilinear operator: */ 1686 xinput->GetStrainRate(epsilon,yinput,xyz_list,gauss); 1687 1688 } 1689 /*}}}*/ 1690 /*FUNCTION Inputs::GetStrainRateStokes(double* epsilon,double* xyz_list, double* gauss, int xenum, int yenum,int zenum){{{2*/ 1691 void Inputs::GetStrainRateStokes(double* epsilon,double* xyz_list, double* gauss, int xenum, int yenum,int zenum){ 1692 1693 vector<Object*>::iterator object; 1694 Input* xinput=NULL; 1695 Input* yinput=NULL; 1696 Input* zinput=NULL; 1697 1698 /*Go through inputs and find data for xenum: */ 1699 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1700 xinput=(Input*)(*object); 1701 if (xinput->EnumType()==xenum)break; 1702 } 1703 /*Go through inputs and find data for yenum: */ 1704 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1705 yinput=(Input*)(*object); 1706 if (yinput->EnumType()==yenum)break; 1707 } 1708 /*Go through inputs and find data for zenum: */ 1709 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1710 zinput=(Input*)(*object); 1711 if (zinput->EnumType()==zenum)break; 1712 } 1713 1714 if (!xinput | !yinput | !zinput){ 1715 /*we could not find one input with the correct enum type. No defaults values were provided, 1716 * error out: */ 1717 ISSMERROR("%s%i%s%i%s%i\n"," could not find input with enum type ",xenum," or enum type ",yenum, " or enum type ",zenum); 1718 } 1719 1720 /*Ok, we have the inputs, call bilinear operator: */ 1721 xinput->GetStrainRateStokes(epsilon,yinput,zinput,xyz_list,gauss); 1722 1723 } 1724 /*}}}*/ 1725 /*FUNCTION Inputs::AddInput{{{2*/ 1726 int Inputs::AddInput(Input* in_input){ 1727 1728 /*First, go through dataset of inputs and check whether any input 1729 * with the same name is already in. If so, erase the corresponding 1730 * object before adding this new one: */ 1731 vector<Object*>::iterator object; 1732 Input* input=NULL; 1733 1734 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1735 1736 input=(Input*)(*object); 1737 1738 if (input->EnumType()==in_input->EnumType()){ 1739 this->DeleteObject(input); 1740 break; 1741 } 1742 } 1743 this->AddObject(in_input); 1744 } 1745 /*}}}*/ 1746 1747 /*Object functions*/ 1748 1749 1750 /*}}}*/ 1751 /*Parameters: {{{1*/ 1752 1753 1754 /*Object constructors and destructor*/ 1755 /*FUNCTION Parameters::Parameters(){{{2*/ 1756 Parameters::Parameters(){ 1757 return; 1758 } 1759 /*}}}*/ 1760 /*FUNCTION Parameters::Parameters(int in_enum){{{2*/ 1761 Parameters::Parameters(int in_enum): DataSet(in_enum){ 1762 //do nothing; 1763 return; 1764 } 1765 /*}}}*/ 1766 /*FUNCTION Parameters::~Parameters(){{{2*/ 1767 Parameters::~Parameters(){ 1768 return; 1769 } 1770 /*}}}*/ 1771 1772 /*Object management*/ 1773 /*FUNCTION Parameters::FindParam(double* pscalar, int enum_type){{{2*/ 1774 int Parameters::FindParam(double* pscalar, int enum_type){ 1775 1776 /*Go through a dataset, and find a Param* object 1777 *which parameter name is "name" : */ 1778 1779 vector<Object*>::iterator object; 1780 Param* param=NULL; 1781 1782 int found=0; 1783 1784 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1785 1786 /*Find param type objects: */ 1787 if((*object)->Enum()==ParamEnum){ 1788 1789 /*Ok, this object is a parameter, recover it and ask which name it has: */ 1790 param=(Param*)(*object); 1791 1792 if(param->EnumType()==enum_type){ 1793 /*Ok, this is the one! Recover the value of this parameter: */ 1794 param->GetParameterValue(pscalar); 1795 found=1; 1796 break; 1797 } 1798 } 1799 } 1800 return found; 1801 } 1802 /*}}}*/ 1803 /*FUNCTION Parameters::FindParam(int* pinteger,int enum_type){{{2*/ 1804 int Parameters::FindParam(int* pinteger,int enum_type){ 1805 1806 1807 /*Go through a dataset, and find a Param* object 1808 *which parameter name is "name" : */ 1809 1810 vector<Object*>::iterator object; 1811 Param* param=NULL; 1812 1813 int found=0; 1814 1815 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1816 1817 /*Find param type objects: */ 1818 if((*object)->Enum()==ParamEnum){ 1819 1820 /*Ok, this object is a parameter, recover it and ask which name it has: */ 1821 param=(Param*)(*object); 1822 1823 if(param->EnumType()==enum_type){ 1824 /*Ok, this is the one! Recover the value of this parameter: */ 1825 param->GetParameterValue(pinteger); 1826 found=1; 1827 break; 1828 } 1829 } 1830 } 1831 return found; 1832 } 1833 /*}}}*/ 1834 /*FUNCTION Parameters::FindParam(char** pstring,int enum_type){{{2*/ 1835 int Parameters::FindParam(char** pstring,int enum_type){ 1836 1837 /*Go through a dataset, and find a Param* object 1838 *which parameter name is "name" : */ 1839 1840 vector<Object*>::iterator object; 1841 Param* param=NULL; 1842 1843 int found=0; 1844 1845 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1846 1847 /*Find param type objects: */ 1848 if((*object)->Enum()==ParamEnum){ 1849 1850 /*Ok, this object is a parameter, recover it and ask which name it has: */ 1851 param=(Param*)(*object); 1852 1853 if(param->EnumType()==enum_type){ 1854 /*Ok, this is the one! Recover the value of this parameter: */ 1855 param->GetParameterValue(pstring); 1856 found=1; 1857 break; 1858 } 1859 } 1860 } 1861 return found; 1862 1863 } 1864 /*}}}*/ 1865 /*FUNCTION Parameters::FindParam(char*** pstringarray,int* pM,int enum_type){{{2*/ 1866 int Parameters::FindParam(char*** pstringarray,int* pM,int enum_type){ 1867 1868 /*Go through a dataset, and find a Param* object 1869 *which parameter name is "name" : */ 1870 1871 vector<Object*>::iterator object; 1872 Param* param=NULL; 1873 1874 int found=0; 1875 1876 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1877 1878 /*Find param type objects: */ 1879 if((*object)->Enum()==ParamEnum){ 1880 1881 /*Ok, this object is a parameter, recover it and ask which name it has: */ 1882 param=(Param*)(*object); 1883 1884 if(param->EnumType()==enum_type){ 1885 /*Ok, this is the one! Recover the value of this parameter: */ 1886 param->GetParameterValue(pstringarray,pM); 1887 found=1; 1888 break; 1889 } 1890 } 1891 } 1892 return found; 1893 1894 } 1895 /*}}}*/ 1896 /*FUNCTION Parameters::FindParam(double** pdoublearray,int* pM,int enum_type){{{2*/ 1897 int Parameters::FindParam(double** pdoublearray,int* pM, int enum_type){ 1898 1899 /*Go through a dataset, and find a Param* object 1900 *which parameter name is "name" : */ 1901 1902 vector<Object*>::iterator object; 1903 Param* param=NULL; 1904 1905 int found=0; 1906 1907 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1908 1909 /*Find param type objects: */ 1910 if((*object)->Enum()==ParamEnum){ 1911 1912 /*Ok, this object is a parameter, recover it and ask which name it has: */ 1913 param=(Param*)(*object); 1914 1915 if(param->EnumType()==enum_type){ 1916 /*Ok, this is the one! Recover the value of this parameter: */ 1917 param->GetParameterValue(pdoublearray,pM); 1918 found=1; 1919 break; 1920 } 1921 } 1922 } 1923 return found; 1924 1925 } 1926 /*}}}*/ 1927 /*FUNCTION Parameters::FindParam(double** pdoublearray,int* pM, int* pN,int enum_type){{{2*/ 1928 int Parameters::FindParam(double** pdoublearray,int* pM, int* pN,int enum_type){ 1929 1930 /*Go through a dataset, and find a Param* object 1931 *which parameter name is "name" : */ 1932 1933 vector<Object*>::iterator object; 1934 Param* param=NULL; 1935 1936 int found=0; 1937 1938 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1939 1940 /*Find param type objects: */ 1941 if((*object)->Enum()==ParamEnum){ 1942 1943 /*Ok, this object is a parameter, recover it and ask which name it has: */ 1944 param=(Param*)(*object); 1945 1946 if(param->EnumType()==enum_type){ 1947 /*Ok, this is the one! Recover the value of this parameter: */ 1948 param->GetParameterValue(pdoublearray,pM,pN); 1949 found=1; 1950 break; 1951 } 1952 } 1953 } 1954 return found; 1955 1956 } 1957 /*}}}*/ 1958 /*FUNCTION Parameters::FindParam(Vec* pvec,int enum_type){{{2*/ 1959 int Parameters::FindParam(Vec* pvec,int enum_type){ 1960 1961 /*Go through a dataset, and find a Param* object 1962 *which parameter name is "name" : */ 1963 1964 vector<Object*>::iterator object; 1965 Param* param=NULL; 1966 1967 int found=0; 1968 1969 for ( object=objects.begin() ; object < objects.end(); object++ ){ 1970 1971 /*Find param type objects: */ 1972 if((*object)->Enum()==ParamEnum){ 1973 1974 /*Ok, this object is a parameter, recover it and ask which name it has: */ 1975 param=(Param*)(*object); 1976 1977 if(param->EnumType()==enum_type){ 1978 /*Ok, this is the one! Recover the value of this parameter: */ 1979 param->GetParameterValue(pvec); 1980 found=1; 1981 break; 1982 } 1983 } 1984 } 1985 return found; 1986 1987 } 1988 /*}}}*/ 1989 /*FUNCTION Parameters::FindParamMat* pmat,int enum_type){{{2*/ 1990 int Parameters::FindParam(Mat* pmat,int enum_type){ 1991 1992 /*Go through a dataset, and find a Param* object 1993 *which parameter name is "name" : */ 1994 1995 vector<Object*>::iterator object; 1996 Param* param=NULL; 1997 1998 int found=0; 1999 2000 for ( object=objects.begin() ; object < objects.end(); object++ ){ 2001 2002 /*Find param type objects: */ 2003 if((*object)->Enum()==ParamEnum){ 2004 2005 /*Ok, this object is a parameter, recover it and ask which name it has: */ 2006 param=(Param*)(*object); 2007 2008 if(param->EnumType()==enum_type){ 2009 /*Ok, this is the one! Recover the value of this parameter: */ 2010 param->GetParameterValue(pmat); 2011 found=1; 2012 break; 2013 } 2014 } 2015 } 2016 return found; 2017 2018 } 2019 /*}}}*/ 2020 /*FUNCTION Parameters::FindParamObject{{{2*/ 2021 Object* Parameters::FindParamObject(int enum_type){ 2022 2023 /*Go through a dataset, and find a Param* object 2024 *which parameter name is "name" : */ 2025 2026 vector<Object*>::iterator object; 2027 Param* param=NULL; 2028 2029 for ( object=objects.begin() ; object < objects.end(); object++ ){ 2030 2031 /*Find param type objects: */ 2032 if((*object)->Enum()==ParamEnum){ 2033 2034 /*Ok, this object is a parameter, recover it and ask which name it has: */ 2035 param=(Param*)(*object); 2036 2037 if(param->EnumType()==enum_type){ 2038 /*Ok, this is the one! Return the object: */ 2039 return (*object); 2040 } 2041 } 2042 } 2043 return NULL; 2044 } 2045 /*}}}*/ 2046 2047 /*Object functions*/ 2048 2049 2050 /*}}}*/ -
issm/trunk/src/c/DataSet/DataSet.h
r3673 r3685 1 1 /* 2 * DataSet.h: 3 * \brief Class that holds objects. 4 * \file DataSet.h This prototype defines a DataSet, capable of holding any type of 5 * objects (using the abstract class Object). 2 * DataSet.h: declaration of DataSet,Parameters and Inputs classes 6 3 */ 7 8 4 9 5 #ifndef _DATASET_H_ … … 11 7 12 8 #include <vector> 9 #include "../objects/Object.h" 13 10 #include "../toolkits/toolkits.h" 14 #include "../objects/Object.h" 11 12 /*forward declarations */ 13 class Parameters; 14 class DataSet; 15 15 class Inputs; 16 class Parameters;17 16 17 18 /********************************************************DATASET************************************************/ 18 19 class DataSet{ 19 20 … … 102 103 DataSet* DataSetDemarshallRaw(char** pmarshalled_dataset); 103 104 105 106 107 /********************************************************INPUTS************************************************/ 108 class Input; 109 class Node; 110 #include "./DataSet.h" 111 #include "../objects/objects.h" 112 113 class Inputs: public DataSet{ 114 115 public: 116 117 /*constructors, destructors: {{{1*/ 118 Inputs(); 119 Inputs(int enum_type); 120 ~Inputs(); 121 /*}}}*/ 122 /*numerics: {{{1*/ 123 int AddInput(Input* in_input); 124 125 void GetParameterValue(bool* pvalue,int enum_type); 126 void GetParameterValue(int* pvalue,int enum_type); 127 void GetParameterValue(double* pvalue,int enum_type); 128 void GetParameterValue(double* pvalue,Node* node,int enum_type); 129 void GetParameterValue(double* pvalue,Node* node1,Node* node2,double gauss_coord,int enum_type); 130 void GetParameterValue(double* pvalue,double* gauss,int enum_type); 131 void GetParameterValue(double* pvalue,double* gauss,int enum_type,double defaultvalue); 132 133 void GetParameterValues(double* values,double* gauss_pointers, int numgauss,int enum_type); 134 void GetParameterValues(double* values,double* gauss_pointers, int numgauss,int enum_type,double* defaultvalues); 135 136 void GetParameterDerivativeValue(double* derivativevalues, double* xyz_list, double* gauss,int enum_type); 137 void GetStrainRate(double* epsilon,double* xyz_list, double* gauss, int xenum, int yenum); 138 void GetStrainRateStokes(double* epsilon,double* xyz_list, double* gauss, int xenum, int yenum,int yenum); 139 /*}}}*/ 140 141 }; 142 143 144 /********************************************************PARAMETERS************************************************/ 145 146 class Parameters: public DataSet{ 147 148 public: 149 150 /*constructors, destructors: {{{1*/ 151 Parameters(); 152 Parameters(int enum_type); 153 ~Parameters(); 154 /*}}}*/ 155 /*numerics: {{{1*/ 156 int FindParam(double* pscalar, int enum_type); 157 int FindParam(int* pinteger,int enum_type); 158 int FindParam(char** pstring,int enum_type); 159 int FindParam(char*** pstringarray,int* pM,int enum_type); 160 int FindParam(double** pdoublearray,int* pM,int enum_type); 161 int FindParam(double** pdoublearray,int* pM,int* pN,int enum_type); 162 int FindParam(Vec* pvec,int enum_type); 163 int FindParam(Mat* pmat,int enum_type); 164 Object* FindParamObject(int enum_type); 165 /*}}}*/ 166 167 }; 168 169 104 170 #endif -
issm/trunk/src/c/Makefile.am
r3673 r3685 23 23 libISSM_a_SOURCES = ./objects/objects.h\ 24 24 ./objects/Object.h\ 25 ./objects/Bamg Geom.h\26 ./objects/Bamg Geom.cpp\27 ./objects/Bamg Mesh.h\28 ./objects/Bamg Mesh.cpp\29 ./objects/Bamg Opts.h\30 ./objects/Bamg Opts.cpp\25 ./objects/Bamg/BamgGeom.h\ 26 ./objects/Bamg/BamgGeom.cpp\ 27 ./objects/Bamg/BamgMesh.h\ 28 ./objects/Bamg/BamgMesh.cpp\ 29 ./objects/Bamg/BamgOpts.h\ 30 ./objects/Bamg/BamgOpts.cpp\ 31 31 ./objects/Element.h\ 32 32 ./objects/Model.h\ … … 35 35 ./objects/FemModel.cpp\ 36 36 ./objects/Material.h\ 37 ./objects/Material.cpp\38 37 ./objects/DofVec.h\ 39 38 ./objects/DofVec.cpp\ 40 39 ./objects/Load.h\ 41 ./objects/Load.cpp\42 40 ./objects/OptArgs.h\ 43 41 ./objects/OptPars.h\ … … 45 43 ./objects/Contour.h\ 46 44 ./objects/Contour.cpp\ 47 ./objects/ Friction.h\48 ./objects/ Friction.cpp\45 ./objects/Loads/Friction.h\ 46 ./objects/Loads/Friction.cpp\ 49 47 ./objects/DakotaPlugin.h\ 50 48 ./objects/DakotaPlugin.cpp\ … … 55 53 ./objects/DofIndexing.h\ 56 54 ./objects/DofIndexing.cpp\ 55 ./objects/IoModel.h\ 56 ./objects/IoModel.cpp\ 57 57 ./objects/Node.h\ 58 58 ./objects/Node.cpp\ 59 59 ./objects/Result.h\ 60 60 ./objects/Result.cpp\ 61 ./objects/ Tria.h\62 ./objects/ Tria.cpp\63 ./objects/Input Objects/Input.h\64 ./objects/Input Objects/TriaVertexInput.h\65 ./objects/Input Objects/TriaVertexInput.cpp\66 ./objects/Input Objects/SingVertexInput.h\67 ./objects/Input Objects/SingVertexInput.cpp\68 ./objects/Input Objects/BeamVertexInput.h\69 ./objects/Input Objects/BeamVertexInput.cpp\70 ./objects/Input Objects/PentaVertexInput.h\71 ./objects/Input Objects/PentaVertexInput.cpp\72 ./objects/Input Objects/BoolInput.h\73 ./objects/Input Objects/BoolInput.cpp\74 ./objects/Input Objects/IntInput.h\75 ./objects/Input Objects/IntInput.cpp\76 ./objects/Input Objects/DoubleInput.h\77 ./objects/Input Objects/DoubleInput.cpp\78 ./objects/ Sing.h\79 ./objects/ Sing.cpp\80 ./objects/ Beam.h\81 ./objects/ Beam.cpp\82 ./objects/ Penta.h\83 ./objects/ Penta.cpp\84 ./objects/Mat ice.h\85 ./objects/Mat ice.cpp\86 ./objects/Mat par.h\87 ./objects/Mat par.cpp\88 ./objects/ Spc.cpp\89 ./objects/ Spc.h\90 ./objects/ Rgb.cpp\91 ./objects/ Rgb.h\92 ./objects/ Penpair.cpp\93 ./objects/ Penpair.h\94 ./objects/ Pengrid.cpp\95 ./objects/ Pengrid.h\96 ./objects/ Icefront.cpp\97 ./objects/ Icefront.h\98 ./objects/ Riftfront.cpp\99 ./objects/ Riftfront.h\100 ./objects/ Numericalflux.cpp\101 ./objects/ Numericalflux.h\102 ./objects/Param Objects/Param.h\103 ./objects/Param Objects/BoolParam.cpp\104 ./objects/Param Objects/BoolParam.h\105 ./objects/Param Objects/IntParam.cpp\106 ./objects/Param Objects/IntParam.h\107 ./objects/Param Objects/DoubleParam.cpp\108 ./objects/Param Objects/DoubleParam.h\109 ./objects/Param Objects/PetscMatParam.cpp\110 ./objects/Param Objects/PetscMatParam.h\111 ./objects/Param Objects/StringArrayParam.cpp\112 ./objects/Param Objects/StringArrayParam.h\113 ./objects/Param Objects/DoubleMatParam.cpp\114 ./objects/Param Objects/DoubleMatParam.h\115 ./objects/Param Objects/DoubleVecParam.cpp\116 ./objects/Param Objects/DoubleVecParam.h\117 ./objects/Param Objects/PetscVecParam.cpp\118 ./objects/Param Objects/PetscVecParam.h\119 ./objects/Param Objects/StringParam.cpp\120 ./objects/Param Objects/StringParam.h\61 ./objects/Elements/Tria.h\ 62 ./objects/Elements/Tria.cpp\ 63 ./objects/Inputs/Input.h\ 64 ./objects/Inputs/TriaVertexInput.h\ 65 ./objects/Inputs/TriaVertexInput.cpp\ 66 ./objects/Inputs/SingVertexInput.h\ 67 ./objects/Inputs/SingVertexInput.cpp\ 68 ./objects/Inputs/BeamVertexInput.h\ 69 ./objects/Inputs/BeamVertexInput.cpp\ 70 ./objects/Inputs/PentaVertexInput.h\ 71 ./objects/Inputs/PentaVertexInput.cpp\ 72 ./objects/Inputs/BoolInput.h\ 73 ./objects/Inputs/BoolInput.cpp\ 74 ./objects/Inputs/IntInput.h\ 75 ./objects/Inputs/IntInput.cpp\ 76 ./objects/Inputs/DoubleInput.h\ 77 ./objects/Inputs/DoubleInput.cpp\ 78 ./objects/Elements/Sing.h\ 79 ./objects/Elements/Sing.cpp\ 80 ./objects/Elements/Beam.h\ 81 ./objects/Elements/Beam.cpp\ 82 ./objects/Elements/Penta.h\ 83 ./objects/Elements/Penta.cpp\ 84 ./objects/Materials/Matice.h\ 85 ./objects/Materials/Matice.cpp\ 86 ./objects/Materials/Matpar.h\ 87 ./objects/Materials/Matpar.cpp\ 88 ./objects/Constraints/Spc.cpp\ 89 ./objects/Constraints/Spc.h\ 90 ./objects/Constraints/Rgb.cpp\ 91 ./objects/Constraints/Rgb.h\ 92 ./objects/Loads/Penpair.cpp\ 93 ./objects/Loads/Penpair.h\ 94 ./objects/Loads/Pengrid.cpp\ 95 ./objects/Loads/Pengrid.h\ 96 ./objects/Loads/Icefront.cpp\ 97 ./objects/Loads/Icefront.h\ 98 ./objects/Loads/Riftfront.cpp\ 99 ./objects/Loads/Riftfront.h\ 100 ./objects/Loads/Numericalflux.cpp\ 101 ./objects/Loads/Numericalflux.h\ 102 ./objects/Params/Param.h\ 103 ./objects/Params/BoolParam.cpp\ 104 ./objects/Params/BoolParam.h\ 105 ./objects/Params/IntParam.cpp\ 106 ./objects/Params/IntParam.h\ 107 ./objects/Params/DoubleParam.cpp\ 108 ./objects/Params/DoubleParam.h\ 109 ./objects/Params/PetscMatParam.cpp\ 110 ./objects/Params/PetscMatParam.h\ 111 ./objects/Params/StringArrayParam.cpp\ 112 ./objects/Params/StringArrayParam.h\ 113 ./objects/Params/DoubleMatParam.cpp\ 114 ./objects/Params/DoubleMatParam.h\ 115 ./objects/Params/DoubleVecParam.cpp\ 116 ./objects/Params/DoubleVecParam.h\ 117 ./objects/Params/PetscVecParam.cpp\ 118 ./objects/Params/PetscVecParam.h\ 119 ./objects/Params/StringParam.cpp\ 120 ./objects/Params/StringParam.h\ 121 121 ./objects/NodeSets.cpp\ 122 122 ./objects/NodeSets.h\ 123 123 ./DataSet/DataSet.cpp\ 124 124 ./DataSet/DataSet.h\ 125 ./DataSet/Inputs.cpp\126 ./DataSet/Inputs.h\127 ./DataSet/Parameters.cpp\128 ./DataSet/Parameters.h\129 125 ./shared/shared.h\ 130 126 ./shared/Alloc/alloc.h\ … … 228 224 ./EnumDefinitions/EnumDefinitions.cpp\ 229 225 ./ModelProcessorx/ModelProcessorx.h\ 230 ./ModelProcessorx/IoModel.h\231 ./ModelProcessorx/IoModel.cpp\232 226 ./ModelProcessorx/Partitioning.cpp\ 233 227 ./ModelProcessorx/CreateDataSets.cpp\ … … 456 450 ./objects/Object.h\ 457 451 ./objects/BamgGeom.h\ 458 ./objects/Bamg Geom.cpp\459 ./objects/Bamg Mesh.h\460 ./objects/Bamg Mesh.cpp\461 ./objects/Bamg Opts.h\462 ./objects/Bamg Opts.cpp\452 ./objects/Bamg/BamgGeom.cpp\ 453 ./objects/Bamg/BamgMesh.h\ 454 ./objects/Bamg/BamgMesh.cpp\ 455 ./objects/Bamg/BamgOpts.h\ 456 ./objects/Bamg/BamgOpts.cpp\ 463 457 ./objects/Element.h\ 464 458 ./objects/Model.h\ … … 467 461 ./objects/FemModel.cpp\ 468 462 ./objects/Material.h\ 469 ./objects/Material.cpp\470 463 ./objects/DofVec.h\ 471 464 ./objects/DofVec.cpp\ 472 465 ./objects/Load.h\ 473 ./objects/Load.cpp\474 466 ./objects/SolverEnum.h\ 475 467 ./objects/Contour.h\ … … 477 469 ./objects/OptArgs.h\ 478 470 ./objects/OptPars.h\ 479 ./objects/ Friction.h\480 ./objects/ Friction.cpp\471 ./objects/Loads/Friction.h\ 472 ./objects/Loads/Friction.cpp\ 481 473 ./objects/DakotaPlugin.h\ 482 474 ./objects/DakotaPlugin.cpp\ 483 475 ./objects/DofIndexing.h\ 484 476 ./objects/DofIndexing.cpp\ 477 ./objects/IoModel.h\ 478 ./objects/IoModel.cpp\ 485 479 ./objects/Node.h\ 486 480 ./objects/Node.cpp\ … … 491 485 ./objects/Result.h\ 492 486 ./objects/Result.cpp\ 493 ./objects/ Tria.h\494 ./objects/ Tria.cpp\495 ./objects/Input Objects/Input.h\496 ./objects/Input Objects/TriaVertexInput.h\497 ./objects/Input Objects/TriaVertexInput.cpp\498 ./objects/Input Objects/SingVertexInput.h\499 ./objects/Input Objects/SingVertexInput.cpp\500 ./objects/Input Objects/BeamVertexInput.h\501 ./objects/Input Objects/BeamVertexInput.cpp\502 ./objects/Input Objects/PentaVertexInput.h\503 ./objects/Input Objects/PentaVertexInput.cpp\504 ./objects/Input Objects/BoolInput.h\505 ./objects/Input Objects/BoolInput.cpp\506 ./objects/Input Objects/IntInput.h\507 ./objects/Input Objects/IntInput.cpp\508 ./objects/Input Objects/DoubleInput.h\509 ./objects/Input Objects/DoubleInput.cpp\510 ./objects/ Sing.h\511 ./objects/ Sing.cpp\512 ./objects/ Beam.h\513 ./objects/ Beam.cpp\514 ./objects/ Penta.h\515 ./objects/ Penta.cpp\516 ./objects/Mat ice.h\517 ./objects/Mat ice.cpp\518 ./objects/Mat par.h\519 ./objects/Mat par.cpp\520 ./objects/ Spc.cpp\521 ./objects/ Spc.h\522 ./objects/ Rgb.cpp\523 ./objects/ Rgb.h\524 ./objects/ Penpair.cpp\525 ./objects/ Penpair.h\526 ./objects/ Pengrid.cpp\527 ./objects/ Pengrid.h\528 ./objects/ Icefront.cpp\529 ./objects/ Icefront.h\530 ./objects/ Riftfront.cpp\531 ./objects/ Riftfront.h\532 ./objects/ Numericalflux.cpp\533 ./objects/ Numericalflux.h\534 ./objects/Param Objects/Param.h\535 ./objects/Param Objects/BoolParam.cpp\536 ./objects/Param Objects/BoolParam.h\537 ./objects/Param Objects/IntParam.cpp\538 ./objects/Param Objects/IntParam.h\539 ./objects/Param Objects/DoubleParam.cpp\540 ./objects/Param Objects/DoubleParam.h\541 ./objects/Param Objects/PetscMatParam.cpp\542 ./objects/Param Objects/PetscMatParam.h\543 ./objects/Param Objects/StringArrayParam.cpp\544 ./objects/Param Objects/StringArrayParam.h\545 ./objects/Param Objects/DoubleMatParam.cpp\546 ./objects/Param Objects/DoubleMatParam.h\547 ./objects/Param Objects/DoubleVecParam.cpp\548 ./objects/Param Objects/DoubleVecParam.h\549 ./objects/Param Objects/PetscVecParam.cpp\550 ./objects/Param Objects/PetscVecParam.h\551 ./objects/Param Objects/StringParam.cpp\552 ./objects/Param Objects/StringParam.h\487 ./objects/Elements/Tria.h\ 488 ./objects/Elements/Tria.cpp\ 489 ./objects/Inputs/Input.h\ 490 ./objects/Inputs/TriaVertexInput.h\ 491 ./objects/Inputs/TriaVertexInput.cpp\ 492 ./objects/Inputs/SingVertexInput.h\ 493 ./objects/Inputs/SingVertexInput.cpp\ 494 ./objects/Inputs/BeamVertexInput.h\ 495 ./objects/Inputs/BeamVertexInput.cpp\ 496 ./objects/Inputs/PentaVertexInput.h\ 497 ./objects/Inputs/PentaVertexInput.cpp\ 498 ./objects/Inputs/BoolInput.h\ 499 ./objects/Inputs/BoolInput.cpp\ 500 ./objects/Inputs/IntInput.h\ 501 ./objects/Inputs/IntInput.cpp\ 502 ./objects/Inputs/DoubleInput.h\ 503 ./objects/Inputs/DoubleInput.cpp\ 504 ./objects/Elements/Sing.h\ 505 ./objects/Elements/Sing.cpp\ 506 ./objects/Elements/Beam.h\ 507 ./objects/Elements/Beam.cpp\ 508 ./objects/Elements/Penta.h\ 509 ./objects/Elements/Penta.cpp\ 510 ./objects/Materials/Matice.h\ 511 ./objects/Materials/Matice.cpp\ 512 ./objects/Materials/Matpar.h\ 513 ./objects/Materials/Matpar.cpp\ 514 ./objects/Constraints/Spc.cpp\ 515 ./objects/Constraints/Spc.h\ 516 ./objects/Constraints/Rgb.cpp\ 517 ./objects/Constraints/Rgb.h\ 518 ./objects/Loads/Penpair.cpp\ 519 ./objects/Loads/Penpair.h\ 520 ./objects/Loads/Pengrid.cpp\ 521 ./objects/Loads/Pengrid.h\ 522 ./objects/Loads/Icefront.cpp\ 523 ./objects/Loads/Icefront.h\ 524 ./objects/Loads/Riftfront.cpp\ 525 ./objects/Loads/Riftfront.h\ 526 ./objects/Loads/Numericalflux.cpp\ 527 ./objects/Loads/Numericalflux.h\ 528 ./objects/Params/Param.h\ 529 ./objects/Params/BoolParam.cpp\ 530 ./objects/Params/BoolParam.h\ 531 ./objects/Params/IntParam.cpp\ 532 ./objects/Params/IntParam.h\ 533 ./objects/Params/DoubleParam.cpp\ 534 ./objects/Params/DoubleParam.h\ 535 ./objects/Params/PetscMatParam.cpp\ 536 ./objects/Params/PetscMatParam.h\ 537 ./objects/Params/StringArrayParam.cpp\ 538 ./objects/Params/StringArrayParam.h\ 539 ./objects/Params/DoubleMatParam.cpp\ 540 ./objects/Params/DoubleMatParam.h\ 541 ./objects/Params/DoubleVecParam.cpp\ 542 ./objects/Params/DoubleVecParam.h\ 543 ./objects/Params/PetscVecParam.cpp\ 544 ./objects/Params/PetscVecParam.h\ 545 ./objects/Params/StringParam.cpp\ 546 ./objects/Params/StringParam.h\ 553 547 ./objects/NodeSets.cpp\ 554 548 ./objects/NodeSets.h\ 555 549 ./DataSet/DataSet.cpp\ 556 550 ./DataSet/DataSet.h\ 557 ./DataSet/Inputs.cpp\558 ./DataSet/Inputs.h\559 ./DataSet/Parameters.cpp\560 ./DataSet/Parameters.h\561 551 ./shared/shared.h\ 562 552 ./shared/Threads/issm_threads.h\ … … 657 647 ./EnumDefinitions/EnumDefinitions.cpp\ 658 648 ./ModelProcessorx/ModelProcessorx.h\ 659 ./ModelProcessorx/IoModel.h\660 ./ModelProcessorx/IoModel.cpp\661 649 ./ModelProcessorx/Partitioning.cpp\ 662 650 ./ModelProcessorx/CreateDataSets.cpp\ -
issm/trunk/src/c/ModelProcessorx/CreateDataSets.cpp
r3673 r3685 9 9 #endif 10 10 11 #include ". /IoModel.h"11 #include "../objects/objects.h" 12 12 #include "../shared/shared.h" 13 13 #include "../include/macros.h" -
issm/trunk/src/c/ModelProcessorx/CreateParameters.cpp
r3673 r3685 9 9 #include "../shared/shared.h" 10 10 #include "../MeshPartitionx/MeshPartitionx.h" 11 #include "./IoModel.h"12 11 13 12 void CreateParameters(Parameters** pparameters,IoModel* iomodel,ConstDataHandle iomodel_handle){ -
issm/trunk/src/c/ModelProcessorx/Partitioning.cpp
r3673 r3685 10 10 11 11 #include <string.h> 12 #include ". /IoModel.h"12 #include "../objects/objects.h" 13 13 #include "../shared/shared.h" 14 14 #include "../EnumDefinitions/EnumDefinitions.h" 15 15 #include "../include/macros.h" 16 #include "../io/io.h" 16 17 #include "../include/typedefs.h" 17 18 #include "../MeshPartitionx/MeshPartitionx.h" -
issm/trunk/src/c/io/FetchParams.cpp
r3673 r3685 12 12 13 13 #include <mex.h> 14 15 #include "../objects/Param.h"16 14 #include "./io.h" 15 #include "../objects/objects.h" 17 16 #include "../shared/shared.h" 18 17 #include "../include/macros.h" 18 #include "../EnumDefinitions/EnumDefinitions.h" 19 19 20 20 void FetchParams(DataSet** pparameters, DataHandle dataref){ 21 21 22 22 int i,j; 23 int count; 23 24 24 25 /*output: */ -
issm/trunk/src/c/io/IoModelFetchData.cpp
r3570 r3685 10 10 11 11 #include "./io.h" 12 #include "../ModelProcessorx/IoModel.h"13 #include "../shared/shared.h"14 #include "../include/macros.h"15 12 16 13 #ifdef _SERIAL_ -
issm/trunk/src/c/io/WriteParams.cpp
r3673 r3685 13 13 #include <mex.h> 14 14 15 #include "../objects/Param.h"16 15 #include "./io.h" 16 #include "../objects/objects.h" 17 17 #include "../shared/shared.h" 18 18 #include "../include/macros.h" -
issm/trunk/src/c/io/io.h
r3673 r3685 3 3 */ 4 4 5 #ifndef IO_H_6 #define IO_H_5 #ifndef _IO_H_ 6 #define _IO_H_ 7 7 8 #include "../objects/NodeSets.h" 9 #include "../objects/DofVec.h" 10 #include "../objects/BamgMesh.h" 11 #include "../objects/BamgGeom.h" 8 #include "../objects/objects.h" 12 9 #include "../DataSet/DataSet.h" 13 10 #include "../include/types.h" … … 59 56 #endif 60 57 61 62 63 64 65 58 #ifdef _PARALLEL_ 66 59 void FetchData(double** pmatrix, int* pM,int* pN,FILE* fid); … … 83 76 84 77 85 86 87 88 78 #endif /* _IO_H_ */ -
issm/trunk/src/c/shared/Elements/GetVerticesCoordinates.cpp
r3162 r3685 3 3 */ 4 4 5 #include "../../objects/ Node.h"5 #include "../../objects/objects.h" 6 6 7 7 int GetVerticesCoordinates( double* xyz, Node** nodes, int numgrids){ -
issm/trunk/src/c/shared/Numerics/numerics.h
r3673 r3685 8 8 #include "./GaussPoints.h" 9 9 #include "./isnan.h" 10 #include "../../objects/OptArgs.h" 11 #include "../../objects/OptPars.h" 10 11 struct OptArgs; 12 struct OptPars; 12 13 13 14 double min(double a,double b);
Note:
See TracChangeset
for help on using the changeset viewer.