this question is probably due to my lack of knowledge of python, nonetheless here it is: is it possible to import a gmsh mesh file.geo instead of writing it entirely on the fipy script as is it done in this tutorial ?
a procedure like this: open file; read/store the content in data_var; mesh = Gmsh2D(data_var) # generate the mesh with gmsh
Thanks
There's no need to "read/store the content in data_var".
Per http://www.ctcms.nist.gov/fipy/fipy/generated/fipy.meshes.html#module-fipy.meshes.gmshMesh, the first argument to Gmsh2D et al. is:
arg: a string giving (i) the path to an MSH file, (ii) a path to a Gmsh geometry (”.geo”) file, or (iii) a Gmsh geometry script
Just supply the path to your .geo file.