MAGiC  V5.0
Mailleurs Automatiques de Géometries intégrés à la Cao
mg_solution.h
Aller à la documentation de ce fichier.
1 //####//------------------------------------------------------------
2 //####//------------------------------------------------------------
3 //####// MAGiC
4 //####// Jean Christophe Cuilliere et Vincent FRANCOIS
5 //####// Departement de Genie Mecanique - UQTR
6 //####//------------------------------------------------------------
7 //####// MAGIC est un projet de recherche de l equipe ERICCA
8 //####// du departement de genie mecanique de l Universite du Quebec a Trois Rivieres
9 //####// http://www.uqtr.ca/ericca
10 //####// http://www.uqtr.ca/
11 //####//------------------------------------------------------------
12 //####//------------------------------------------------------------
13 //####//
14 //####// mg_solution.h
15 //####//
16 //####//------------------------------------------------------------
17 //####//------------------------------------------------------------
18 //####// COPYRIGHT 2000-2024
19 //####// jeu 13 jun 2024 11:58:53 EDT
20 //####//------------------------------------------------------------
21 //####//------------------------------------------------------------
22 #ifndef __MGSOLUTION_
23 #define __MGSOLUTION_
24 
25 
26 
27 
28 
29 
30 #include <map>
31 #include <set>
32 #include <vector>
33 
34 
35 #include <stdio.h>
36 
37 #include "mg_identificateur.h"
38 #include "mg_definition.h"
39 
40 const unsigned int SOL_EXISTANTE=0;
41 
42 
43 std::ostream& operator << (std::ostream& o,class MG_SOLUTION& sol);
44 
45 
47 {
48 public:
49 
50  MG_SOLUTION(class MG_MAILLAGE *mai,int nb,char* chemin,int code,std::string nomsol,int entite=MAGIC::ENTITE_SOLUTION::ENTITE_NOEUD,int type_solution=MAGIC::TYPE_SOLUTION::SCALAIRE);
51  MG_SOLUTION(unsigned long num,MG_MAILLAGE *mai,int nb,char* chemin,int code,std::string nomsol,int entite=MAGIC::ENTITE_SOLUTION::ENTITE_NOEUD,int type_solution=MAGIC::TYPE_SOLUTION::SCALAIRE);
52  virtual ~MG_SOLUTION();
53 
54  double lire(int i,int j,int coord=0,int num_no=0);
55  void ecrire(double val,int i,int j,int coord=0,int num_no=0);
56  void active_solution(int num);
57  void change_legende(int num,std::string val);
58  std::string get_legende(int num);
59  int get_nb_champ(void);
61  double get_legende_min(int num=0);
62  double get_legende_max(int num=0);
63  void efface(void);
64  std::string get_nom(void);
65  std::string get_nom_fichier(void);
66  int get_entite_solution(void);
67  int get_dim_solution(void);
68 
69  virtual void enregistrer(std::ostream& o,double version);
70  virtual void get_fichier_dependant(std::vector<std::string> &liste_fichier);
71 
72 
73  friend std::ostream& operator << (std::ostream& o,MG_SOLUTION& maillage);
74 
75 private:
76  void inisolution(char* chemin,int code);
77  char *nom_fichier;
78  int nb_champs;
79  FILE* in;
83  std::string* legende;
84  std::string nomsolution;
87  std::vector<unsigned long> hash;
88 };
89 
90 
91 
92 #endif
93 
94 
MG_MAILLAGE * mgmai
Definition: mg_solution.h:80
virtual void enregistrer(std::ostream &o, double version)
void change_legende(int num, std::string val)
MG_SOLUTION(class MG_MAILLAGE *mai, int nb, char *chemin, int code, std::string nomsol, int entite=MAGIC::ENTITE_SOLUTION::ENTITE_NOEUD, int type_solution=MAGIC::TYPE_SOLUTION::SCALAIRE)
Definition: mg_solution.cpp:42
int get_entite_solution(void)
int get_dim_solution(void)
void inisolution(char *chemin, int code)
Definition: mg_solution.cpp:60
virtual void get_fichier_dependant(std::vector< std::string > &liste_fichier)
friend std::ostream & operator<<(std::ostream &o, MG_SOLUTION &maillage)
std::string nomsolution
Definition: mg_solution.h:84
double get_legende_min(int num=0)
MG_MAILLAGE * get_maillage(void)
void active_solution(int num)
std::string * legende
Definition: mg_solution.h:83
double solmax[MAX_TYPE_SOLUTION]
Definition: mg_solution.h:82
int get_nb_champ(void)
int typeentite
Definition: mg_solution.h:85
double get_legende_max(int num=0)
double lire(int i, int j, int coord=0, int num_no=0)
std::string get_nom(void)
std::string get_legende(int num)
void efface(void)
double solmin[MAX_TYPE_SOLUTION]
Definition: mg_solution.h:81
int dim_solution
Definition: mg_solution.h:86
void ecrire(double val, int i, int j, int coord=0, int num_no=0)
FILE * in
Definition: mg_solution.h:79
std::vector< unsigned long > hash
Definition: mg_solution.h:87
char * nom_fichier
Definition: mg_solution.h:77
std::string get_nom_fichier(void)
virtual ~MG_SOLUTION()
Definition: mg_solution.cpp:52
const int MAX_TYPE_SOLUTION
Definition: mg_definition.h:42
const unsigned int SOL_EXISTANTE
Definition: mg_solution.h:40
std::ostream & operator<<(std::ostream &o, class MG_SOLUTION &sol)