#include <dbcrs.h>
Public Member Functions | |
dbcrs (void) | |
void | mark_used (long ic, long csti) |
marks ic-th corss-section type and its csti-th parameter set as used | |
long | read (XFILE *in) |
reads cross section parameters from the opened text file as strings | |
long | readmc (XFILE *in, mechcrsec *mechc, descrip *d) |
reads cross section parameters from the opened text file with help of mechcrsec procedures | |
void | renumber_id (void) |
renumbers database indeces according with used cross-sections | |
long | search_crs (crsectype ce, long ci) |
searching cross-section with given type and index | |
~dbcrs (void) | |
Public Attributes | |
csec * | crs |
array with cross-sections | |
long * | crsu |
array with indicators of cross-section usage in the given problem | |
long | ncrsu |
number of cross-sections used in the given problem | |
long | numt |
number of cross-section entries |
Cross-section database class
Created by Tomas Koudelka, koudelka@cml.fsv.cvut.cz
Definition at line 39 of file dbcrs.h.
dbcrs | ( | void | ) |
~dbcrs | ( | void | ) |
Destructor which deletes cross-section database.
Created by Tomas Koudelka koudelka@cml.fsv.cvut.cz, 11. 2001
void mark_used | ( | long | ic, | |
long | csti | |||
) |
marks ic-th corss-section type and its csti-th parameter set as used
The method marks of used cross-section type and its instance(parameters). Eventually, it increases the number of used cs types and instances(property) of the given cs type.
ic | - index of cross-section type in the database | |
csti | - index of cross-section type instance(prarameters) |
Created by Tomas Koudelka koudelka@cml.fsv.cvut.cz, 7. 2009
Definition at line 288 of file dbcrs.cpp.
References crs, crsu, csec::instu, ncrsu, and csec::ninstu.
Referenced by input_elem_crsec(), and input_nod_crsec().
long read | ( | XFILE * | in | ) |
reads cross section parameters from the opened text file as strings
The method reads cross section characteristics from the opened text file. The parameters are stored as strings
in | - pointer to the opened file |
0 | - on success | |
i>0 | - in case of failure in the reading of i-th material type |
Created by TKo, 6.2014
Definition at line 178 of file dbcrs.cpp.
References crs, crsu, memset(), numt, and xfscanf().
Referenced by input_crs().
reads cross section parameters from the opened text file with help of mechcrsec procedures
The method reads material characteristics from the opened text file with help of mechcrsec procedures.
in | - pointer to the opened file | |
mechc | - pointer to the allocated mechcrsec structure | |
d | - pointer to structure with description of preprocessor setup |
0 | - on success | |
i>0 | - in case of failure in the reading of i-th cross section type |
Created by TKo, 6.2014
Definition at line 212 of file dbcrs.cpp.
References csec::allocmc(), crs, crsectype_kwdset(), crsu, mechcrsec::cstype, ignore, XFILE::index_created, XFILE::kwdmode, descrip::matkwd, memset(), mechcrsec::ncst, csec::ninst, no, numt, mechcrsec::numtype, mechcrsec::readcrsectype(), sect_mode_ignore, csec::type, type, and xfscanf().
Referenced by input_crs().
void renumber_id | ( | void | ) |
renumbers database indeces according with used cross-sections
The method renumbers indeces of used instances of cross-section types.
Created by Tomas Koudelka koudelka@cml.fsv.cvut.cz, 7. 2009
Definition at line 309 of file dbcrs.cpp.
References crs, csec::ninst, numt, and csec::ridx.
Referenced by output().
long search_crs | ( | crsectype | ce, | |
long | ci | |||
) |
searching cross-section with given type and index
This method searches database whether contains cross-section with type number ce and type index number ci.
ce | - cross-section type number | |
ci | - cross-section type index |
Returns :
If | the cross-section with given parameters exists in the database function returns index of given cross-section in the array crs else returns -1. |
Created by Tomas Koudelka koudelka@cml.fsv.cvut.cz, 11. 2001
Definition at line 261 of file dbcrs.cpp.
References crs, numt, and type.
Referenced by input_elem_crsec(), and input_nod_crsec().
array with cross-sections
Definition at line 48 of file dbcrs.h.
Referenced by dbcrs(), mark_used(), read(), readmc(), renumber_id(), search_crs(), wr_crsecs(), wr_elements(), wr_lay_elements(), wr_lay_nodes(), wr_nodes(), and ~dbcrs().
long* crsu |
long ncrsu |
number of cross-sections used in the given problem
Definition at line 50 of file dbcrs.h.
Referenced by dbcrs(), mark_used(), and wr_crsecs().
long numt |
number of cross-section entries
Definition at line 47 of file dbcrs.h.
Referenced by dbcrs(), read(), readmc(), renumber_id(), search_crs(), and wr_crsecs().