2D Rayleigh-Benard

276 views
Skip to first unread message

Jason Lee

unread,
Sep 12, 2016, 8:27:41 AM9/12/16
to Dedalus Users

Dear all,

I'm still working on RB convection these days.
A question here is that I found even though the Rayleigh number is 5000, the water flow is static.
I post the two temperature perturbation maps at t = 500 and 1157.
The no-slip boundary condition is used.
This is kind of weird since the critical Rayleigh number should be around 1700 according to these curves above.

So I would like to ask that whether you guys have tested this before?

My setup is:
# Parameters
Lx, Lz = (2.*math.sqrt(2), 1.)
Prandtl = 6.8
Rayleigh = 5e3

# Create bases and domain
x_basis
= de.Fourier('x', 128, interval=(0, Lx))
z_basis
= de.Chebyshev('z', 128, interval=(0, Lz))
domain
= de.Domain([x_basis, z_basis], grid_dtype=np.float64)

# 2D Boussinesq hydrodynamics
problem
= de.IVP(domain, variables=['p','b','u','w','bz','uz','wz','vort'])
problem
.parameters['P'] = (Rayleigh * Prandtl)**(-1/2)
problem
.parameters['R'] = (Rayleigh / Prandtl)**(-1/2)
problem
.parameters['F'] = F = 1
problem
.add_equation("dx(u) + wz = 0")
problem
.add_equation("dt(b) - P*(dx(dx(b)) + dz(bz)) - w         = -(u*dx(b) + w*bz)")
problem
.add_equation("dt(u) - R*(dx(dx(u)) + dz(uz)) + dx(p)     = -(u*dx(u) + w*uz)")
problem
.add_equation("dt(w) - R*(dx(dx(w)) + dz(wz)) + dz(p) - b = -(u*dx(w) + w*wz)")
problem
.add_equation("bz - dz(b) = 0")
problem
.add_equation("uz - dz(u) = 0")
problem
.add_equation("wz - dz(w) = 0")
problem
.add_equation("uz - dx(w) + vort = 0")
problem
.add_bc("left(b) = 0")
problem
.add_bc("left(u) = 0")
problem
.add_bc("left(w) = 0")
problem
.add_bc("right(b) = 0")
problem
.add_bc("right(u) = 0")
problem
.add_bc("right(w) = 0", condition="(nx != 0)")
problem
.add_bc("integ(p, 'z') = 0", condition="(nx == 0)")

# Build solver
solver
= problem.build_solver(de.timesteppers.RK443)
logger
.info('Solver built')

# Initial conditions
x
= domain.grid(0)
z
= domain.grid(1)
b
= solver.state['b']
bz
= solver.state['bz']
u
= solver.state['u']
w
= solver.state['w']
vort
= solver.state['vort']

# Random perturbations, initialized globally for same results in parallel
gshape
= domain.dist.grid_layout.global_shape(scales=1)
slices
= domain.dist.grid_layout.slices(scales=1)
rand
= np.random.RandomState(seed=42)
noise
= rand.standard_normal(gshape)[slices]

# Linear background + perturbations damped at walls
#zb, zt = z_basis.interval
bpert
= noise
#bpert = rd.array_gen_from_file('tmpr_init.dat')
b
['g'] = bpert
u
['g'] = rd.array_gen_from_file('uvel_init.dat')
w
['g'] = rd.array_gen_from_file('wvel_init.dat')
# b.differentiate('z', out=bz)

# Integration parameters
solver
.stop_sim_time = 2000
solver
.stop_wall_time = 20000 * 60.
solver
.stop_iteration = np.inf

# CFL
CFL
= flow_tools.CFL(solver, initial_dt=2.5e-3, cadence=5, safety=0.1,
                     max_change
=1.5, min_change=0.5, max_dt=0.0025)
CFL
.add_velocities(('u', 'w'))

Thank you guys

Regards

Jason

Jason Lee

unread,
Sep 18, 2016, 9:18:13 PM9/18/16
to Dedalus Users
Hey guys,

I'm really confused. Hope someone could help.

Best

Jason

Daniel Lecoanet

unread,
Sep 19, 2016, 1:10:00 PM9/19/16
to dedalu...@googlegroups.com
Hi Jason,

You might be interested in looking at the following paper where we calculated 2D convective steady states for Rayleigh numbers up to 4x10^5:


So it is completely normal to find steady states at Rayleigh numbers substantially larger than the critical Rayleigh number.  These steady states are often unstable to 3D perturbations.

Daniel

--
You received this message because you are subscribed to the Google Groups "Dedalus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dedalus-users+unsubscribe@googlegroups.com.
To post to this group, send email to dedalu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dedalus-users/cbe09310-af89-4ece-902f-0402bea30ca7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Ben Brown

unread,
Sep 19, 2016, 2:27:25 PM9/19/16
to dedalus-users
Jason,
     At moderately large aspect ratios (e.g. A=4), we've been seeing stable flywheel states establish even at very high Ra (10^8 and higher) in 2-D Rayleigh-Benard.  They're very robust.

--Ben

Jason Lee

unread,
Sep 27, 2016, 1:05:06 AM9/27/16
to Dedalus Users, leco...@princeton.edu
Thank you Daniel! I will check it out.

Jason Lee

unread,
Sep 27, 2016, 1:06:24 AM9/27/16
to Dedalus Users
Thanks Ben. That would be interesting.

Jason Lee

unread,
Sep 27, 2016, 1:25:31 AM9/27/16
to Dedalus Users, leco...@princeton.edu
Hi, Daniel,

There must be some misleading. The problem in my post is that the water is static which means there is almost no motion in the flow rather than the steady state. Actually that is the thing confusing me.
Hope you guys know why.

Thanks

Jason

Keaton Burns

unread,
Sep 27, 2016, 6:12:03 AM9/27/16
to dedalu...@googlegroups.com
Hi Jason,

Can you send along all the scripts and initial condition data files you’re using, so we can test it out locally?

Thanks,
-Keaton
--
You received this message because you are subscribed to the Google Groups "Dedalus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dedalus-user...@googlegroups.com.

To post to this group, send email to dedalu...@googlegroups.com.

Jason Lee

unread,
Sep 29, 2016, 1:33:21 AM9/29/16
to Dedalus Users
Hi Keaton,

Sure.
Please note that the python script is quite verbose after I added some output lines and it cannot be parallel computed since I didn't use related syntax.

Thank you.

Jason

rayleigh_benard.py
tmpr_init.dat
uvel_init.dat
wvel_init.dat
readata.py

Keaton Burns

unread,
Sep 29, 2016, 11:55:35 AM9/29/16
to dedalu...@googlegroups.com
Hi Jason,

I ran it until about t=50 on my laptop and made the attached video using the dedalus analysis hdf5 outputs.  From this it looks like the instability is saturating into steady rolls.  Are you seeing actually static (zero) velocities in your text-based outputs?  If so, maybe there’s an issue with how you’re writing out to the text files?

-Keaton
--
You received this message because you are subscribed to the Google Groups "Dedalus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dedalus-user...@googlegroups.com.
To post to this group, send email to dedalu...@googlegroups.com.
frames.mp4
Reply all
Reply to author
Forward
0 new messages