# Re: Operate the whole vector field

OpenLB – Open Source Lattice Boltzmann Code › Forums › on OpenLB › General Topics › Operate the whole vector field › Re: Operate the whole vector field

Hi steed188,

there are several ways to get your velocity data modified.

Fist, velocity as you put it in your post has x,z,y component. Perhaps you prefer to compute the magnitude (l^2 norm, see SuperEuklidNorm3D<T,DESCRIPTOR> http://optilb.com/DoxyGen/html/d6/d91/classolb_1_1SuperEuklidNorm3D.html ) first and then divide it by two.

These is one way how OpenLB may help you, more details can be found in your documentation, Chapter Functors.

Operations such as multiplication (pointwise) with a constant, or linear function, … are usually done via Analytical Functors. Now, in order to manipulate a lattice Functor, you have to transform it first to an analytical functor and then apply the algebraic operations. Afterwards transform the functor back to a lattice functor, see interpolationF.h

Regards,

Albert