48 unsigned long nelcount = 0;
62 logger(
LOG_ERROR,
"Symmetry level ksymmi=%d. Acousto supports only 1 symmetry plane (ksymmi=1) or axialsymmetry (ksymmi>3) with GMSH files \n",
runinfo->
ksymmi);
68 fnodes = fopen(gmshgeom->
filename,
"r");
75 while (fgets(line, 100, fnodes) != NULL) {
76 if (0 == strcmp(
"$Nodes\n", line)) {
77 fgets(line, 100, fnodes);
78 sscanf(line,
"%d\n", &ntmp);
83 if (0 == strcmp(
"$Elements\n", line)) {
84 fgets(line, 100, fnodes);
85 sscanf(line,
"%d\n", &netmp);
86 for (j = 0; j < netmp; j++) {
87 fgets(line, 100, fnodes);
88 sscanf(line,
"%d %d\n", &ntmp, &eltype);
89 if (2 == eltype || 3 == eltype) {
94 logger(
LOG_INFO,
"GMSH FILE -> number of read triangular and quadrilateral elements %d\n", nelcount);
95 logger(
LOG_INFO,
"GMSH FILE -> number of triangular and quadrilateral elements after symmetrization %d\n",
geometries[igeom].nelmb);
#define MSG_GEOM_FILE_NOTFOUND
Definition: messages.h:38
struct geometry * geometries
Definition: globals.h:66
struct run_info * runinfo
Definition: globals.h:34
#define GMSH
Definition: config.h:58
int ncntr
Definition: structs.h:175
#define CONFIG_GET_STRING(config, name, var)
Definition: config.h:48
void * ptrgeom
Definition: structs.h:173
struct vector refpoint
Definition: structs.h:254
#define LOG_INFO
Definition: logger.h:26
const char * filename
Definition: structs.h:252
#define LOG_ERROR
Definition: logger.h:24
int nelmb
Definition: structs.h:179
#define ACOUSTO_ERROR_GEOMETRY
Definition: constants.h:25
struct vector symvec
Definition: structs.h:253
struct config_t config
Definition: config.h:61
DOUBLE z
Definition: structs.h:35
#define LOG_DEBUG
Definition: logger.h:27
int type
Definition: structs.h:171
int nsymm
Definition: structs.h:97
int ksymmi
Definition: structs.h:91
DOUBLE x
Definition: structs.h:31
int nnodb
Definition: structs.h:177
#define MAX_PATH
Definition: constants.h:29
#define CONFIG_GET_FLOAT(config, name, var)
Definition: config.h:44
void logger(int level, char *msg,...)
Definition: logger.c:56
DOUBLE y
Definition: structs.h:33