#include <string.h>
#include "iotools.h"
#include "kwdset.h"
#include "vector.h"
#include "siftop.h"
#include "gfunct.h"
#include "alias.h"
#include "global.h"
#include "inicd.h"
#include "globprep.h"
#include "loadel.h"
#include "prepalias.h"
#include "input.h"
#include "hangnode.h"
#include "bocon.h"
#include "dbcrs.h"
#include "dbmat.h"
#include "entityload.h"
#include "pointset.h"
#include "tempload.h"
#include "aggregator.h"
Go to the source code of this file.
Functions | |
long | give_lt_id (elloadtype tel) |
long | input (XFILE *in, descrip *d) |
main function for input from the preprocessor file | |
long | input_crs (XFILE *in, descrip *d) |
input cross-section from the the corresponding section of the preprocessor file | |
long | input_crs (char *fname, descrip *d) |
input cross-section from the cross-section file | |
long | input_elem_crsec (XFILE *in, const enumstr elemsects[], long nsect) |
assignment of element cross-section types | |
long | input_elem_eigstr (XFILE *in, const enumstr elemsects[], long nsect) |
asignment of eigenstrains to elements | |
long | input_elem_eltimefunc (XFILE *in, const enumstr elemsects[], long nsect) |
assignment of time functions to elements | |
long | input_elem_lcs (XFILE *in, const enumstr elemsects[], long nsect) |
assignment of local coordinate systems | |
long | input_elem_load (XFILE *in, const enumstr elemsects[], long nsect) |
assignment of load defined at particular elements | |
long | input_elem_loadedge (XFILE *in, const enumstr elemsects[], long nsect) |
assignment edge load to elements | |
long | input_elem_loadsurf (XFILE *in, const enumstr elemsects[], long nsect) |
assignment surface load to elements | |
long | input_elem_loadvol (XFILE *in, const enumstr elemsects[], long nsect) |
assignment of volume load to elements | |
long | input_elem_mat (XFILE *in, const enumstr elemsects[], long nsect) |
assignment of element material types | |
long | input_elem_type (XFILE *in, const enumstr elemsects[], long nsect) |
assignment of element types | |
long | input_elemprop (XFILE *in) |
input of element properties | |
long | input_files (XFILE *in, descrip &d) |
reading of topology, material and cross section files | |
long | input_hang_nodes (XFILE *in) |
input of hanging nodes from the separate file | |
long | input_lc (XFILE *in) |
input of description of load cases | |
long | input_materials (XFILE *in, descrip *d) |
input material from the corresponding section of the preprocessor file | |
long | input_materials (char *fname, descrip *d) |
input material from the material file | |
long | input_nod_bocon (XFILE *in, const enumstr nodsects[], long nsect) |
assignment of boundary conditions at nodes | |
long | input_nod_coupl_dofs (XFILE *in, const enumstr nodsects[], long nsect) |
assignment of coupled dofs at nodes | |
long | input_nod_crsec (XFILE *in, const enumstr nodsects[], long nsect) |
assignment of cross-setions at nodes | |
long | input_nod_dof_tfunc (XFILE *in, const enumstr nodsects[], long nsect) |
assignment of time functions cotrolling dofs at nodes | |
long | input_nod_initcond (XFILE *in, const enumstr nodsects[], long nsect) |
assignment of initial conditions at nodes | |
long | input_nod_lcs (XFILE *in, const enumstr nodsects[], long nsect) |
assignment of local coordinate systems at nodes | |
long | input_nod_load (XFILE *in, const enumstr nodsects[], long nsect) |
assignment of nodal load | |
long | input_nod_ndof (XFILE *in, const enumstr nodsects[], long nsect) |
assignment of dofs at nodes | |
long | input_nod_springs (XFILE *in, const enumstr nodsects[], long nsect) |
assignment of spring supports at nodes | |
long | input_nod_tdload (XFILE *in, const enumstr nodsects[], long nsect) |
assignment of nodal time dependent load | |
long | input_nod_temper (XFILE *in, const enumstr nodsects[], long nsect) |
assignment of temparture load at nodes | |
long | input_nodprop (XFILE *in) |
input of nodal properties | |
long | input_siftop (XFILE *in, descrip *d) |
input topolgy using siftop class | |
const gentity | operator-- (gentity &a, int) |
long give_lt_id | ( | elloadtype | tel | ) |
Function converts load type alias to long index with different sequence of load types. Tel has sequence volume=1, edge=2, surface=3 and resulting index has following values: edge = 0, surface = 1, volume = 2. The function returns -1 for rest values of tel.
tel | - alias of converted load type. |
Returns:
-1 | - for unknown or unsupported alias | |
0 | - for edge load type | |
1 | - for surface load type | |
2 | - for volume load type |
Definition at line 5142 of file input.cpp.
References edge, surface, and volume.
Referenced by input_elem_load().
main function for input from the preprocessor file
Function reads problem data from file in a writes it to file out in SIFEL format.
in | - pointer to opened input file | |
d | - pointer to structure with description of preprocessor setup |
0 | - on succes | |
1 | - unable to open temporary file | |
2 | - if fails reading number of loading cases | |
3 | - if fails reading topology | |
4 | - if fails reading materials | |
5 | - if fails reading cross-sections | |
6 | - if fails reading property file | |
7 | - if fails writing output file |
Definition at line 39 of file input.cpp.
References precond::agg, boss, descrip::crf, descrip::crssec, descrip::hangnf, ignore, XFILE::ignorecase, aggregator::impl, input_crs(), input_elemprop(), input_hang_nodes(), input_lc(), input_materials(), input_nodprop(), input_siftop(), XFILE::kwdmode, descrip::matf, descrip::matsec, Mp, no, Nod_hang, Numhn, descrip::paral, slesolv::prec, print_err(), precond::pt, sfeti, probdesc::ssle, slesolv::tlinsol, descrip::topf, XFILE::warning, xfclose(), and xfopen().
Referenced by main().
input cross-section from the the corresponding section of the preprocessor file
Function reads cross-section database from file with name given by the fname.
in | - pointer to the opened XFILE file | |
d | - pointer to structure with description of preprocessor setup |
Returns :
0 | - on succes | |
1 | - if fails opening file | |
2 | - if fails reading cross-section parameters |
Created by TKo, 06.2014
Definition at line 1021 of file input.cpp.
References begsec_crsec, bsec_str, descrip::crsstr, Dbcrs, XFILE::ignorecase, XFILE::kwdmode, Mc, Mespr, dbcrs::read(), dbcrs::readmc(), sect_mode_seq, XFILE::warning, xf_setsec(), and yes.
long input_crs | ( | char * | fname, | |
descrip * | d | |||
) |
input cross-section from the cross-section file
Function reads cross-section database from file with name given by the fname.
fname | - string with database file name | |
d | - pointer to structure with description of preprocessor setup |
Returns :
0 | - on succes | |
1 | - if fails opening file | |
2 | - if fails reading cross-section parameters |
Created by TKo
Definition at line 974 of file input.cpp.
References descrip::crsstr, Dbcrs, XFILE::ignorecase, XFILE::kwdmode, Mc, Mespr, dbcrs::read(), dbcrs::readmc(), sequent_mode, XFILE::warning, xfclose(), xfopen(), and yes.
Referenced by input().
assignment of element cross-section types
The function assigns cross-section type to the elements. It scans sections eledgpr, elsurfpr, elvolpr for keyword "el_type". The record which assigns cross-section type to the element looks like follows: "el_crsec" "propid" prop crsec_type crsec_id where prop is positive integer number.
The asssigning starts at section for volumes and finishes at section for edges. If an element belongs to several entities and different cross-section types are prescribed for these entities, error of assignment is signalized.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array elemsects |
Returns :
0 | - on succes | |
1 | - cannot find required cross-section in database | |
2 | - different cross-section types have been assigned to one element | |
3 | - property numbers of the required entity type have not been read on elements | |
4 | - property number of the required entity type have not been found on elements |
Definition at line 3548 of file input.cpp.
References Check_unused_prop, XFILE::col, crsectype_kwdset(), Dbcrs, El_cst, El_cstdbi, El_csti, entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, dbcrs::mark_used(), memset(), print_err(), dbcrs::search_crs(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, xf_setsec(), and xfscanf().
Referenced by input_elemprop().
asignment of eigenstrains to elements
The function assigns eigenstrains to the elements with with required property. It scans sections elemedgpr, elemsurfpr, elemvolpr for keyword "el_eigstr". The record which assigns eigenstrains to elements looks like follows: "el_eigstr" "propid" prop "ncomp" nc "eigstr_comp" {time_functions_of_eigenstrain_components}xnc
The asssigning starts at section for volumes and finishes at section for edges. In case of multiple assigning of different eigen strains, error of assignment is signalized.
in | - pointer to opened input file with property description | |
elemsects | - array with descriptors of sections, which will be searched nsect - number of searched sections i.e number of elements in array elemsects |
Returns :
0 | - on succes | |
1 | - read error of gfunct | |
2 | - multiple assignment of nonidentical eigenstrains | |
3 | - incompatible number of assigned eigenstrain componennts with element | |
4 | - property numbers of the required entity type have not been read on elements | |
5 | - property number of the required entity type have not been found on elements |
Definition at line 4769 of file input.cpp.
References list::append(), list::at(), Check_unused_prop, XFILE::col, gfunct::compare(), list::count(), El_eigstr, El_eigstrgf_lst, entitypstr, XFILE::fname, getkwd_sect(), mechtop::give_tncomp(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), Mt, print_err(), gfunct::read(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, xf_setsec(), and xfscanf().
Referenced by input_elemprop().
assignment of time functions to elements
Function reads time functions for switching on/off of given elements. It scans sections eledgpr, elsurfpr, elvolpr for keyword "el_tfunct". The record which assigns volume load to the element looks like follows: "el_tfunct" "propid" prop "el_tfunc" time_function_id where prop is positive integer number.
The asssigning starts at section for volumes and finishes at section for vertices. In case of multiple assigning of different time functions, error of assignment is signalized.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - assignment of different time function at one element | |
2 | - property numbers of the required entity type have not been read on elements | |
3 | - element have not assigned a time function | |
4 | - property number of the required entity type have not been found on elements |
Definition at line 4952 of file input.cpp.
References Check_unused_prop, XFILE::col, El_tfunc, entitypstr, XFILE::fname, getkwd_sect(), gregion, growing_mech_structure, Gtm, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, memset(), Mp, gtopology::ngf, print_err(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, probdesc::tprob, xf_setsec(), and xfscanf().
Referenced by input_elemprop().
assignment of local coordinate systems
Function reads local coordinate systems defined at elements. It scans sections elemedgpr, elemsurfpr, elemvolpr for keyword "el_lcs". The record which assigns local coordinate system to elements looks like follows: "el_lcs" "propid" prop "dim" vect_dim {"basevec" base_vector_components}[vect_dim]
The asssigning starts at section for volumes and finishes at section for edges. In case of multiple assigning of different local coordinate systems, error of assignment is signalized.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array elemsects |
Returns :
0 | - on succes | |
1 | - invalid dimension of base vectors | |
2 | - property numbers of the required entity type have not been read on elements | |
3 | - property number of the required entity type have not been found on elements |
Definition at line 3702 of file input.cpp.
References allocv(), Check_unused_prop, XFILE::col, copyv(), El_lcs, entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, memset(), print_err(), readv(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, xf_setsec(), and xfscanf().
Referenced by input_elemprop().
assignment of load defined at particular elements
The function assigns different types of load defined at particular elements to the elements with the required property. It scans sections eledgpr, elsurfpr, elvolpr for keyword "el_load". The record which assigns volume load to the element looks like follows: "el_load" "propid" prop "lc_id" load_case_index "load_type" type_of_load "nedge"|"nsurf"|"" number_of_elem_edges|surfaces| "ncomp" total_number_of_load_componets {load_components}[ncomp] where prop is positive integer number. For more details see loadel.cpp|h
The asssigning starts at section for volumes and finishes at section for edges. If an element belongs to several entities and different load types are prescribed for these entities, merging of load is performed.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array elemsects |
Returns :
0 | - on succes | |
1 | - invalid load/subload case index | |
2 | - unknown type of load or load cannot be read | |
3 | - merging of load failured | |
4 | - property numbers of the required entity type have not been read on elements | |
5 | - property number of the required entity type have not been found on elements |
Definition at line 3886 of file input.cpp.
References Check_unused_prop, XFILE::col, El_load, El_loadcol, El_loadln, entitypstr, XFILE::fname, getkwd_sect(), give_lt_id(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), loadel::merge(), loadel::nlc, Nlc, loadel::nslc, Nslc, Nslc_cum, print_err(), loadel::read_prep(), sect_mode_full, sect_mode_fwd, sect_mode_seq, loadel::tel, Tnslc, Top, xf_setsec(), and xfscanf().
Referenced by input_elemprop().
assignment edge load to elements
The function assigns edge load to the elements with with required edge property. It scans sections eledgpr for keyword "edge_load". The record which assigns edge load to the element looks like follows: "edge_load" "propid" prop "lc_id" load_case_index "ncomp" total_number_of_load_componets {load_components}[ncomp] where prop is positive integer number. For more details see entityload.cpp|h
The asssigning scans only section for edges. If an element belongs to several entities and different load types are prescribed for these entities, merging of load is performed.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array elemsects |
Returns :
0 | - on succes | |
1 | - read error | |
2 | - merging of load failured | |
3 | - property numbers of the required entity type have not been read on elements | |
4 | - property number of the required entity type have not been found on elements |
Definition at line 4097 of file input.cpp.
References Check_unused_prop, XFILE::col, entityload::edge2loadel(), El_load, El_loadcol, El_loadln, entitypstr, XFILE::fname, gcurve, getkwd_sect(), XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), loadel::merge(), entityload::nlc, Nlc, entityload::nslc, Nslc, Nslc_cum, print_err(), entityload::read(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Tnslc, Top, xf_setsec(), and xfscanf().
Referenced by input_elemprop().
assignment surface load to elements
The function assigns surface load to the elements with with required surface property. It scans sections elsurfpr for keyword "el_surfload". The record which assigns surface load to the element looks like follows: "el_surfload" "propid" prop "lc_id" load_case_index "ncomp" total_number_of_load_componets {load_components}[ncomp] where prop is positive integer number. For more details see entityload.cpp|h
The asssigning scans only section for surfaces. If an element belongs to several entities and different load types are prescribed for these entities, merging of load is performed.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array elemsects |
Returns :
0 | - on succes | |
1 | - read error | |
2 | - merging of load failured | |
3 | - property numbers of the required entity type have not been read on elements | |
4 | - property number of the required entity type have not been found on elements |
Definition at line 4320 of file input.cpp.
References Check_unused_prop, XFILE::col, El_load, El_loadcol, El_loadln, entitypstr, XFILE::fname, getkwd_sect(), gsurface, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), loadel::merge(), entityload::nlc, Nlc, entityload::nslc, Nslc, Nslc_cum, print_err(), entityload::read(), sect_mode_full, sect_mode_fwd, sect_mode_seq, entityload::surface2loadel(), Tnslc, Top, xf_setsec(), and xfscanf().
Referenced by input_elemprop().
assignment of volume load to elements
The function assigns volume load to the elements with with required volume property. It scans sections elsurfpr for keyword "el_surfload". The record which assigns surface load to the element looks like follows: "el_surfload" "propid" prop "lc_id" load_case_index "ncomp" total_number_of_load_componets {load_components}[ncomp] where prop is positive integer number. For more details see entityload.cpp|h
The asssigning scans only section for surfaces. If an element belongs to several entities and different load types are prescribed for these entities, merging of load is performed.
in | - pointer to opened input file with property description | |
elemsects | - array with descriptors of sections, which will be searched nsect - number of searched sections i.e number of elements in array elemsects |
Returns :
0 | - on succes | |
1 | - read error | |
2 | - merging of load failured | |
3 | - property numbers of the required entity type have not been read on elements | |
4 | - property number of the required entity type have not been found on elements |
Definition at line 4545 of file input.cpp.
References Check_unused_prop, XFILE::col, El_load, El_loadcol, El_loadln, entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), loadel::merge(), entityload::nlc, Nlc, entityload::nslc, Nslc, Nslc_cum, print_err(), entityload::read(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Tnslc, Top, entityload::vol2loadel(), xf_setsec(), and xfscanf().
Referenced by input_elemprop().
assignment of element material types
The function assigns material type to the elements. It scans sections eledgpr, elsurfpr, elvolpr for keyword "el_type". The record which assigns material type to the element looks like follows: "el_mat" "propid" prop "num_mat" nmat nmat*{"type" material_type "type_id" material_id} where prop is positive integer number.
The asssigning starts at section for volumes and finishes at section for edges. If an element belongs to several entities and different material types are prescribed for these entities, error of assignment is signalized. Finally, the function checks whether all elements have assigned a material type.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array elemsects |
Returns :
0 | - on succes | |
1 | - different material types have been assigned to one element | |
2 | - no type has been assigned to elements | |
3 | - property numbers of the required entity type have not been read on elements | |
4 | - property number of the required entity type have not been found on elements |
Definition at line 3327 of file input.cpp.
References Check_unused_prop, XFILE::col, Dbmat, El_matdbi, El_matid, El_mattype, El_nmat, entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, dbmat::mark_used(), mattype_kwdset(), memset(), print_err(), dbmat::search_mat(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, xf_setsec(), and xfscanf().
Referenced by input_elemprop().
assignment of element types
The function assigns element type to the elements. It scans sections eledgpr, elsurfpr, elvolpr for keyword "el_type". The record which assigns type to the element looks like follows: "el_type" "propid" prop element_type where prop is positive integer number.
The asssigning starts at section for volumes and finishes at section for edges. If an element belongs to several entities and types are prescribed for these entities, error of assignment is signalized. Finally, the function checks whether all elements have assigned type.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array elemsects |
Returns :
0 | - on succes | |
1 | - different types have been assigned to one element | |
2 | - different strain/stress states have been assigned to one element | |
3 | - no type has been assigned to elements | |
4 | - property numbers of the required entity type have not been read on elements | |
5 | - property number of the required entity type have not been found on elements |
Definition at line 3159 of file input.cpp.
References Check_unused_prop, XFILE::col, El_ssst, El_type, elemtype_kwdset(), entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), planeelementlt, planequadcontact, print_err(), sect_mode_full, sect_mode_fwd, sect_mode_seq, strastrestate_kwdset(), Top, xf_setsec(), and xfscanf().
Referenced by input_elemprop().
long input_elemprop | ( | XFILE * | in | ) |
input of element properties
Function reads element properties from file in
in | - poinetr to opened input file with property description |
Returns :
0 | - on succes | |
1 | - fails input of element types | |
2 | - fails input of material | |
3 | - fails input of cross-sections | |
4 | - fails input of local coordinate systems | |
5 | - fails input of load record | |
6 | - fails input of edge load | |
7 | - fails input of surface load | |
8 | - fails input of volume load | |
9 | - fails input of eigenstrains | |
10 | - fails input of time functions for elements |
Created 04.2008 by Tomas Koudelka koudelka@cml.fsv.cvut.cz
Definition at line 1154 of file input.cpp.
References enumstr::alias, mechtop::alloc_prep(), begsec_eledgpr, begsec_elsurfpr, begsec_elvolpr, bsec_str, El_type, enumstr::id, input_elem_crsec(), input_elem_eigstr(), input_elem_eltimefunc(), input_elem_lcs(), input_elem_load(), input_elem_loadedge(), input_elem_loadsurf(), input_elem_loadvol(), input_elem_mat(), input_elem_type(), XFILE::kwdmode, Mt, sequent_mode, and Top.
Referenced by input().
reading of topology, material and cross section files
The function reads section with files used for the generation of MEFEL input file e.g., topology, material or cros ssection files. It also reads setup of preprocessor.
in | - pointer to the opened XFILE structure | |
d | - structure with input data format description |
0 | - on success |
Created by Tomas Koudelka, 7.7.2014
Definition at line 208 of file input.cpp.
References answertype_kwdset(), descrip::crf, descrip::crskwd, descrip::crssec, descrip::crsstr, descrip::hangnf, descrip::matf, descrip::matkwd, descrip::matsec, descrip::matstr, descrip::meshfmt, meshform_kwdset(), no, descrip::redgn, descrip::topf, xfscanf(), and yes.
Referenced by main().
long input_hang_nodes | ( | XFILE * | in | ) |
input of hanging nodes from the separate file
Function reads hanging nodes data from the separated topology file in.
in | - pointer to the opened XFILE structure |
Function returns:
0 | : on success | |
1 | : on error in reading of number of master nodes | |
2 | : on error in reading of hanging node number | |
3 | : on error in reading of hanging node data |
Definition at line 836 of file input.cpp.
References memset(), Nod_hang, Numhn, print_err(), hangnode::read(), Top, and xfscanf().
Referenced by input().
long input_lc | ( | XFILE * | in | ) |
input of description of load cases
Input of data about load cases and layers
in | - pointer to the opened XFILE structure |
Returns:
1 | - in case of wrong number of load cases | |
2 | - in case of wrong number of layers | |
3 | - in case of wrong load|subload case index | |
4 | - in case of wrong temperature load type | |
5 | - in case of wrong number of prescribed displacements (growing mechanical problem only) | |
6 | - in case of multiple assignment of different values of prescribed displacements to the same subload case (growing mechanical problem only) |
created 04.2008 by Tomas Koudelka koudelka@cml.fsv.cvut.cz
Definition at line 262 of file input.cpp.
References begsec_loadcase, bsec_str, XFILE::col, dynload_kwdset(), eigen_dynamics, XFILE::fname, forced_dynamics, growing_mech_structure, Gtm, probdesc::homog, XFILE::kwdmode, layered_linear_statics, XFILE::line, linear_statics, mat_nonlinear_statics, mech_timedependent_prob, memset(), Mp, Mstrc, Nlay, Nlc, Nmstrc, Npd, Nslc, Nslc_cum, Nspd, print_err(), gfunct::read(), gtopology::read_gf(), sect_mode_full, sequent_mode, Spd, Tdload, Tf, timeindload, Tlt, Tnslc, probdesc::tprob, xf_setsec(), and xfscanf().
Referenced by input().
input material from the corresponding section of the preprocessor file
Function reads material database from corresponding XFILE section.
in | - pointer to the opened XFILE file | |
d | - pointer to structure with description of preprocessor setup |
Returns :
0 | - on succes | |
1 | - if fails opening file | |
2 | - if fails reading material parameters |
Created by TKo, 06.2014
Definition at line 929 of file input.cpp.
References begsec_mater, bsec_str, Dbmat, XFILE::ignorecase, XFILE::kwdmode, descrip::matstr, Mespr, Mm, dbmat::read(), dbmat::readmm(), sect_mode_seq, XFILE::warning, xf_setsec(), and yes.
long input_materials | ( | char * | fname, | |
descrip * | d | |||
) |
input material from the material file
Function reads material database from file with name given by the fname
fname | - string with database file name | |
d | - pointer to structure with description of preprocessor setup |
Returns :
0 | - on succes | |
1 | - if fails opening file | |
2 | - if fails reading material parameters |
Definition at line 882 of file input.cpp.
References Dbmat, XFILE::ignorecase, XFILE::kwdmode, descrip::matstr, Mespr, Mm, dbmat::read(), dbmat::readmm(), sequent_mode, XFILE::warning, xfclose(), xfopen(), and yes.
Referenced by input().
assignment of boundary conditions at nodes
Function reads and assigns boundary conditions at each node. It scans sections nodvertpr, nodedgpr, nodsurfpr, nodvolpr for keyword "bocon". The record which assigns dofs to node looks like follows: "bocon" "propid" prop "num_bc" nbc {"dir" dir "cond" cond [func]}[nbc]
The asssigning starts at section for volumes and finishes at section for vertices. If a node belongs to several entities and boundary conditions are prescribed for these entities, the assigned boundary conditions are merged and a message is written into the log file. In case of multiple assigning of different boundary conditions in same direction, error of merging is signalized.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - assignment of different number of dofs at one node | |
2 | - expression could not be parsed | |
3 | - two boundary conditons cannot be merged | |
4 | - growing mechanical problem type is required (dofs have to be controlled by time functions) | |
5 | - nodes with required property and entity type cannot be found |
Definition at line 1393 of file input.cpp.
References Check_unused_prop, XFILE::col, bocon::copy(), entitypstr, XFILE::fname, getkwd_sect(), gregion, growing_mech_structure, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), bocon::merge(), Mp, Nod_bocon, Nod_ndof, print_err(), bocon::read(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, probdesc::tprob, xf_setsec(), and xfscanf().
Referenced by input_nodprop().
assignment of coupled dofs at nodes
Function reads and assigns coupled dofs at each node. It scans sections nodvertpr, nodedgpr, nodsurfpr, nodvolpr for keyword "dof_coupl". The record which assigns coupled dofs to nodes looks like follows: "dof_coupl" "propid" prop "num_coup_dir" ndir {"dir" dir_index}[ndir]
The asssigning starts at section for volumes and finishes at section for vertices. If a node belongs to several entities and boundary conditions are prescribed for these entities, the assigned boundary conditions are merged and a message is written into the log file.In case of multiple assigning of different boundary conditions in same direction, error of merging is signalized.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - assignment of different number of dofs at one node | |
2 | - invalid number of coupled dofs (out of <1;ndof>) | |
3 | - invalid coupled dof number (out of <1;ndof>) | |
4 | - growing mechanical problem type is required (dofs have to be controlled by time functions) | |
5 | - nodes with required property and entity type cannot be found |
Definition at line 1576 of file input.cpp.
References Check_unused_prop, XFILE::col, entitypstr, XFILE::fname, getkwd_sect(), gregion, growing_mech_structure, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), Mp, Nod_ccn, Nod_ndof, print_err(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, probdesc::tprob, xf_setsec(), and xfscanf().
Referenced by input_nodprop().
assignment of cross-setions at nodes
Function reads cross-sections at each node. It scans sections nodvertpr, nodedgpr, nodsurfpr, nodvolpr for keyword "nod_crsec". The record which assigns a cross-section to node looks like follows: "nod_crsec" "propid" prop "type" type_keyword "type_id" type_index
The asssigning starts at section for volumes and finishes at section for vertices. In case of multiple assigning of different cross-sections, error of assignment is signalized.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - cannot find required cross-section in database | |
2 | - different cross-section type has been assigned at one node | |
3 | - nodes with required property and entity type cannot be found |
Definition at line 1946 of file input.cpp.
References Check_unused_prop, XFILE::col, crsectype_kwdset(), csplanestr, Dbcrs, entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, dbcrs::mark_used(), memset(), nocrosssection, Nod_cst, Nod_cstdbi, Nod_csti, print_err(), dbcrs::search_crs(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, xf_setsec(), and xfscanf().
Referenced by input_nodprop().
assignment of time functions cotrolling dofs at nodes
Function reads time functions for switching dofs on/off at each node. It scans sections nodvertpr, nodedgpr, nodsurfpr, nodvolpr for keyword "nod_tfunc". The record which assigns dofs to node looks like follows: "nod_tfunc" "propid" prop {"tfunc_id" tfunc_id}[ndofn]
The asssigning starts at section for volumes and finishes at section for vertices. In case of multiple assigning of different time functions, error of assignment is signalized.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - cannot determine unique number of dofs for the given property and entity type | |
2 | - number of prescribed time functions is out of range <1,ndofn> | |
3 | - dof id is out of range <1,ndofn> | |
4 | - nodes with required property and entity type cannot be found | |
5 | - invalid time function id |
Created by TKo, 09.2009
Definition at line 1768 of file input.cpp.
References Check_unused_prop, XFILE::col, entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), Nod_ccn, Nod_ndof, print_err(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, xf_setsec(), and xfscanf().
Referenced by input_nodprop().
assignment of initial conditions at nodes
Function reads initial conditions at nodes. It scans sections nodvertpr, nodedgpr, nodsurfpr, nodvolpr for keyword "nod_inicond". The record which assigns nodal initial conditions looks like follows: "nod_inicond" "propid" prop "cond" {initial_condition}
The asssigning starts at section for volumes and finishes at section for vertices. If a node belongs to several entities and initial conditions are prescribed for these entities, the assigned conditions are merged and a message is written into the log file.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - invalid load case index | |
2 | - assignment of different types of initial conditons at one node | |
3 | - nodes with required property and entity type cannot be found |
Definition at line 2825 of file input.cpp.
References Check_unused_prop, XFILE::col, inicd::copy(), entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), inicd::merge(), Nlc, Nod_inicd, print_err(), inicd::read(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, xf_setsec(), and xfscanf().
Referenced by input_nodprop().
assignment of local coordinate systems at nodes
Function reads local coordinate systems defined at nodes. It scans sections nodvertpr, nodedgpr, nodsurfpr, nodvolpr for keyword "nod_lcs". The record which assigns local coordinate system to node looks like follows: "nod_lcs" "propid" prop "dim" vect_dim {"basevec" base_vector_components}[vect_dim]
The asssigning starts at section for volumes and finishes at section for vertices. In case of multiple assigning of different local coordinate systems, error of assignment is signalized.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - invalid dimension of base vectors | |
2 | - nodes with required property and entity type cannot be found |
Definition at line 2319 of file input.cpp.
References allocv(), Check_unused_prop, XFILE::col, copyv(), entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, memset(), Nod_lcs, print_err(), readv(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, xf_setsec(), and xfscanf().
Referenced by input_nodprop().
assignment of nodal load
Function reads nodal load. It scans sections nodvertpr, nodedgpr, nodsurfpr, nodvolpr for keyword "nod_load". The record which assigns nodal load looks like follows: "nod_load" "propid" prop "load_comp" {load_components}[ndofn]
The asssigning starts at section for volumes and finishes at section for vertices. If a node belongs to several entities and loads are prescribed for these entities, the assigned loads are merged and a message is written into the log file.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - load case index out of range | |
2 | - assignment of different number of dofs at slected nodes | |
3 | - cannot find nodes with required property and entity type |
Definition at line 2485 of file input.cpp.
References Check_unused_prop, XFILE::col, entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), Nlc, Nod_load, Nod_ndof, Nslc, Nslc_cum, print_err(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Tnslc, Top, xf_setsec(), and xfscanf().
Referenced by input_nodprop().
assignment of dofs at nodes
The function assign number of dofs at each node. It scans sections nodvertpr, nodedgpr, nodsurfpr, nodvolpr for keyword "ndofn". The record which assigns dofs to node looks like follows: "ndofn" ndof "propid" prop where ndof and prop are positive integer numbers.
The asssigning starts at section for volumes and finishes at section for vertices. If a node belongs to several entities and dofs are prescribed for these entities, the assigned dofs are rewritten and in case of multiple assigning, the message is written into the log file. Finally, the function checks whether all nodes have assigned ndof
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - wrong number of dofs has been assigned to nodes | |
2 | - different numbers of dofs have been assigned to node | |
3 | - no number of dofs has been assigned to nodes | |
4 | - nodes with required property and entity type cannot be found |
Definition at line 1254 of file input.cpp.
References Check_unused_prop, XFILE::col, entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), Nod_ndof, print_err(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, xf_setsec(), and xfscanf().
Referenced by input_nodprop().
assignment of spring supports at nodes
Function reads spring supports at each node. It scans sections nodvertpr, nodedgpr, nodsurfpr, nodvolpr for keyword "nod_crsec". The record which assigns a springs to node looks like follows: "nod_spring" "propid" prop "dir" dir_index "num_mat" nmat nmat*{"type" material_type "type_id" material_id}
The asssigning starts at section for volumes and finishes at section for vertices. In case of multiple assigning of different springs, error of assignment is signalized.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - cannot find required material in database | |
2 | - different material type has been assigned to spring at one node | |
3 | - nodes with required property and entity type cannot be found | |
4 | - direction of spring is out of range <1,6> or <1, ndofn> | |
5 | - nodes with the given property have different number of dofs |
Definition at line 2090 of file input.cpp.
References Check_unused_prop, XFILE::col, Dbmat, entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, dbmat::mark_used(), mattype_kwdset(), memset(), Nod_ndof, Nod_nsprmat, Nod_sprmatdbi, Nod_sprmatid, Nod_sprmattype, print_err(), dbmat::search_mat(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Top, xf_setsec(), and xfscanf().
Referenced by input_nodprop().
assignment of nodal time dependent load
Function reads time dependent nodal load. It scans sections nodvertpr, nodedgpr, nodsurfpr, nodvolpr for keyword "nod_load". The record which assigns nodal load looks like follows: "nod_load" "propid" prop "load_comp" {time_functions_of_load_components}[ndofn]
The asssigning starts at section for volumes and finishes at section for vertices. If a node belongs to several entities and loads are prescribed for these entities, the assigned loads are merged and a message is written into the log file.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - subloadcases cannot be required with this type of load | |
2 | - index of load case is out of range | |
3 | - assignment of different number of dofs at one node | |
4 | - cannot find nodes with required property and entity type |
Definition at line 2661 of file input.cpp.
References Check_unused_prop, XFILE::col, entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), Nlc, Nod_ndof, Nod_tdload, print_err(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Tnslc, Top, xf_setsec(), and xfscanf().
Referenced by input_nodprop().
assignment of temparture load at nodes
Function reads nodal temperatures. It scans sections nodvertpr, nodedgpr, nodsurfpr, nodvolpr for keyword "nod_temper". The record which assigns nodal initial conditions looks like follows: "nod_temper" "propid" prop "lc_id" load_case_index "temperature" temperature_value
The asssigning starts at section for volumes and finishes at section for vertices. If a node belongs to several entities and temperatures are prescribed for these entities, the assigned temperatures are OVERWRITTEN and a message is written into the log file.
in | - pointer to opened input file with property description - array with descriptors of sections, which will be searched - number of searched sections i.e number of elements in array nodsects |
Returns :
0 | - on succes | |
1 | - wrong loadcase/subloadcase id | |
2 | - wrong temperature load type is required (it should be 1 or 2) | |
3 | - nodes with required property and entity type cannot be found |
Definition at line 2996 of file input.cpp.
References Check_unused_prop, XFILE::col, tempload::copy(), entitypstr, XFILE::fname, getkwd_sect(), gregion, XFILE::ignorecase, XFILE::kwdmode, XFILE::line, Log, memset(), tempload::nlc, Nlc, Nod_temper, tempload::nslc, Nslc, Nslc_cum, Ntempl, print_err(), tempload::read(), sect_mode_full, sect_mode_fwd, sect_mode_seq, Tlt, Tnslc, Top, xf_setsec(), and xfscanf().
Referenced by input_nodprop().
long input_nodprop | ( | XFILE * | in | ) |
input of nodal properties
Function reads nodal properties from file in
in | - poinetr to opened input file with property description |
Returns :
0 | - on succes | |
1 | - fails input of ndofs | |
2 | - fails input of boundary conditions | |
3 | - fails input of common code numbers | |
4 | - fails input of springs at nodes | |
5 | - fails input of time functions of dofs | |
6 | - fails input of cross-sections | |
7 | - fails input of local coordinate systems | |
8 | - fails input of load | |
9 | - fails input of time dependent load | |
10 | - fails input of initial conditions | |
11 | - fails input of temperatures |
Created 04.2008 by Tomas Koudelka koudelka@cml.fsv.cvut.cz
Definition at line 1073 of file input.cpp.
References input_nod_bocon(), input_nod_coupl_dofs(), input_nod_crsec(), input_nod_dof_tfunc(), input_nod_initcond(), input_nod_lcs(), input_nod_load(), input_nod_ndof(), input_nod_springs(), input_nod_tdload(), input_nod_temper(), XFILE::kwdmode, Nod_ccn, and sequent_mode.
Referenced by input().
input topolgy using siftop class
Function reads topology file in, format of the file is described by structure d.
in | - pointer to the opened XFILE structure | |
d | - structure with input data format description |
Function returns:
0 | : on success | |
4 | : in case of unknown mesh format |
In case of reading alternative file format :
1 | : on error in reading of node | |
2 | : on error in reading of element | |
3 | : on error in reading of global node numbers |
Definition at line 803 of file input.cpp.
References descrip::meshfmt, descrip::paral, print_err(), descrip::redgn, sifel, t3d, and Top.
Referenced by input().