Hello,
I have a question regarding write and read XDMF.
‘’’
mesh = Mesh(“mesh.xml”)
PM = FunctionSpace(mesh, ‘DG’, 0)
a = project(a, PM)
a_xdmf = XDMFFile(“a.xdmf”)
a.rename(“a”, “a”)
a_xdmf.write(a)
a_xdmf.close()
a_xdmf_in = XDMFFile(“a.xdmf”)
a_in = Function(PM)
a_xdmf_in.read(a_in)
‘’’
I found the error as follows: ‘TypeError: read(): incompatible function arguments.’
What would be the right way(s) to export ‘function’ and read it back?
Thank you!
Meen