[GRASS-user] how to create a Finite Element mesh from XY data?

Vishal Mehta vishalm1975 at gmail.com
Fri Jun 27 16:12:22 PDT 2014


hi all,

I need to re-create a finite element mesh from XY data, (from input files
for a groundwater model someone else built in a different platform (IWFM).
Would appreciate some help in figuring out how to take the 2 files below,
and create a polygon vector layer with element ID assigned to polygons.

The nodes and elements are in 2 files, here is what they look like:

1. nodes file has node id, x,y (utm 10 wgs 84 i think), and a region id















*C                      Groundwater Node LocationsC   The following lists
the node number and x & y coordinate of each nodeCC   ID;   Groundwater
node numberC   X,Y;  Coordinates of groundwater node location;
[L]CC-------------------------------------------------------------------------------C
Node     ----------Coordinates----------C    ID
X
YC-------------------------------------------------------------------------------
1          563734             4308465     2          565407
4308558     3          566687             4308507     4
567636             4308465*
...


2. element files links the nodes to element ids

 File Description
C
C   This file  contains the element configuration for each element.
C   The nodes that make a finite element are listed for each element in
C   a counter-clock wise fashion starting with any node. For triangular
elements,
C   the fourth node is specified as zero.
C
C
C   For example,
C
C                    13-------------14----------17
C                     I              I         I
C                     I      2       I   3   I
C                     I              I     I
C                     I              I   I
C                    15------------- 16
C
C
C   The configuration for elements 2 and 3 will be listed as,
C
C            element   node 1    node 2    node 3   node 4
C               2        13        15        16        14
C               3        14        16        17         0
...
----------------------------------------------------------------------------
C   Element     ------------Corresponding Nodes------------------
Subregion
C   IE          IDE(1)        IDE(2)       IDE(3)       IDE(4)
IRGE
C-------------------------------------------------------------------------------
    1           1             5            6            2
1
    2           3             2            6            7
1
    3           3             7            8            4
1
    4           11            6            5            10
1
    5           11            12           7            6
1
    6           12            16           8            7
1
    7           13            9            17           0
1
...

Thanks for any help!
Vishal


-- 
Vishal K. Mehta, PhD
Sr. Scientist
Stockholm Environment Institute - US
133 D St Suite F
Davis CA 95616
www.sei-us.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/grass-user/attachments/20140627/474efc93/attachment.html>


More information about the grass-user mailing list