-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathconvert_geo_xml.py
More file actions
38 lines (28 loc) · 828 Bytes
/
convert_geo_xml.py
File metadata and controls
38 lines (28 loc) · 828 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Fri May 25 17:19:57 20120
@author: monique
"""
import os
from dolfin import *
#Path
dir_name = "/mnt/c/Users/Monique/Documents/Guelph_Dolomite/"
folder = "Malhas/"
path = dir_name + folder
os.chdir(path)
sample = ["YZ","XZ"]
#Sample number
threshold = ["5"]
sl_1 = ["1","2"]
#sl_1 = 150
#s_tot = 10
for am in sample:
for s in sl_1:
for t in threshold:
#File
file_in = "gd_" + am + "-474-g" + s + "-c" + t + "-0005_00025"
file_out = "gd_" + am + "-474-g" + s + "-c" + t
#Convert
os.system("gmsh "+ file_in +".geo -2 -o " + file_out + "_5_00025.msh")
os.system("dolfin-convert " + file_out + "_5_00025.msh " + file_out + "_5_00025.xml")