Computing a unit vector field
Asked by
Heitor Pina
I have a FE Function v on a VectorFunctionSpace V and I need to compute u=v/||v||, i.e., a unit vector field which will be used in a variational form. I am writing u=v/sqrt(dot(v,v)) but this is not working. It seems that I am missing something very trivial here and would appreciate any help.
Best
Heitor
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- DOLFIN Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- Johan Hake
- Solved:
- Last query:
- Last reply:
To post a message you must log in.