Anistropic Viscosity in Dedalus 3

20 views
Skip to first unread message

Marty Hewitt

unread,
Jul 2, 2025, 8:47:20 AMJul 2
to Dedalus Users
I am trying to solve for motion in an incompressible fluid in Dedalus 3, the setup is very similar to the Rayleigh Benard example given on the website. I have attached a screenshot with my equations of motion. The fluid is simulated on a 2D plane, here u is a 2D vector giving velocity in the plane and v is a scalar field representing velocity into and out of the plane.

I am trying to go from an isotropic viscosity, as in the term "nu*div(grad_u)", to an anistropic viscosity, in which the diffusion along the x direction is subjected to a different viscosity than the diffusion along the z direction. 

I have tried a few different ways to implement this but my ideas have not worked. Is there a way to implement anistropic viscosity in the vector equations of Dedalus 3? I imagine this is not an uncommon thing to do, but I don't know how to implement it while still using the symbolic vector equations. Thanks for the help!
Screenshot 2025-07-01 at 12.43.16 PM.png

Keaton Burns

unread,
Jul 2, 2025, 9:52:07 AMJul 2
to dedalu...@googlegroups.com
Hi Marty,

The easiest approach is probably to just enter the equations componentwise with partial derivatives, but it should still be possible in the vectorial interface if you define a (spatially constant, so no bases) diffusivity tensor K encoding the different diffusivities, and contract with it like div(K@grad_u). 

Best,
-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 view this discussion visit https://groups.google.com/d/msgid/dedalus-users/0ffaafc9-a049-4096-9c1c-c928e2f5de3an%40googlegroups.com.

Marty Hewitt

unread,
Jul 3, 2025, 11:06:03 AMJul 3
to dedalu...@googlegroups.com
Hello Keaton,

Thanks for the quick reply! 

I had ended up figuring out the issue a little while after I submitted the ticket, I did end up using a tensor formed from an outer product of the basis vectors. I appreciate that you included the functionality for an outer product operation like this in Dedalus, it’s very intuitive.

Regards,
Marty

You received this message because you are subscribed to a topic in the Google Groups "Dedalus Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/dedalus-users/s9JkU8SX1KU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to dedalus-user...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/dedalus-users/CADZXxBiMbV_DtwUvC11r20y512uKMR6LAZLddzFe18LoOZhONQ%40mail.gmail.com.

Reply all
Reply to author
Forward
0 new messages