[vtkusers] Calculate magnitude from vector
    Mathieu Malaterre 
    mathieu.malaterre at kitware.com
       
    Mon May  8 18:25:56 EDT 2006
    
    
  
Martin Baumann wrote:
> Hi,
> 
> is there a function in vtk that calculates magnitude of a vector?
> At the moment I do this by hand: magn = sqrt( a^2 + b^2 + c^2)
> I guess that there is a more vtk-style-way to do this.
Hi Martin,
	I am not sure I understand your question. But you can have a look at 
vtkMath::Norm. For a more general filter you should have a look at 
vtkImageMagnitude if dealing with images. Or vtkArrayCalculator when 
dealing with vtkDataArray.
HTH
Mathieu
    
    
More information about the vtkusers
mailing list