I'm solving a problem of a rotating object (cylinder) in a fluid, initially at rest, and I want to compute the forces and moments acting on it. The object is placed at the origen and a tangencial (sliding) velocity is prescribed at the surface through cs_user_boundary_conditions.f90.
The forces and moments (with respect to the origen) are computed using cs_user_extra_operations-global_efforts.f90, for the giver boundary
Code: Select all
! Face center xnod(1) = cdgfbo(1, ifac) xnod(2) = cdgfbo(2, ifac) xnod(3) = cdgfbo(3, ifac) ! Global Efforts do ii = 1, ndim xfor(ii) = xfor(ii) + bfprp_for(ii, ifac) enddo !Global Moments tfor(1)= tfor(1)+ (bfprp_for(3, ifac)* xnod(2) - bfprp_for(2, ifac)*xnod(3)) tfor(2)= tfor(2)+ (bfprp_for(1, ifac)* xnod(3) - bfprp_for(3, ifac)*xnod(1)) tfor(3)= tfor(3)+ (bfprp_for(2, ifac)* xnod(1) - bfprp_for(1, ifac)*xnod(2))
The problem is that the resulting moment direction is not aligned with the rotation direction. Any idea why?
I'm not using any turbulence model and the convergence is ok.
I attach the file where is setted the tangencial velocity and the forces and moments computed.
Thanks for your help!