Toroidal-poloidal decomposition in d3

211 views
Skip to first unread message

Calum Skene

unread,
Feb 16, 2022, 12:10:51 PM2/16/22
to Dedalus Users
Hi
Congratulations to the Dedalus team on the release of v3. I am wondering if this code can be used to implement a toroidal-poloidal decomposition in spherical shell coordinates. Saving two scalar fields rather than a vector field would allow for decreased memory requirements. I think there are a couple of things that this would require:

1. Surface Laplacian: A 2D Laplacian acting only in the theta and phi directions. I think this can be written in terms of the full spherical operators, but I am wondering if there is a more direct way to get this operator?
2. Gauge constraint: The toroidal and poloidal components are unique up to adding a function of r. I think this can be fixed by requiring that the average of the fields over each sphere of radius r is zero, for instance by writing "d3.Average(bP, c.S2coordsys) = 0". As when setting the integral of pressure to be zero and adding a constant tau term to the continuity equation, is there a similar way this can be done for the toroidal and poloidal equations, e.g. adding an arbitrary function of r to each equation? I've tried this but get TypeError: unsupported operand type(s) for +: 'SphericalShellBasis' and 'SphericalShellRadialBasis'

Thanks,
Calum

Ruben Rojas

unread,
May 8, 2023, 10:04:07 AM5/8/23
to Dedalus Users
Hello Callum.
I was searching for Poloidal-Toroidal decomposition in the chat and I encounter your question. I was wondering if you have had any progress with this. I am also interested in using it eventually.
Best wishes,
Ruben

Calum Skene

unread,
May 9, 2023, 3:55:50 AM5/9/23
to Dedalus Users
Hi
Unfortunately I didn't get poloidal-toroidal to work. However, I ended up solving my equations a different way and so haven't tried this in a while, so perhaps it's easier to do now.
Sorry I can't be of more help.
Best,
Calum

Ruben Rojas

unread,
May 9, 2023, 4:07:04 AM5/9/23
to Dedalus Users
Understood! Thanks for the reply. I will eventually give it a try. If you interested I'll let you know.
Best,
Ruben

Adrian Fraser

unread,
May 9, 2023, 11:31:31 AM5/9/23
to Dedalus Users
Hi Ruben,

I haven't done it myself, but I heard from Ben just the other week that it has been done before. He gave me the impression that while it's technically possible, and it does provide some speedups and reduced memory usage, it wasn't a significant enough difference that he's bothered to universally implement it in his calculations except when doing speed tests compared to other codes.

Best,
Adrian

Ruben Rojas

unread,
May 16, 2023, 7:15:14 PM5/16/23
to Dedalus Users
Hello Adrian! Thanks for the reply. Sorry I missed it a week ago. It is good to know that the performance doesn't change.
However, I am more interested in understanding the difference between dedalus spectral decomposition and a toroidal-poloidal scalar field decomposition of the velocity field. 
Best,
Ruben
Reply all
Reply to author
Forward
0 new messages