Skip to main content

GPE solver

Project description

quTARANG

Welcome to quTARANG, a fast GPU enabled python solver to solve Gross-Pitaeskii equation.

Capablities of quTARANG

It is a solver developed to study turbulence in quantum systems specially in Bose-Einstein condensates. It can run on both GPU and CPU.

The documentation of code is available at quTARANG.

Dependencies

quTARANG depends on the following packages:

  • numpy
  • cupy (If you want to use GPU)
  • pathlib
  • h5py
  • matplotlib

Instllation

You can install quTARANG using pip

   pip install quTARANG  

How to use:

To run a simulation:

  1. Import the required libraries

        from quTARANG import xp, Params, GPE
    
  2. Set the parameters

    Create an instance of the Params class and set the parameters according to your need. The parameters have been detailed in the documentation. Example:

    # Create an instance of the Params class for storing parameters.
        par = gpe.Params(N = [64, 64, 64],
                     L = [16, 16, 16],
                     g = 0.1,
                     dt = 0.001,
                     tmax = 5,
                     rms = [True, 0, 100])
    
  3. Initiate GPE class Create an instance of the GPE class by passing the Params instance created previously.

    # Create an instance of the GPE class.
       G = gpe.GPE(par)
    
  4. Set initial conditon

    You can give initial condition in terms of wavefunction and potential by defining their functions and passing them to the function set_init.

        # Set wavefunction
        wfc = (1/xp.pi**(1/4)) * xp.exp(-(x**2/2 + y**2/2 + z**2/2))
        
        # Set potential 
        pot = (x**2 + y**2 + z**2)/2
    
        G.set_init(wfc, pot)
    

    wfc function will be used to set the initial wavefunction and pot variable will be used to set the initial potential.

  5. Start the simulation:

        G.evolve()
    

The results are stored as hdf5 files in the cwd or the path set by the user in the Params instance.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

qutarang-0.0.1.tar.gz (15.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

qutarang-0.0.1-py3-none-any.whl (11.5 kB view details)

Uploaded Python 3

File details

Details for the file qutarang-0.0.1.tar.gz.

File metadata

  • Download URL: qutarang-0.0.1.tar.gz
  • Upload date:
  • Size: 15.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.12

File hashes

Hashes for qutarang-0.0.1.tar.gz
Algorithm Hash digest
SHA256 9a8e74f22000122c081cfdd5616a26f9e711907ed12598cafe602a270cea8c05
MD5 342b4e1f8ae4ab600fc8f7d05770b2bf
BLAKE2b-256 1cbd66a0a826182438cfbfb71b1a2de9f7ee89cfd3fb70d8b06b401c2cf6cf7c

See more details on using hashes here.

File details

Details for the file qutarang-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: qutarang-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 11.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.12

File hashes

Hashes for qutarang-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 545f37e9246c9d821fda6c14fa69760edebaa77cc67ccc9cae06f96abce528fa
MD5 14bc17d2e01dcd23c224f1af1fbfaf4e
BLAKE2b-256 a74635f982d4c361de3409c3e313c3c5971670b2aaa356407f2dec19ed47994e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page