Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/microsoft/svirl
Svirl is GPU-accelerated solver of complex Ginzburg-Landau equations for superconductivity. It consists of time-dependent solver to describe vortex dynamics and free energy minimizer to accurately find static configurations.
https://github.com/microsoft/svirl
cuda ginzburg-landau gpu python scientific-computing superconductivity vortex
Last synced: about 1 month ago
JSON representation
Svirl is GPU-accelerated solver of complex Ginzburg-Landau equations for superconductivity. It consists of time-dependent solver to describe vortex dynamics and free energy minimizer to accurately find static configurations.
- Host: GitHub
- URL: https://github.com/microsoft/svirl
- Owner: microsoft
- License: mit
- Created: 2020-08-25T23:01:27.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2022-09-01T18:36:18.000Z (over 2 years ago)
- Last Synced: 2024-12-04T17:49:14.489Z (about 1 month ago)
- Topics: cuda, ginzburg-landau, gpu, python, scientific-computing, superconductivity, vortex
- Language: Python
- Homepage:
- Size: 1.98 MB
- Stars: 21
- Watchers: 6
- Forks: 11
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Security: SECURITY.md
Awesome Lists containing this project
README
# Svirl: GPU-accelerated Ginzburg-Landau equations solver
Svirl is an open source solver of complex Ginzburg-Landau (GL) equations
mainly used to describe magnetic vortices in superconductors. It consists of two
parts: (i) time-dependent Ginzburg-Landau (TDGL) solver [1] and (ii) GL free
energy minimizer with uses modified non-linear conjugate gradient method.The current version of Svirl can be used for two-dimensional (2D) systems only,
the work on three-dimensional (3D) solver is in progress.Svirl has intuitive Python3 API and requires nVidia GPU to run. The idea of
GPU-acceletrated TDGL solver was initially developed in the framework of [OSCon
project](http://oscon-scidac.org/) for infinite GL parameter limit.## Main features
* 2D time-dependent GL solver
* 2D GL free energy minimizer
* finite and infinite GL parameters
* user-defined material domain for order parameter
* calculates observables such as GL free energy, current density, and magnetic field
* detector of vortex positions
* uses nVidia CUDA by means of [pyCUDA](https://documen.tician.de/pycuda/)## Example
```python
import numpy as np
from svirl import GLSolvergl = GLSolver(
dx = 0.5, dy = 0.5,
Lx = 64, Ly = 64,
order_parameter = 'random',
gl_parameter = 5.0, # np.inf
normal_conductivity = 200.0,
homogeneous_external_field = 0.1,
dtype = np.float64,
)gl.solve.td(dt=0.1, Nt=1000)
gl.solve.cg(n_iter = 1000)
vx, vy, vv = gl.params.fixed_vortices.vortices
print('Order parameter: array of shape', gl.vars.order_parameter.shape)
print('%d vortices detected' % vx.size)print('Free energy: ', gl.observables.free_energy)
ch, cv = gl.observables.current_density
print('Total current density: two arrays of shape', ch.shape, '[horizontal links] and', cv.shape, '[vertical links]')ch, cv = gl.observables.supercurrent_density
print('Supercurrent density: two arrays of shape', ch.shape, '[horizontal links] and', cv.shape, '[vertical links]')
print('Magnetic field: array of shape', gl.observables.magnetic_field.shape)
```# References
1. I.A. Sadovskyy et al, Stable large-scale solver for Ginzburg-Landau equations for superconductors, [J. Comp. Phys. 294, 639 (2015)](https://doi.org/10.1016/j.jcp.2015.04.002); [arXiv:1409.8340](https://arxiv.org/abs/1409.8340).
# Code of conduct
We follow the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct).