CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Solving a curl equation (new to OpenFoam)

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 4, 2020, 07:15
Question Solving a curl equation (new to OpenFoam)
  #1
New Member
 
Manuel Ausserlechner
Join Date: Mar 2020
Posts: 2
Rep Power: 0
aussm is on a distinguished road
Hello,


i am new to OpenFoam and i want to solve the equation:


fvm::ddt(rho) = fvc::curl(vel x rho)


*rho and vel are volVectorField's
*i want to solve it with euler time steps in the loops
*vel is always normal to rho (magnitude is constant =1)
*initial conditions of rho should look like a circle, so i want to set the initialFieldValues with setFields



i created a own solver by copying "scalarTransportFoam", what do i have to take care of to change my solver the right way?


i would be so happy about some help


LG aussm
aussm is offline   Reply With Quote

Old   March 21, 2020, 15:09
Default
  #2
Member
 
MNM
Join Date: Aug 2017
Posts: 69
Rep Power: 9
SHUBHAM9595 is on a distinguished road
Hey Manuel, I assume that rho is not density here...
Well, Just use the createFields.H of scalarTransportFoam and declare both the volVectorFields similar to "U".
And for the latter part where you want to solve for rho using fvm and fvc simultaneously at the same timestep... which is kind of difficult with the current syntax.....U should guide the solver to use the old values of rho in the fvc part.....So replace
Code:
fvc::curl(vel ^ rho);
with something like
Code:
fvc::curl(vel ^ rho.oldTime() );
and it should work.......
SHUBHAM9595 is offline   Reply With Quote

Reply

Tags
curl, initial condition, setfields, vector field


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
problem with Min/max rho tH3f0rC3 OpenFOAM 8 July 31, 2019 09:48
Free surface issues with interDyMFoam for hydroturbine oumnion OpenFOAM Running, Solving & CFD 0 October 6, 2017 14:05
Floating point exception error lpz_michele OpenFOAM Running, Solving & CFD 53 October 19, 2015 02:50
Micro Scale Pore, icoFoam gooya_kabir OpenFOAM Running, Solving & CFD 2 November 2, 2013 13:58
Could anybody help me see this error and give help liugx212 OpenFOAM Running, Solving & CFD 3 January 4, 2006 18:07


All times are GMT -4. The time now is 23:47.