Source: k2dgrflow/domainnet2d.h
|
|
|
|
/***************************************************************************
domainnet2d.h - description
-------------------
begin : Wed May 30 2001
copyright : (C) 2001 by benny
email : bm@cage.rug.ac.be
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
#ifndef DOMAINNET2D_H
#define DOMAINNET2D_H
/**The class that controls a FEM-mesh or net
Plays the starting point for functions on the objects
of the mesh, so the elements, the edges and the nodes.
*@author benny
*/
//STL includes
#include <vector.h>
#include <iterator.h>
//topology
#include "topology.h"
#include "k2dborderbase.h"
class KURL;
class DomainNet2d {
friend class GalarSolver2d;
friend class GalarImpGrFlow;
public:
/** Construct a domain with a file generated by the EasyMesh programm.
Should have the form filename.d */
DomainNet2d();
~DomainNet2d();
/**add a boundary to the domain. The number 0 .. geoBoundary.size()-1 is important, so leave it !
*/
void addBoundary(K2dBorderBase *bound) {geoBoundary.push_back(bound); };
void buildNet(KURL &EasyMeshFileName);
/**number of nodes in the domain (= number of unknowns in our equation !)
*/
int nrNodes(){return geoNodes.size(); };
/**number of elements in the domain
*/
int nrEle(){return geoEle.size(); };
/** a test function of all the functionality
*/
bool testDomainNet2d();
/** to test the domain you can send it as readeble data to cout
*/
void output();
private:
/**containers of the actual objects contained in a net
*/
vector<TopoElement2d*> geoEle;
vector<TopoEdge2d*> geoEdges;
vector<TopoNode2d*> geoNodes;
vector<K2dBorderBase*> geoBoundary;
/*
//structures to quickly read the easymeshfiles
//two structures to quickly read input data of files wish must be displayed
struct sid
{
int node1;
int node2;
};
struct nod
{
double coord1;
double coord2;
};
*/
};
#endif
Generated by: benny@okidoki on Thu Jun 21 10:41:51 2001, using kdoc 2.0a53. |