Eötvös Quantum Utilities  v4.9.146
Providing the Horsepowers in the Quantum Realm
Square_Lead_Hamiltonians.m
Go to the documentation of this file.
1 %% Eotvos Quantum Transport Utilities - Square_Lead_Hamiltonians
2 % Copyright (C) 2009-2015 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 %> @addtogroup lattices Lattices
18 %> @{
19 %> @file Square_Lead_Hamiltonians.m
20 %> @brief Class to create the Hamiltonian of one unit cell in a translational invariant lead made of square lattice structure, including the SSH model.
21 %> @}
22 %> @brief Class to create the Hamiltonian of one unit cell in a translational invariant lead made of square lattice structure, including the SSH model.
23 %%
25 
26 
27 methods (Static = true)
28 %% SquareLattice_Lead_Hamiltonians
29 %> @brief Creates Hamiltonians H_0 and H_1 for square lattice structure
30 %> @param lead_param An instance of structure #Lattice_Square (or its subclass) containing the physical parameters.
31 %> @param M Number of sites in the cross section of the lead.
32 %> @return [1] The Hamiltonian of one slab in the ribbon.
33 %> @return [2] The coupling between the slabs.
34 %> @return [3] The transverse coupling between the slabs for transverse calculations.
35 %> @return [4] A structure Coordinates containing the coordinates of the sites.
36  function [H0, H1, H1_transverse, coordinates] = SquareLattice_Lead_Hamiltonians( lead_param, M )
37 
38  % check the structure containing the physical parameters
39  supClasses = superclasses(lead_param);
40  if sum( strcmp( supClasses, 'Lattice_Square' ) ) == 0
41  error(['EQuUs:Lattices:Square_Lead_Hamiltonians:SquareLattice_Lead_Hamiltonians'], 'Invalid type of the input parameter');
42  end
43 
44  if isempty(M)
45  error(['EQuUs:Square_Lead_Hamiltonians:SquareLattice_Lead_Hamiltonians'], 'The input parameter M is empty')
46  end
47 
48  epsilon = lead_param.epsilon;
49  vargamma = lead_param.vargamma;
50 
51  H0 = sparse(1:M,1:M,epsilon,M,M) - sparse(1:M-1,2:M,vargamma,M,M) - sparse(2:M,1:M-1,vargamma,M,M);
52  H1 = sparse(1:M,1:M,-vargamma,M,M);
53 
54  coordinates = structures('coordinates');
55  coordinates.x = transpose(1:M);
56  coordinates.y = zeros(M,1);
57  coordinates.a = [0; 1];
58 
59  if M == 1
60  H0 = full(H0);
61  H1 = full(H1);
62  end
63 
64  coordinates.b = [M,0];
65  H1_transverse = sparse(M,1,-vargamma,M,M);
66 
67 
68  end
69 
70 %% SSH_Lead_Hamiltonians
71 %> @brief Creates Hamiltonians H_0 and H_1 of the SSH model.
72 %> @param lead_param An instance of structure #Lattice_SSH (or its subclass) containing the physical parameters.
73 %> @return [1] The Hamiltonian of one slab in the ribbon.
74 %> @return [2] The coupling between the slabs.
75 %> @return [3] The transverse coupling between the slabs for transverse calculations.
76 %> @return [4] A structure Coordinates containing the coordinates of the sites.
77  function [H0, H1, H1_transverse, coordinates] = SSH_Lead_Hamiltonians( lead_param )
78 
79  % check the structure containing the physical parameters
80  supClasses = superclasses(lead_param);
81  if sum( strcmp( supClasses, 'Lattice_SSH' ) ) == 0
82  error(['EQuUs:Lattices:Square_Lead_Hamiltonians:SSH_Lead_Hamiltonians'], 'Invalid type of the input parameter');
83  end
84 
85  epsilon = lead_param.epsilon;
86  vargamma1 = lead_param.vargamma1;
87  vargamma3 = lead_param.vargamma3;
88  deltaAB = lead_param.deltaAB;
89  if isempty( deltaAB )
90  deltaAB = 0;
91  end
92 
93  H0 = zeros(2,2);
94  H1 = zeros(2);
95 
96  H0(1,2) = -vargamma1;
97  H0(2,1) = -vargamma1;
98  H0(1,1) = deltaAB/2 + epsilon;
99  H0(2,2) = -deltaAB/2 + epsilon;
100 
101  H1(2,1) = -vargamma3;
102 
103  H1_transverse = [];
104 
105  coordinates = structures('coordinates');
106  coordinates.x = transpose(1:2);
107  coordinates.y = zeros(2,1);
108  coordinates.a = [0; 1];
109 
110 
111  end
112 
113 %% Lieb_Lead_Hamiltonians
114 %> @brief Creates Hamiltonians H_0 and H_1 for Lieb lattice structure
115 %> @param lead_param An instance of structure #Lattice_Lieb (or its subclass) containing the physical parameters.
116 %> @param M Number of sites in the cross section of the lead.
117 %> @return [1] The Hamiltonian of one slab in the ribbon.
118 %> @return [2] The coupling between the slabs.
119 %> @return [3] The transverse coupling between the slabs for transverse calculations.
120 %> @return [4] A structure Coordinates containing the coordinates of the sites.
121  function [H0, H1, H1_transverse, coordinates] = Lieb_Lead_Hamiltonians( lead_param, M )
122 
123  % check the structure containing the physical parameters
124  supClasses = superclasses(lead_param);
125  if sum( strcmp( supClasses, 'Lattice_Lieb' ) ) == 0
126  error(['EQuUs:Lattices:Square_Lead_Hamiltonians:Lieb_Lead_Hamiltonians'], 'Invalid type of the input parameter');
127  end
128 
129  if isempty(M)
130  error(['EQuUs:', class(obj), ':Lieb_Lead_Hamiltonians'], 'The input parameter M is empty')
131  end
132 
133 
134  epsilon = lead_param.epsilon;
135  vargamma = lead_param.vargamma;
136  N = 3*M;
137 
138 
139  h00=toeplitz([epsilon,-vargamma,0]);
140  h01=-vargamma*[0 0 0; 0 0 0; 0 1 0];
141  h1=-vargamma*[0 1 0; 0 0 0; 0 0 0];
142 
143  H0=sparse([],[],[], N,N);
144  H1=sparse([],[],[], N,N);
145 
146  for l=1:3;
147  for m=1:3;
148  H0 = H0 + sparse(l:3:N,m:3:N,h00(l,m),N,N) + sparse(l:3:N-3,m+3:3:N,h01(l,m),N,N) + sparse(l+3:3:N,m:3:N-3,h01(m,l),N,N);
149  H1 = H1 + sparse(l:3:N,m:3:N,h1(l,m),N,N);
150  end
151  end
152 
153  coordinates = structures('coordinates');
154  coordinates.x = zeros(N,1);
155  coordinates.x(1:3:N) = transpose(1:M);
156  coordinates.x(2:3:N) = transpose(1:M);
157  coordinates.x(3:3:N) = transpose(1:M)+0.5;
158  coordinates.y = zeros(N,1);
159  coordinates.y(1:3:N) = 0.5;
160  coordinates.a = [0; 1];
161 
162  if M == 1
163  H0 = full(H0);
164  H1 = full(H1);
165  end
166 
167  H1_transverse = sparse([],[],[], N,N);
168  for l=1:3;
169  for m=1:3;
170  H1_transverse = H1_transverse + sparse(3*M-3+l,m,h01(l,m),3*M,3*M);
171  end
172  end
173  coordinates.b = [M,0];
174 
175  end
176 
177 end % methods static
178 
179 
180 end
Class to create the Hamiltonian of one unit cell in a translational invariant lead made of square lat...
function Transport(Energy, B)
Calculates the conductance at a given energy value.
Class containing physical parameters of the square lattice.
function Hamiltonians(varargin)
Function to create the custom Hamiltonians for the 1D chain.
Structure param contains data structures describing the physical parameters of the scattering center ...
Definition: structures.m:45
Class containing physical parameters of the Lieb lattice.
Definition: Lattice_Lieb.m:26
Structure sites contains data to identify the individual sites in a matrix.
Definition: structures.m:187
Structure containing the coordinates and other quantum number identifiers of the sites in the Hamilto...
Definition: Coordinates.m:24
function structures(name)