Eötvös Quantum Utilities  v5.0.144
Providing the Horsepowers in the Quantum Realm
CalculateTransport_pnp_Specq.m
Go to the documentation of this file.
1 % Calculates the conductance for specific transverse momentums - based on EQuUs v5.0.144
2 % Copyright (C) 2019 Peter Rakyta, Ph.D.
3 %
4 % This program is free software: you can redistribute it and/or modify
5 % it under the terms of the GNU General Public License as published by
6 % the Free Software Foundation, either version 3 of the License, or
7 % (at your option) any later version.
8 %
9 % This program is distributed in the hope that it will be useful,
10 % but WITHOUT ANY WARRANTY; without even the implied warranty of
11 % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 % GNU General Public License for more details.
13 %
14 % You should have received a copy of the GNU General Public License
15 % along with this program. If not, see http://www.gnu.org/licenses/.
16 %
17 %> @file CalculateTransporSpecq.m
18 %> @brief Function to calculate the transverse momentum resolved conductance through a pnp junction in the zero temperature limit.
19 %
20 %
21 %> @brief Function to calculate the transverse momentum resolved conductance through a pnp junction in the zero temperature limit.
22 %> @param qvec The transverse momentum number.
23 %> @param height The length of the junction
24 %> @param Energy The energy relative to the Fermi level
25 %> @param Opt An instance of structure #Opt
26 %> @param param An instance of structure #param
27 %> @param outputXML The absolute path to the output XML
28 %> @param pnpPotentialStrength The strength of the npn transition
29 %> @param B_loc The strength of the magnetic field
30 %> @return Returns with the calculated conductivity for the given transverse momentum number.
31  function Cq = CalculateTransport_pnp_Specq( qvec, height, Energy, EF, Opt, param, outputXML, pnpPotentialStrength, B_loc )
32  Cq = zeros(size(qvec));
33 
34  % Planck contant
35  h = 6.626e-34;
36  % The charge of the electron
37  qe = 1.602e-19;
38  % atomic distance
39  rCC = 1.42*1e-10; %In Angstrom
40  % flux quantum
41  phi0 = h/qe;
42 
43  % lattice constant in zigzag edged graphene riibon is sqrt(3)*rCC
44  lattice_constant = sqrt(3);
45 
46  % The dimensionless strength of the local magnetic field
47  eta_B = 2*pi/phi0*(rCC)^2*B_loc;
48 
49  for idx = 1:length(qvec)
50  q = qvec(idx);
51 
52  % shift the transverse momentum with the value of the vector potential to get teh mechanical momentum
53  q = q - 1.5*eta_B*height*lattice_constant;
54 
55  % creating the Ribbon class representing the twoterminal setup
56  cRibbon = Ribbon('width', 2, 'height', height, 'Opt', Opt, 'param', param, ...
57  'q', q, 'EF', EF, 'filenameOut', outputXML );
58 
59  % calculate the conductance for a given transverse momentum
60  Cq(idx) = Transport_q( Energy, B_loc, cRibbon );
61  end
62 
63 
64 
65 %% Transport_q
66 %> @brief Calculates the transvere momemntum resolved conductance for a given energy
67 %> @param Energy The energy value.
68 %> @param B The magnetic field
69 %> @param selfEnergy Logical value. Set true to use the self energy in the calculations or false to use the surface Green operator.
70  function Conductance = Transport_q( Energy, B_loc, cRibbon_loc )
71 
72  % creating funcfion handles for the magnetic vector potentials
73  CreateHandlesForMagneticField( B_loc, cRibbon_loc )
74 
75  % seeting the Energy value in the Ribbon class
76  cRibbon_loc.setEnergy( Energy )
77 
78  % Calculates the surface Green operator of the scattering region
79  cRibbon_loc.CalcFiniteGreensFunctionFromHamiltonian('PotInScatter', @pnpPotential);
80 
81  % creating function handle for the Dyson Eq.
82  Dysonfunc = @()cRibbon_loc.CustomDysonFunc( 'constant_channels', false, 'SelfEnergy', true );
83 
84  % Evaluate the Dyson Eq.
85  cRibbon_loc.FL_handles.DysonEq( 'CustomDyson', Dysonfunc );
86 
87  % Calculating the Scattering matrix
88  cRibbon_loc.FL_handles.SmatrixCalc();
89 
90  % Calculate the conductance
91  try
92  conductance = cRibbon_loc.FL_handles.Conduktance();
93  catch
94  Conductance = NaN;
95  return
96  end
97 
98  Conductance = conductance(1,2);
99 
100  %disp( ['E = ', num2str(Energy), ' conductance = ', num2str(Conductance)])
101 
102  end
103 
104 
106 %> @brief Creates and set function handles of the magnetic vector potentials in the Ribbon class
107 %> @param B The magnetic field
108  function CreateHandlesForMagneticField( B_loc, cRibbon_loc )
109  hLandaux = createVectorPotential( B_loc );
110  cRibbon_loc.setHandlesForMagneticField('scatter', hLandaux, 'lead', hLandaux );
111  end
112 
113 
115 %> @brief Creates the function handle of the magnetic vector potential
116 %> @param B The magnetic field
117 %> @return Returns with the function handle.
118  function hLandaux = createVectorPotential( B_loc )
119 
120  % lattice constant in zigzag edged graphene riibon is sqrt(3)*rCC
121  lattice_constant = sqrt(3);
122 
123  % calculating the diemnsionless strength of the magnetic field
124  eta_B = 2*pi/phi0*(rCC)^2*B_loc;
125  % constant vector potential in the systems: stabilizes the numerical computation
126  Aconst = 0;
127 
128 
129  % creting the funciton handles of the vector potentials
130  hLandaux = @(x,y)(Landaux(x,y, eta_B, Aconst, height, lattice_constant));
131 
132  end
133 
134 %% pnpPotential
135 %> @brief Potential in the scattering region (transversally translational invariant)
136 %> @param An instance of structure #coordinates containing the position of the sites
137 %> @return An array of the on-site potential.
138  function ret = pnpPotential( coordinates )
139  if isempty(pnpPotentialStrength)
140  ret = 0;
141  return;
142  end
143 
144  lattice_const = norm(coordinates.a);
145 
146  lambda = 60*lattice_const; %transition length of the pn potential in units of rCC
147  y1 = 0.20*height*lattice_const;
148  y2 = height*lattice_const - y1;
149 
150  y = coordinates.y;
151 
152 
153  ret = pnpPotentialStrength*( tanh((y-y1)/lambda) - tanh((y-y2)/lambda) )/2;
154 
155  end
156 
157 
158  end
159 
160 
161 
function CalculateTransporSpecq(qvec, width_uc, height, Energy, EF, Opt, param, outputXML, FiniteGreensFunctionFromHamiltonian)
Function to calculate the DC transverse momentum resolved conductivity in the zero temperature limit.
function setEnergy(Energy)
Sets the energy for the calculations.
Structure Opt contains the basic computational parameters used in EQuUs.
Definition: structures.m:60
A class for calculations on a ribbon of finite width for equilibrium calculations mostly in the zero ...
Definition: Ribbon.m:34
function pnpPotential(coordinates)
Potential in the scattering region (transversally translational invariant)
function CreateHandlesForMagneticField(B_loc, cRibbon_loc)
Creates and set function handles of the magnetic vector potentials in the Ribbon class.
Structure param contains data structures describing the physical parameters of the scattering center ...
Definition: structures.m:45
Structure sites contains data to identify the individual sites in a matrix.
Definition: structures.m:187
function Landaux(x, y, eta_B, Aconst, height, lattice_constant)
Vector potential in the Landau gauge parallel to the x direction.
function Transport_q(Energy, B_loc, cRibbon_loc)
Calculates the transvere momemntum resolved conductance for a given energy.
function createVectorPotential(B_loc)
Creates the function handle of the magnetic vector potential.
function CalculateTransport_pnp_Specq(qvec, height, Energy, EF, Opt, param, outputXML, pnpPotentialStrength, B_loc)
Function to calculate the transverse momentum resolved conductance through a pnp junction in the zero...