# Import the bemio.mesh_utilities module from bemio.mesh_utilities import mesh import numpy as np # Read WAMIT mesh r_cube = mesh.read(file_name='r_cube.gdf') # Save to a NEMOH mesh r_cube.write(mesh_format='NEMOH')
#! /usr/bin/python from bemio.mesh_utilities.mesh import read flap1 = read(file_name='flap1.gdf') flap1.view(save_png=False,camera_pos=[70,0,0]) flap1.write(mesh_format='VTP') flap2 = read(file_name='flap2.gdf') flap2.view(save_png=False,camera_pos=[70,0,0]) flap2.write(mesh_format='VTP') base = read(file_name='base.gdf') base.view(save_png=False,camera_pos=[70,0,0]) base.write(mesh_format='VTP')
#! /usr/bin/python from bemio.mesh_utilities.mesh import read sphere = read(file_name='sphere.gdf') sphere.view(save_png=False, camera_pos=[70, 0, 0]) sphere.write(mesh_format='VTP')
#! /usr/bin/python from bemio.mesh_utilities.mesh import read sphere = read(file_name='sphere.gdf') sphere.view(save_png=False,camera_pos=[70,0,0]) sphere.write(mesh_format='VTP')
#! /usr/bin/python from bemio.mesh_utilities.mesh import read mesh = read(file_name='ellipsoid.gdf') mesh.view(save_png=False,camera_pos=[20,0,0]) mesh.write(mesh_format='VTP')
#! /usr/bin/python from bemio.mesh_utilities.mesh import read flap = read(file_name='flap.gdf') flap.view(save_png=False,camera_pos=[70,0,0]) flap.write(mesh_format='VTP') base = read(file_name='base.gdf') base.view(save_png=False,camera_pos=[70,0,0]) base.write(mesh_format='VTP')
# Import the bemio.mesh_utilities module from bemio.mesh_utilities import mesh import numpy as np # Read WAMIT mesh buoy = mesh.read(file_name='buoy.gdf') # Save to a NEMOH mesh buoy.write(mesh_format='NEMOH')
# Import the bemio.mesh_utilities module from bemio.mesh_utilities import mesh import numpy as np # Read WAMIT mesh ellipsoid = mesh.read(file_name='ellipsoid.gdf') # Save to a NEMOH mesh ellipsoid.write(mesh_format='NEMOH')
#! /usr/bin/python from bemio.mesh_utilities.mesh import read buoy_a = read(file_name='wamit_data/buoy_a.GDF') buoy_a.view(save_png=False, camera_pos=[50, 50, 0]) buoy_a.write(mesh_format='VTP') buoy_b = read(file_name='wamit_data/buoy_b.GDF') buoy_b.view(save_png=False, camera_pos=[50, 50, 0]) buoy_b.write(mesh_format='VTP')
#! /usr/bin/python from bemio.mesh_utilities.mesh import read flap1 = read(file_name='flap1.gdf') flap1.view(save_png=False, camera_pos=[70, 0, 0]) flap1.write(mesh_format='VTP') flap2 = read(file_name='flap2.gdf') flap2.view(save_png=False, camera_pos=[70, 0, 0]) flap2.write(mesh_format='VTP') base = read(file_name='base.gdf') base.view(save_png=False, camera_pos=[70, 0, 0]) base.write(mesh_format='VTP')
#! /usr/bin/python from bemio.mesh_utilities.mesh import read mesh = read(file_name='coer_comp.gdf') mesh.view(save_png=False,camera_pos=[2,2,2]) mesh.write(mesh_format='VTP')
#! /usr/bin/python from bemio.mesh_utilities.mesh import read flap = read(file_name='flap.gdf') flap.view(save_png=False, camera_pos=[70, 0, 0]) flap.write(mesh_format='VTP') base = read(file_name='base.gdf') base.view(save_png=False, camera_pos=[70, 0, 0]) base.write(mesh_format='VTP')
# Import the bemio.mesh_utilities module from bemio.mesh_utilities import mesh import numpy as np # Read WAMIT mesh coer_comp = mesh.read(file_name='coer_comp.GDF') coer_comp.translate(translation_vect=[0.,0.,-.2]) # Save to a NEMOH mesh coer_comp.write(mesh_format='NEMOH')
#! /usr/bin/python from bemio.mesh_utilities.mesh import read buoy_a = read(file_name='wamit_data/buoy_a.GDF') buoy_a.view(save_png=False,camera_pos=[50,50,0]) buoy_a.write(mesh_format='VTP') buoy_b = read(file_name='wamit_data/buoy_b.GDF') buoy_b.view(save_png=False,camera_pos=[50,50,0]) buoy_b.write(mesh_format='VTP')
# Import the bemio.mesh_utilities module from bemio.mesh_utilities import mesh import numpy as np # Read WAMIT mesh base = mesh.read(file_name='base.GDF') # Save to a NEMOH mesh base.write(mesh_format='NEMOH')
#! /usr/bin/python # Import the bemio.mesh_utilities module from bemio.mesh_utilities import mesh import numpy as np from copy import copy # Read mesh ellipsoid = mesh.read(file_name='ellipsoid.gdf') # Scale and translate the copy of the mesh ellipsoid.scale(scale_vect=[5., 10., 10.]) ellipsoid.translate(translation_vect=[1., 2., 3.]) # Write the scaled and tranalated mesh to WAMIT format ellipsoid.write(mesh_format='WAMIT')
#! /usr/bin/python from bemio.mesh_utilities.mesh import read mesh = read(file_name='ellipsoid.gdf') mesh.view(save_png=False, camera_pos=[20, 0, 0]) mesh.write(mesh_format='VTP')
# Import the bemio.mesh_utilities module from bemio.mesh_utilities import mesh import numpy as np # Read WAMIT mesh sphere = mesh.read(file_name='sphere.gdf') # Save to a NEMOH mesh sphere.write(mesh_format='NEMOH')