5@nb.jit(nopython=True, fastmath=True)
6def make_nei_ele(m, n, l, nei_ele):
10 Only for hexahedral mesh
14 m : x direction elements
15 n : y direction elements
16 l : z direction elements
48 if pz >= j*ml + (i+1)*l:
74@nb.jit(nopython=True, fastmath=True)
75def make_coloring(m, n, l, icolor, lcolor):
77 2-Color Algorithm for hexahedral mesh
92 for ind
in range(ist, iend):
94 lcolor[ele] = ca//denom
97 lcolor[ele] = cb//denom
105def read_input(fname):
106 isnum = re.compile(
'\d+')
109 src = open(fname).read()
111 print(
"[Error] Cannot open the input file")
114 nums = re.findall(isnum, src)
116 print(
"[Error] Missing input parameter(s)")
119 return np.array([eval(num)
for num
in nums])