Hello,
I am solving a coupled flow and temperature problem, where the viscosity ‘mu’ depends on the temperature, thus forming the coupling.
I want to be able to extract the viscosity as a .pvd file, but it’s proven tricky, as viscosity is defined as
mu = exp(-Gamma*T),
where T is temperature (part of the solution) and Gamma is a constant.
I want to do something like
File(“Viscosity,pvd”) << mu
but the error I get is
File “/usr/local/lib/python3.6/dist-packages/dolfin/io/init.py”, line 21, in lshift
self.write(u)
AttributeError: ‘Exp’ object has no attribute ‘_cpp_object’
I realise that I need to interpolate or do something else to mu before just exporting it, but I haven’t been able to find out exactly what that is.
Any help would be greatly appreciated!