-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinverter_test_script.m
71 lines (41 loc) · 1.72 KB
/
inverter_test_script.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
clear
%% Load Saved Circuit from Circuits Folder
load(fullfile('Circuits_folder/inverterCircuits/six/', 'inverter6dotGlobalInput.mat'));
mycircuit = Circuit;
simnamefront = 'inverter6dotGlobalInput_simresults';
%% Physics Constants for Nice Signal Units
epsilon_0 = 8.854E-12;
a=1e-9;%[m]
q=1;%[eV]
Eo = q^2*(1.602e-19)/(4*pi*epsilon_0*a)*(1-1/sqrt(2)); %Kink Energy Field Strength
%% Signals
clf
myaxis = axes;
mycircuit = mycircuit.GenerateNeighborList();
mycircuit = mycircuit.Relax2GroundState(0);
mycircuit = mycircuit.CircuitDraw(0,myaxis);
numOfPeriods = 5;
TimeStepsPerPeriod = 400;
%Clock Signal Setup
clocksignal = Signal();
clocksignal.Wavelength = 50;
clocksignal.Amplitude = 15*Eo;
clocksignal.Period=200;
%Input Signal Setup
inputsignal = Signal();
inputfield = -0.001*Eo;
inputsignal.Type = 'Fermi';
inputsignal.Amplitude = 2*inputfield;
inputsignal.Period = clocksignal.Period*2;
inputsignal.Phase = inputsignal.Period/4;
inputsignal.Sharpness = 3;
inputsignal.MeanValue = inputsignal.Amplitude/2;
inputSignalsList{1} = inputsignal;
clockSignalsList{1} = clocksignal;
%% Simulation
mycircuit = mycircuit.pipeline(clockSignalsList, 'inputSignalsList', inputSignalsList, ...
'Filename', simnamefront, 'mobileCharge', 1, ...
'numOfPeriods', numOfPeriods, 'TimeSteps', numOfPeriods*TimeStepsPerPeriod, ...
'randomizedRelaxation', 0);
%% Visualization
PipelineVisualization(simnamefront,myaxis,pwd,'Inverter_GlobalInput.mp4',10);