underworld3 icon indicating copy to clipboard operation
underworld3 copied to clipboard

Evaluation of derivatives functions

Open dansand opened this issue 4 years ago • 2 comments

Example:

sr -= (stokes.div_u/mesh.dim)*eye(mesh.dim)  
inv2 = sr[0,0]**2 + sr[0,1]**2 + sr[1,0]**2 + sr[1,1]**2   
inv2 = 1/2.*inv2
strainRate_2ndInvariant = sqrt(inv2)

uw.function.evaluate(strainRate_2ndInvariant, mesh.data)
RuntimeError: Derivatives functions are not handled yet unfortunately.

This is a known limitation as the error message makes clear. But for experimentation it would (really) useful to be able to view things like the strain rate.

dansand avatar Oct 07 '21 21:10 dansand

I second this - we have variable interpolation (rbf only suitable for fields), we have projection (works for anything but maps to nodes), and we have this half-working function_evaluation that ought to be the most general but is hopelessly limited.

lmoresi avatar May 04 '23 10:05 lmoresi

@julesghub - can you update this issue to the current PETSc state ?

lmoresi avatar Aug 29 '24 12:08 lmoresi