Hi Gerard,

> You probably need to write your own small python or c++ program to
> calculate it (I'd recommend python because it would be quicker). You'd
> generate n points along the path, put these into a vtkPolyData object
> and set this as the inport to a vtkProbeFilter
> (http://www.vtk.org/doc/nightly/html/classvtkProbeFilter.html), and set
> your mesh with the velocity vector as the filter source. You can extract
> the velocity vectors from this filter and dot them with the tangent
> vectors at your sample points. You could do this either using the basic
> VTK python interface or (the more modern approach) use the traited
> version with mayavi2.

This seems to be exactly the information we were after; we'll give it a go.

Many thanks,

Hans




>
> Cheers
> Gerard
>
> Hans Fangohr wrote:
>> Dear all, dear Prabhu,
>>
>> the following question may be slighty off topic but I was hoping that
>> somebody in the audience may have tried to do something similar before
>> and could give some advice. If not, just ignore this email and accept
>> my apologies, please.
>>
>> We would like to calculate the circulation (=the line integral of
>> scalar product of velocity and tangent vector of the line) of the flow
>> around a torus-shaped object. We have the data in VTK (obviously using
>> mayavi to look at it ;-) ) and are wandering whether it might be
>> possible to compute the circulation with VTKs help.
>>
>> Some background information:
>>
>>     The actual simulation is carried out with a somewhat complicated
>>     locally refined rectangular mesh (and we have not implemented this
>>     and are neither very confident in decoding the data structure) but
>>     we have managed to import the data to VTK. It would therefore be
>>     immensely convenient if VTK could compute the circulation as it
>>     knows the velocity field anyway, and can carry out linear
>>     interpolation between the provided data points (something which
>>     would be that easy to code by hand for this example).
>>
>>     It may be possible to use a square path around the torus shape object
>>     (instead of circular path) if that makes the problem any easier to
>>     handle.
>>
>>
>> Thank you for listening,
>>
>> Hans
>>
>>
>>
>>
>> --
>> Hans Fangohr
>>
>> School of Engineering Sciences
>> University of Southampton
>> Phone: +44 (0) 238059 8345
>>
>> Email: [EMAIL PROTECTED]
>> http://www.soton.ac.uk/~fangohr
>>
>>
>>
>>
>>
>> -------------------------------------------------------------------------
>> This SF.net email is sponsored by: Microsoft
>> Defy all challenges. Microsoft(R) Visual Studio 2008.
>> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
>> _______________________________________________
>> MayaVi-users mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/mayavi-users
>
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> MayaVi-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/mayavi-users
>
>
>

--
Hans Fangohr

School of Engineering Sciences 
University of Southampton 
Phone: +44 (0) 238059 8345

Email: [EMAIL PROTECTED]
http://www.soton.ac.uk/~fangohr





-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
MayaVi-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mayavi-users

Reply via email to