GPUE  v1.0
GPU Gross-Pitaevskii Equation numerical solver for Bose-Einstein condensates
split_op.h
Go to the documentation of this file.
1 //##############################################################################
16 //##############################################################################
17 
18 #ifndef SPLIT_OP_H
19 #define SPLIT_OP_H
20 
21 #include <cstdio>
22 #include <cstdlib>
23 #include <cmath>
24 #include <string>
25 #include <ctime>
26 #include <cuda.h>
27 #include <cuda_runtime.h>
28 #include <cufft.h>
29 #include <ctype.h>
30 #include <getopt.h>
31 #include "tracker.h"
32 #include "ds.h"
33 #include "constants.h"
34 
35 #ifdef __linux
36  #include<omp.h>
37 #elif __APPLE__
38  //printf("OpenMP support disabled due to Clang/LLVM being behind the trend.",);
39 #endif
40 
48 int isError(int result, char* c); //Checks to see if an error has occurred.
49 
57 void parSum(double2* gpuWfc, Grid &par);
58 
67 void parSum(double* gpuWfc, double *gpuParSum, Grid &par);
68 
82 void optLatSetup(const std::shared_ptr<Vtx::Vortex> centre, const double* V,
83  std::vector<std::shared_ptr<Vtx::Vortex>> &vArray, double theta_opt,
84  double intensity, double* v_opt, const double *x, const double *y,
85  Grid &par);
86 
94 double energy_calc(Grid &par, double2* wfc);
95 
96 #endif
% % % starting wavefunction wfc
Definition: GPE_2d.m:52
Dastructure for simulation runtime parameters.
Useful physical constants.
V
Definition: en.py:68
c
Definition: VtxCorr.m:27
Vortex lattice position, orientation, and tracking.
void parSum(double2 *gpuWfc, Grid &par)
Performs parallel summation and renormalises the wavefunction.
int isError(int result, char *c)
Checks if CUDA operation has succeeded. Prints to stdout.
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.
double energy_calc(Grid &par, double2 *wfc)
Calculates the energy of the condensate.
Class to hold the variable map and grid information.
Definition: ds.h:86
def par
Definition: plot.py:237