CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   FLUENT (http://www.cfd-online.com/Forums/fluent/)
-   -   Electromagnetism in my fluid. (http://www.cfd-online.com/Forums/fluent/92022-electromagnetism-my-fluid.html)

Electromagnetism in my fluid.

Hi,
As I wrote in my previous thread I would like to write my own solution for current problems in fluids.
Firstly I try to describe what I am going to achieve. I have a model with some fluid with electric contacts at the ends. When I put some potential on contacts the electric current flows through this fluids. Magnetic effects occurs and the velocity field change because of magnetic forces. I would like to describe in Fluent (in udfs) this magnetic forces caused by flowing current.
The source of magnetic forces is current so the first step in my work is to describe current density. What I know is that current density in Maxwell theory is subject to continuity equation: dq/dt + div J = 0 (where q is density of electric charge and J is density of current). I have 3d model and tried to transform it to be suitable to transport equation which I can use in Fluent.
The transport eqn in Fluent (in manual) is described as: unsteady_part + d/dxi(convection_part - diffusion_part) = sources.
The question is how I can put continuity equation of current in form of transport eqn calculating in Fluent? Generally, is that a good idea to try to do it this way?
If I could managed with current density I can calculate magnetic vector B = rot(u*J) (where u - magnetic permeability).
The force caused by flowing current can be evaluated from J and B, which means I can add sources to momentum and energy equations in Fluent using DEFINE_SOURCE macro.
This is a draft of procedures which I would like to implement in udfs.
Are these good solutions to solve my problem? If it's Ok, could you help me with this current density eqn?

Best regards