Changeset 5460 for anuga_validation/circular_island/simple_circular
- Timestamp:
- Jul 3, 2008, 2:57:22 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_validation/circular_island/simple_circular/circular.py
r5317 r5460 17 17 18 18 #------------------------------------------------------------------------------ 19 # Project file 20 #------------------------------------------------------------------------------ 21 #Set up file structure 22 anuga_dir = home+'anuga_validation'+sep+'circular_island_tsunami_benchmark'+sep+'anuga'+sep 23 meshes_dir = anuga_dir+'meshes'+sep 24 meshname = 'circular_mesh.msh' 25 output_dir = anuga_dir+'output'+sep 26 27 28 ## #------------------------------------------------------------------------------ 29 ## # Copy scripts to time stamped output directory and capture screen 30 ## # output to file 31 ## #------------------------------------------------------------------------------ 32 ## print "Processor Name:",get_processor_name() 33 ## 34 ## #copy script must be before screen_catcher 35 ## #print kwargs 36 ## 37 ## print 'output_dir', output_dir 38 ## if myid == 0: 39 ## copy_code_files(kwargs['output_dir'],__file__, 40 ## dirname(project.__file__)+sep+ project.__name__+'.py' ) 41 ## 42 ## store_parameters(**kwargs) 43 ## 44 ## barrier() 45 ## 46 ## start_screen_catcher(kwargs['output_dir'], myid, numprocs) 47 ## 48 ## print "Processor Name:",get_processor_name() 49 ## 50 ## # filenames 51 ### meshes_dir_name = project.meshes_dir_name+'.msh' 52 ## 53 ## # creates copy of code in output dir 54 ## print 'min triangles', project.trigs_min, 55 ## print 'Note: This is generally about 20% less than the final amount' 56 57 58 #------------------------------------------------------------------------------ 19 59 # Setup computational domain 20 60 #------------------------------------------------------------------------------ 61 62 21 63 length = 30. 22 64 width = 25. … … 28 70 #boundary 29 71 poly_domain = [[0,0],[length,0],[length,width],[0,width]] 30 meshname = 'test.msh' 72 31 73 32 74 # exporting asc grid … … 46 88 47 89 #Create mesh 90 91 print 'start create mesh from regions' 92 48 93 create_mesh_from_regions(poly_domain, 49 94 boundary_tags={'wavemaker': [0], 'right': [1], … … 53 98 interior_regions = interior_dome, 54 99 use_cache=False, 55 verbose= True)100 verbose=False) 56 101 57 domain = Domain(meshname, use_cache=False, verbose = True) 102 # Setup computational domain 103 104 domain = Domain(meshes_dir+sep+meshname, use_cache=False, verbose = True) 58 105 domain.set_name('circular') # Output name 59 print domain.statistics() 106 print 'memory usage before del domain',mem_usage() 107 108 print domain.statistics() 109 print 'triangles',len(domain) 110 60 111 61 112 #------------------------------------------------------------------------------ … … 106 157 Bw = Dirichlet_boundary([water_depth, 0, 0]) #wall 107 158 Bt = Transmissive_Momentum_Set_Stage_boundary(domain, wave_form) #wavemaker 159 108 160 domain.set_boundary({'left': Bw, 'right': Bw, 'top': Bw, 'wavemaker': Bt}) 109 161
Note: See TracChangeset
for help on using the changeset viewer.