# Code for Dynamics of Rotating Bose-Einstein Condensate

**URL:** <https://community.freefem.org/t/code-for-dynamics-of-rotating-bose-einstein-condensate/2756>\
**Category:** General Discussion\
**Created:** [October 24, 2023, 1:33pm UTC](https://community.freefem.org/t/code-for-dynamics-of-rotating-bose-einstein-condensate/2756 "2023-10-24T13:33:30Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![lchen123123](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/lchen123123/32/1950_2.png) [@lchen123123](https://community.freefem.org/u/lchen123123)\
**Post date:** [October 24, 2023, 1:33pm UTC](https://community.freefem.org/t/code-for-dynamics-of-rotating-bose-einstein-condensate/2756/1 "2023-10-24T13:33:30Z")

</div>

Dear Forum Members,

I am currently working on solving the Gross-Pitaevskii (GP) equation for a rotating Bose-Einstein Condensate (BEC) in 2D and am in search of an example finite-element code that would allow me to study its dynamic evolution.

The 2D GP equation for a rotating BEC in these units can be expressed as:  
i \frac{\partial \psi}{\partial t} = -\frac{1}{2} \nabla^2 \psi + \frac{1}{2} (x^2 + y^2) \psi - \Omega L\_z \psi + g|\psi|^2 \psi  
where \Omega is the angular velocity, L\_z = x_p\_y - y_ p\_x is the angular momentum operator, and g is the interaction strength.

For the initial condition \psi(t=0,x,y), let’s simply consider, e.g., a 2D Gaussian wave packet with a small shifted center. I am particularly interested in tracking its dynamic evolution over time.

Additionally, I am wondering how the Mesh Adaptive Techniques could be incorporated into the code to facilitate the study of the dynamic evolution of vortex states.

Any guidance or example code would be greatly appreciated.

Noah
