From 149d59f7c446a9f90d2a6f438297b13602b84127 Mon Sep 17 00:00:00 2001 From: Karthik Chandrashekara Date: Wed, 14 Jul 2021 20:13:28 +0200 Subject: [PATCH] Minor changes to style of scripting and other cosmetic changes. --- .../test_MOTSimulator.m | 28 ++++++++++++------- 1 file changed, 18 insertions(+), 10 deletions(-) diff --git a/MOT Capture Process Simulation/test_MOTSimulator.m b/MOT Capture Process Simulation/test_MOTSimulator.m index 632899c..31a690a 100644 --- a/MOT Capture Process Simulation/test_MOTSimulator.m +++ b/MOT Capture Process Simulation/test_MOTSimulator.m @@ -7,9 +7,9 @@ OptionsStruct.SimulationMode = '2D'; OptionsStruct.TimeStep = 50e-06; % in s OptionsStruct.SimulationTime = 4e-03; % in s OptionsStruct.SpontaneousEmission = true; -OptionsStruct.Sideband = true; -OptionsStruct.PushBeam = true; -OptionsStruct.Gravity = true; +OptionsStruct.Sideband = false; +OptionsStruct.PushBeam = false; +OptionsStruct.Gravity = false; OptionsStruct.BackgroundCollision = true; OptionsStruct.SaveData = false; OptionsStruct.SaveDirectory = 'C:\DY LAB\MOT Simulation Project\Calculations\Code\MOT Capture Process Simulation'; @@ -43,11 +43,11 @@ clear OptionsStruct %% - Plot initial distribution Simulator.setInitialConditions(); % - sampling the position distribution -Simulator.InitialPositions = Simulator.initialPositionSampling(); +InitialPositions = Simulator.initialPositionSampling(); % - sampling the velocity distribution -Simulator.InitialVelocities = Simulator.initialVelocitySampling(); +InitialVelocities = Simulator.initialVelocitySampling(); NumberOfBins = 100; -Plotting.plotPositionAndVelocitySampling(Simulator, NumberOfBins); +Plotting.plotPositionAndVelocitySampling(NumberOfBins, InitialPositions, InitialVelocities); %% - Plot distributions of magnitude and direction of initial velocities NumberOfBins = 50; @@ -75,20 +75,28 @@ Plotting.plotAngularDistributionForDifferentBeta(Simulator, Beta) Simulator.setInitialConditions(); Plotting.plotCaptureVelocityVsAngle(Simulator); -%% - Plot Phase Space with Acceleration Field +%% - Plot Phase Space -Simulator.NumberOfAtoms = 200; +Simulator.NumberOfAtoms = 100; +MinimumVelocity = 0; MaximumVelocity = 150; NumberOfBins = 200; %Along each axis IncidentAtomDirection = 0*2*pi/360; IncidentAtomPosition = 0; -Plotting.plotPhaseSpaceWithAccelerationField(Simulator, MaximumVelocity, NumberOfBins, IncidentAtomDirection, IncidentAtomPosition) +Plotting.plotPhaseSpaceWithAccelerationField(Simulator, MinimumVelocity, MaximumVelocity, NumberOfBins, IncidentAtomDirection, IncidentAtomPosition) +%% - Plot trajectories along the 3 directions + +Simulator.NumberOfAtoms = 100; +MaximumVelocity = 150; +IncidentAtomDirection = 0*2*pi/360; +IncidentAtomPosition = 0; +Plotting.plotDynamicalQuantities(Simulator, MaximumVelocity, IncidentAtomDirection, IncidentAtomPosition); %% - Scan parameters % ONE-PARAMETER SCAN -NumberOfPointsForParam = 10; %iterations of the simulation +NumberOfPointsForParam = 5; %iterations of the simulation % Scan Cooling Beam Power PowerArray = linspace(0.1, 1.0, NumberOfPointsForParam) * Simulator.TotalPower; % Scan Cooling Beam Detuning