
[Sponsors] 
May 12, 2010, 09:35 
Cross Product in Vorticity Confinement

#1 
New Member
Join Date: Apr 2010
Posts: 8
Rep Power: 8 
When Vorticity confinement force is described, it's always written as follows:
In the 2D case: how can i compute the cross product (ψ x w) ? Isn't ψ a vector (the gradient of a scalar field) and w a scalar (the vorticity in the 2D case is a scalar)? And isn't the cross product of a vector and a scalar undefined? When searchin in google for "Cross product of a scalar" the only site, that doesn't say ".. and a vector is not defined" is the following: http://eprints.nottingham.ac.uk/912/1/papersubmitted.pdf which says "(...) the cross product of a scalar and a vector is a × b = (−a*b_2, a*b_1)." I think that's also the way that nvidea implemented vorticity confinement in its example code. Can anybody explain this to me? is it really a cross product of a scalar and a vector? And why do 99% of the sites say this is impossible? 

May 12, 2010, 12:00 

#2 
Senior Member
Join Date: Jul 2009
Posts: 222
Rep Power: 11 
Vorticity in 2D is not a scalar, it is a vector with one nonzero component directed out of the plane. So all vector operations are applicable.


May 12, 2010, 13:05 

#3 
New Member
Join Date: Apr 2010
Posts: 8
Rep Power: 8 
OK, thank you, that would solve the syntactical problem .
but isn't vorticity defined as x wor as wikipedia says: ? Or is the definition altered for 2D? How does the vector exactly look like, that should i use then in the cross product? 

May 13, 2010, 15:19 
I got it :)

#5 
New Member
Join Date: Apr 2010
Posts: 8
Rep Power: 8 
Ah, so you do a 3DCrossProduct, even though your simulation is in 2D.
Thank you very much for your help 

July 30, 2010, 06:45 
Minus sign confusion

#7 
Member
Tibor Nyers
Join Date: Jul 2010
Location: Hungary
Posts: 91
Rep Power: 9 
Hi,
I'm implementing Jos Stam's Stable Fluids method and I would like to add vorticity confinement to create a more detailed flow. My implementation is in 2D and I have a simple problem with the very last step: psi = [ psi_x, psi_y, 0] w = [ 0, 0, vort_z ] With the cross product: f_vc_x = dx * e * psi_y * vort_z f_vc_y = dx * e * psi_x * vort_z My headache is that I've found in other source codes that my minus sign could be wrong (minus goes to the f_vc_x component instead of the y part). It's a simple cross product, but really can't figure out what is wrong. Am I missing something fundamental? Thanks! PS: hopefully, it's ok to post my question here since my problem is quite related. 

Tags 
cross product, scalar, vector, vorticity confinement 
Thread Tools  
Display Modes  


Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
vorticity calculation at symmetryplane  benconnell  OpenFOAM  0  April 14, 2009 18:45 
Vorticity IsoSurface  John  Main CFD Forum  0  April 4, 2009 23:10 
Algebraic tensor operations  maka  OpenFOAM PreProcessing  2  July 17, 2007 14:40 
vorticity depends on noninertia frame of referenc  dingxi  Main CFD Forum  3  October 18, 2006 13:13 
transform navierstokes eq. to eulereq.  pxyz  Main CFD Forum  37  July 7, 2006 08:42 