#include <dbmat.h>
Public Member Functions | |
dbmat (void) | |
void | mark_used (long ic, long csti) |
marks used materials | |
long | read (XFILE *in) |
reads materials from the text file as strings | |
long | readmm (XFILE *in, mechmat *mechm, descrip *d) |
reads materials from the text file via mechmat procedures | |
void | renumber_id (void) |
renumbers instance indeces of particular material types | |
long | search_mat (mattype ce, long ci) |
searches material database for the given material type and index | |
~dbmat (void) | |
Public Attributes | |
matr * | mat |
array with materials | |
long * | matu |
array with indicators of material usage in the given problem | |
long | nmatu |
number of used materials in the given problem | |
long | numt |
number of material entries |
Material database class
Created by Tomas Koudelka, koudelka@cml.fsv.cvut.cz
Definition at line 47 of file dbmat.h.
dbmat | ( | void | ) |
~dbmat | ( | void | ) |
Destructor which deletes material database.
Created by Tomas Koudelka koudelka@cml.fsv.cvut.cz, 11. 2001
void mark_used | ( | long | im, | |
long | mti | |||
) |
marks used materials
The method marks of used material type and its instance(parameters). Eventually, it increases the number of used material types and instances(properties) of the given material type.
im | - index of material type in the database | |
mti | - index of material type instance(prarameters) |
Created by Tomas Koudelka koudelka@cml.fsv.cvut.cz, 7. 2009
Definition at line 289 of file dbmat.cpp.
References matr::instu, mat, matu, matr::ninstu, and nmatu.
Referenced by input_elem_mat(), and input_nod_springs().
long read | ( | XFILE * | in | ) |
reads materials from the text file as strings
The method reads material characteristics from the opened text file. The characteristic 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 180 of file dbmat.cpp.
References mat, matu, memset(), numt, and xfscanf().
Referenced by input_materials().
reads materials from the text file via mechmat procedures
The method reads material characteristics from the opened text file with help of mechmat procedures.
in | - pointer to the opened file | |
mechm | - pointer to the allocated mechmat 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 material type |
Created by TKo, 6.2014
Definition at line 214 of file dbmat.cpp.
References matr::allocmm(), ignore, XFILE::index_created, XFILE::kwdmode, mat, descrip::matkwd, mattype_kwdset(), matu, memset(), mechmat::mtype, matr::ninst, mechmat::nmt, no, numt, mechmat::numtype, mechmat::readmattype(), sect_mode_ignore, matr::type, type, and xfscanf().
Referenced by input_materials().
void renumber_id | ( | void | ) |
renumbers instance indeces of particular material types
The method renumbers indeces of used instances of material types.
Created by Tomas Koudelka koudelka@cml.fsv.cvut.cz, 7. 2009
Definition at line 310 of file dbmat.cpp.
References mat, matr::ninst, numt, and matr::ridx.
Referenced by output().
long search_mat | ( | mattype | ce, | |
long | ci | |||
) |
searches material database for the given material type and index
This method searches database whether contains material with type number ce and type index number ci.
ce | - material type number | |
ci | - material type index |
Returns :
If | the material with given parameters exists in the database function returns index of given material in the array crs else returns -1. |
Created by Tomas Koudelka koudelka@cml.fsv.cvut.cz, 11. 2001
Definition at line 263 of file dbmat.cpp.
References mat, numt, and type.
Referenced by input_elem_mat(), and input_nod_springs().
array with materials
Definition at line 51 of file dbmat.h.
Referenced by dbmat(), mark_used(), read(), readmm(), renumber_id(), search_mat(), wr_elements(), wr_lay_elements(), wr_materials(), and ~dbmat().
long* matu |
long nmatu |
number of used materials in the given problem
Definition at line 53 of file dbmat.h.
Referenced by dbmat(), mark_used(), and wr_materials().
long numt |
number of material entries
Definition at line 50 of file dbmat.h.
Referenced by dbmat(), read(), readmm(), renumber_id(), search_mat(), and wr_materials().