![]() |
GPUE
v1.0
GPU Gross-Pitaevskii Equation numerical solver for Bose-Einstein condensates
|
command line parser file. More...
#include <cstdio>
#include <cstdlib>
#include <cmath>
#include <string>
#include <ctime>
#include <cuda.h>
#include <cuda_runtime.h>
#include <cufft.h>
#include <ctype.h>
#include <getopt.h>
#include "tracker.h"
#include "ds.h"
#include "constants.h"
Go to the source code of this file.
Functions | |
int | isError (int result, char *c) |
Checks if CUDA operation has succeeded. Prints to stdout. More... | |
void | parSum (double2 *gpuWfc, Grid &par) |
Performs parallel summation and renormalises the wavefunction. More... | |
void | parSum (double *gpuWfc, double *gpuParSum, Grid &par) |
Performs parallel summation and renormalises the wavefunction. More... | |
void | optLatSetup (const std::shared_ptr< Vtx::Vortex > centre, const double *V, std::vector< std::shared_ptr< Vtx::Vortex >> &vArray, double theta_opt, double intensity, double *v_opt, const double *x, const double *y, Grid &par) |
Creates the optical lattice to match the vortex lattice constant. More... | |
double | energy_calc (Grid &par, double2 *wfc) |
Calculates the energy of the condensate. More... | |
command line parser file.
Host and device declarations for simulations.
These functions and variables are necessary for carrying out the GPUE simulations. This file will be re-written in an improved form in some future release.
Definition in file split_op.h.
double energy_calc | ( | Grid & | par, |
double2 * | wfc | ||
) |
Calculates the energy of the condensate.
gpuWfc | Device wavefunction array |
Parameter | class |
int isError | ( | int | result, |
char * | c | ||
) |
Checks if CUDA operation has succeeded. Prints to stdout.
result | Function result code of CUDA operation |
c | Descriptor of CUDA operation |
void optLatSetup | ( | const std::shared_ptr< Vtx::Vortex > | centre, |
const double * | V, | ||
std::vector< std::shared_ptr< Vtx::Vortex >> & | vArray, | ||
double | theta_opt, | ||
double | intensity, | ||
double * | v_opt, | ||
const double * | x, | ||
const double * | y, | ||
Grid & | par | ||
) |
Creates the optical lattice to match the vortex lattice constant.
centre | Central vortex in condensate |
V | Trapping potential for condensate |
vArray | Vortex location array |
theta_opt | Offset angle for optical lattice relative to vortex lattice |
intensity | Optical lattice amplitude |
v_opt | Optical lattice memory address location |
x | X grid array |
y | Y grid array |
Parameter | class |
void parSum | ( | double2 * | gpuWfc, |
Grid & | par | ||
) |
Performs parallel summation and renormalises the wavefunction.
gpuWfc | GPU memory location for wavefunction |
Parameter | class |
void parSum | ( | double * | gpuWfc, |
double * | gpuParSum, | ||
Grid & | par | ||
) |
Performs parallel summation and renormalises the wavefunction.
gpuWfc | GPU memory location for wavefunction |
gpuParSum | wavefunction density |
Parameter | class |