Ignore:
Timestamp:
May 15, 2006, 2:26:21 PM (19 years ago)
Author:
ole
Message:

Implemented Domain(meshfile) variant widely, updated documentation and added more statistics

File:
1 edited

Legend:

Unmodified
Added
Removed
  • inundation/pyvolution/general_mesh.py

    r2808 r2866  
    5353    #input
    5454    def __init__(self, coordinates, triangles,
    55                  geo_reference=None):
     55                 geo_reference=None,
     56                 verbose=False):
    5657        """
    5758        Build triangles from x,y coordinates (sequence of 2-tuples or
     
    6263        If specified coordinates are assumed to be relative to this origin.
    6364        """
     65
     66        if verbose: print 'General_mesh: Building basic mesh structure'
    6467
    6568        from Numeric import array, zeros, Int, Float, sqrt, sum
     
    108111
    109112        #Initialise each triangle
     113        if verbose:
     114            print 'General_mesh: Computing areas, normals and edgelenghts'
     115           
    110116        for i in range(N):
    111             #if i % (N/10) == 0: print '(%d/%d)' %(i, N)
     117            if verbose and i % ((N+10)/10) == 0: print '(%d/%d)' %(i, N)
     118           
    112119
    113120            x0 = V[i, 0]; y0 = V[i, 1]
     
    157164       
    158165        #Build vertex list
     166        if verbose: print 'Building vertex list'         
    159167        self.build_vertexlist()
    160168
Note: See TracChangeset for help on using the changeset viewer.