2024-06-18 19:01:35 +02:00
|
|
|
%% This script is testing the functionalities of the Dipolar Gas Simulator
|
|
|
|
%
|
|
|
|
% Important: Run only sectionwise!!
|
|
|
|
|
|
|
|
%% - Create Simulator, Potential and Calculator object with specified options
|
|
|
|
|
|
|
|
OptionsStruct = struct;
|
|
|
|
|
|
|
|
OptionsStruct.NumberOfAtoms = 1.24E5;
|
|
|
|
OptionsStruct.DipolarPolarAngle = 0;
|
|
|
|
OptionsStruct.DipolarAzimuthAngle = 0;
|
|
|
|
OptionsStruct.ScatteringLength = 86;
|
|
|
|
|
|
|
|
OptionsStruct.TrapFrequencies = [44.97, 10.4, 126.3];
|
|
|
|
OptionsStruct.TrapDepth = 5;
|
|
|
|
OptionsStruct.BoxSize = 15;
|
|
|
|
OptionsStruct.TrapPotentialType = 'Harmonic';
|
|
|
|
|
2024-06-20 12:16:42 +02:00
|
|
|
OptionsStruct.NumberOfGridPoints = [256, 512, 256];
|
2024-06-18 19:01:35 +02:00
|
|
|
OptionsStruct.Dimensions = [50, 120, 150];
|
|
|
|
OptionsStruct.CutoffType = 'Cylindrical';
|
|
|
|
OptionsStruct.SimulationMode = 'ImaginaryTimeEvolution'; % 'ImaginaryTimeEvolution' | 'RealTimeEvolution'
|
|
|
|
OptionsStruct.TimeStepSize = 500E-6; % in s
|
|
|
|
OptionsStruct.NumberOfTimeSteps = 2E6; % in s
|
|
|
|
OptionsStruct.EnergyTolerance = 5E-10;
|
2024-06-20 12:16:42 +02:00
|
|
|
OptionsStruct.ResidualTolerance = 1E-05;
|
2024-06-18 19:01:35 +02:00
|
|
|
|
|
|
|
OptionsStruct.JobNumber = 1;
|
2024-06-19 19:45:22 +02:00
|
|
|
OptionsStruct.RunOnGPU = true;
|
2024-06-18 19:01:35 +02:00
|
|
|
OptionsStruct.SaveData = true;
|
|
|
|
OptionsStruct.SaveDirectory = './Data';
|
|
|
|
options = Helper.convertstruct2cell(OptionsStruct);
|
|
|
|
clear OptionsStruct
|
|
|
|
|
|
|
|
sim = Simulator.DipolarGas(options{:});
|
|
|
|
pot = Simulator.Potentials(options{:});
|
|
|
|
sim.Potential = pot.trap(); % + pot.repulsive_chopstick();
|
|
|
|
|
|
|
|
%-% Run Simulation %-%
|
|
|
|
[Params, Transf, psi, V, VDk] = sim.run();
|