Added figures for q1

This commit is contained in:
David Lenfesty 2021-02-06 17:07:37 -07:00
parent de3b11676d
commit b4c4964470
9 changed files with 193 additions and 33 deletions

View File

@ -4,29 +4,41 @@
\usepackage{setspace} \usepackage{setspace}
\usepackage{listings} \usepackage{listings}
\usepackage{color} \usepackage{color}
\usepackage{circuitikz} \usepackage{amsmath}
\usepackage{float} \usepackage{float}
\usepackage{caption}
\usepackage{subcaption}
\usepackage[margin=0.75in]{geometry}
\renewcommand{\thesubsection}{\indent(\alph{subsection})}
\definecolor{dkgreen}{rgb}{0,0.6,0} \definecolor{dkgreen}{rgb}{0,0.6,0}
\definecolor{gray}{rgb}{0.5,0.5,0.5} \definecolor{gray}{rgb}{0.5,0.5,0.5}
\definecolor{mauve}{rgb}{0.58,0,0.82} \definecolor{mauve}{rgb}{0.58,0,0.82}
\lstset{language=Matlab,% %\lstset{language=Matlab,%
%basicstyle=\color{red}, % %basicstyle=\color{red},
breaklines=true,% % breaklines=true,%
morekeywords={matlab2tikz}, % morekeywords={matlab2tikz},
keywordstyle=\color{blue},% % keywordstyle=\color{blue},%
morekeywords=[2]{1}, keywordstyle=[2]{\color{black}}, % morekeywords=[2]{1}, keywordstyle=[2]{\color{black}},
identifierstyle=\color{black},% % identifierstyle=\color{black},%
stringstyle=\color{mylilas}, % stringstyle=\color{mylilas},
commentstyle=\color{mygreen},% % commentstyle=\color{mygreen},%
showstringspaces=false,%without this there will be a symbol in the places where there is a space % showstringspaces=false,%without this there will be a symbol in the places where there is a space
numbers=left,% % numbers=left,%
numberstyle={\tiny \color{black}},% size of the numbers % numberstyle={\tiny \color{black}},% size of the numbers
numbersep=9pt, % this defines how far the numbers are from the text % numbersep=9pt, % this defines how far the numbers are from the text
emph=[1]{for,end,break},emphstyle=[1]\color{red}, %some words to emphasise % emph=[1]{for,end,break},emphstyle=[1]\color{red}, %some words to emphasise
%emph=[2]{word1,word2}, emphstyle=[2]{style}, % %emph=[2]{word1,word2}, emphstyle=[2]{style},
} %}
\lstset{basicstyle=\small,
keywordstyle=\color{mauve},
identifierstyle=\color{dkgreen},
stringstyle=\color{gray},
numbers=left,
xleftmargin=5em
}
\title{ECE 456 - Problem Set 1} \title{ECE 456 - Problem Set 1}
\date{2021-02-06} \date{2021-02-06}
@ -45,27 +57,70 @@
\singlespacing \singlespacing
\pagenumbering{arabic} \pagenumbering{arabic}
\section{Question 1} \section*{Question 1}
\subsection{(a)} \subsection*{(a)}
Beginning with the following two equations:
\begin{equation} \begin{equation}
N = $\int_{-\infty}^{\infty}$ \label{eq:N_old}
N = \int_{-\infty}^{\infty}\frac{\gamma_1 f_1(E) + \gamma_2 f_2(E)}{\gamma_1 + \gamma_2} D(E-U) dE,
\end{equation} \end{equation}
\begin{equation}
\label{eq:I_old}
I = \frac{q}{\hbar}\frac{\gamma_1 \gamma_2}{\gamma_1 + \gamma_2} \int_{-\infty}^{\infty}[f_1(E) - f_2(E)] D(E-U) dE,
\end{equation}
and changing the variable of integration to $E' = E - U$:
\begin{equation*}
N = \int_{-\infty}^{\infty}\frac{\gamma_1 f_1(E' + U) + \gamma_2 f_2(E' + U)}{\gamma_1 + \gamma_2} D(E') dE',
\end{equation*}
\begin{equation*}
I = \frac{q}{\hbar}\frac{\gamma_1 \gamma_2}{\gamma_1 + \gamma_2} \int_{-\infty}^{\infty}[f_1(E' + U) - f_2(E' + U)] D(E') dE'.
\end{equation*}
Replacing $E' \rightarrow E$, we obtain equations \ref{eq:N_new} and \ref{eq:I_new}.
\begin{equation}
\label{eq:N_new}
N = \int_{-\infty}^{\infty}\frac{\gamma_1 f_1(E + U) + \gamma_2 f_2(E + U)}{\gamma_1 + \gamma_2} DE dE,
\end{equation}
\begin{equation}
\label{eq:I_new}
I = \frac{q}{\hbar}\frac{\gamma_1 \gamma_2}{\gamma_1 + \gamma_2} \int_{-\infty}^{\infty}[f_1(E + U) - f_2(E + U)] DE dE,
\end{equation}
\subsection*{(b)}
For the provided constants, the plots of the number of channel electrons and the channel current follow:
\section{Design Section} \begin{figure}[H]
\centering
\begin{subfigure}{0.5\textwidth}
% Mess around with widths later
\centering
\includegraphics[width=\textwidth]{q1b_electrons.png}
\caption{Plot of channel electrons vs. drain voltage.}
\label{fig:q1b_electrons}
% Note that the comment after \end{subfigure} is required for side by side figures
\end{subfigure}%
\begin{subfigure}{0.5\textwidth}
% Mess around with widths later
\centering
\includegraphics[width=\textwidth]{q1b_current.png}
\caption{Plot of channel current vs. drain voltage.}
\label{fig:q1b_current}
\end{subfigure}
In order to design the desired systems, the Xilinx Vivado software was \caption{Number of electrons and current versus drain voltage.}
used to write VHDL code that described the operation of each circuit. \end{figure}
\newpage
\paragraph{MUX / DEMUX Circuit}
To implement the multiplexing/demultiplexing system, the following circuit had to be written in VHDL.
The VHDL architecture below was written to implement this circuit in hardware.
Below is our code. Note that some variable names are different from those in the example code.
\begin{lstlisting}[language=Matlab] \begin{lstlisting}[language=Matlab]
clear all; clear all;
%% Constants %% Constants
@ -144,7 +199,7 @@ for n = 1:length(voltages)
% Unsure why U_P is updated incrementally, perhaps to avoid oscillations? % Unsure why U_P is updated incrementally, perhaps to avoid oscillations?
%U_P = tmpU_P; %U_P = tmpU_P;
U_P = U_P + 0.1 * (tmpU_P - U_P) %U_P = U_P + 0.1 * (tmpU_P - U_P);
end end
% Calculate current based on solved potential. % Calculate current based on solved potential.
@ -173,4 +228,56 @@ xlabel('Drain voltage [V]');
ylabel('Current [A]'); ylabel('Current [A]');
\end{lstlisting} \end{lstlisting}
\subsection*{(c)}
\begin{figure}[H]
\centering
\begin{subfigure}{0.5\textwidth}
% Mess around with widths later
\centering
\includegraphics[width=\textwidth]{q1c_1.png}
\caption{Plot of channel electrons vs. drain voltage.}
\label{fig:q1c_1}
% Note that the comment after \end{subfigure} is required for side by side figures
\end{subfigure}%
\begin{subfigure}{0.5\textwidth}
% Mess around with widths later
\centering
\includegraphics[width=\textwidth]{q1c_2.png}
\caption{Plot of channel electrons vs. drain voltage.}
\label{fig:q1c_1}
% Note that the comment after \end{subfigure} is required for side by side figures
\end{subfigure}
\begin{subfigure}{0.5\textwidth}
% Mess around with widths later
\centering
\includegraphics[width=\textwidth]{q1c_3.png}
\caption{Plot of channel electrons vs. drain voltage.}
\label{fig:q1c_1}
% Note that the comment after \end{subfigure} is required for side by side figures
\end{subfigure}%
\begin{subfigure}{0.5\textwidth}
% Mess around with widths later
\centering
\includegraphics[width=\textwidth]{q1c_4.png}
\caption{Plot of channel electrons vs. drain voltage.}
\label{fig:q1c_1}
% Note that the comment after \end{subfigure} is required for side by side figures
\end{subfigure}
\begin{subfigure}{0.5\textwidth}
% Mess around with widths later
\centering
\includegraphics[width=\textwidth]{q1c_5.png}
\caption{Plot of channel electrons vs. drain voltage.}
\label{fig:q1c_1}
% Note that the comment after \end{subfigure} is required for side by side figures
\end{subfigure}%
\caption{Visual representation of the fermi functions of the contacts and channel.}
\end{figure}
% TODO appendix for Part C code
\end{document} \end{document}

BIN
PS1/q1b_current.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

BIN
PS1/q1b_electrons.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View File

@ -41,6 +41,7 @@ D = D ./ (dE*sum(D));
N_0 = 0; N_0 = 0;
voltages = linspace(0, 1, 101); voltages = linspace(0, 1, 101);
dV = voltages(2) - voltages(1);
% Terminal Voltages % Terminal Voltages
V_G = 0; V_G = 0;
@ -80,13 +81,65 @@ for n = 1:length(voltages)
% Unsure why U_P is updated incrementally, perhaps to avoid oscillations? % Unsure why U_P is updated incrementally, perhaps to avoid oscillations?
%U_P = tmpU_P; %U_P = tmpU_P;
U_P = U_P + 0.1 * (tmpU_P - U_P) U_P = U_P + 0.1 * (tmpU_P - U_P);
end end
% Calculate current based on solved potential. % Calculate current based on solved potential.
% Note: f1 is dependent on changes in U but has been updated prior in the loop % Note: f1 is dependent on changes in U but has been updated prior in the loop
I(n) = q * (q/hbar) * (gamma_1 * gamma_1 / gamma_sum) * dE * sum((f_1-f_2).*D); I(n) = q * (q/hbar) * (gamma_1 * gamma_1 / gamma_sum) * dE * sum((f_1-f_2).*D);
if (abs(V_D-0.0) <= dV/2)
figure(3); title('VD = 0.0 V');
subplot(2,3,1); plot(f_1,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f1(E+U)'); ylabel('ENERGY [eV]'); title('VD = 0.0 V');
subplot(2,3,2); plot(D/100,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('D(E)/100'); ylabel('ENERGY [eV]'); title('VD = 0.0 V');
subplot(2,3,3); plot(f_2,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f2(E+U)'); ylabel('ENERGY [eV]'); title('VD = 0.0 V');
subplot(2,3,5); plot(f_1-f_2,E,'--',D/100,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f1(E+U)-f2(E+U), D(E)/100'); ylabel('ENERGY [eV]'); title('VD = 0.0 V');
elseif (abs(V_D-0.2) <= dV/2)
figure(4); title('VD = 0.2 V');
subplot(2,3,1); plot(f_1,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f1(E+U)'); ylabel('ENERGY [eV]'); title('VD = 0.2 V');
subplot(2,3,2); plot(D/100,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('D(E)/100'); ylabel('ENERGY [eV]'); title('VD = 0.2 V');
subplot(2,3,3); plot(f_2,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f2(E+U)'); ylabel('ENERGY [eV]'); title('VD = 0.2 V');
subplot(2,3,5); plot(f_1-f_2,E,'--',D/100,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f1(E+U)-f2(E+U), D(E)/100'); ylabel('ENERGY [eV]'); title('VD = 0.2 V');
elseif (abs(V_D-0.5) <= dV/2)
figure(5); title('VD = 0.5 V');
subplot(2,3,1); plot(f_1,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f1(E+U)'); ylabel('ENERGY [eV]'); title('VD = 0.5 V');
subplot(2,3,2); plot(D/100,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('D(E)/100'); ylabel('ENERGY [eV]'); title('VD = 0.5 V');
subplot(2,3,3); plot(f_2,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f2(E+U)'); ylabel('ENERGY [eV]'); title('VD = 0.5 V');
subplot(2,3,5); plot(f_1-f_2,E,'--',D/100,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f1(E+U)-f2(E+U), D(E)/100'); ylabel('ENERGY [eV]'); title('VD = 0.5 V');
elseif (abs(V_D-0.8) <= dV/2)
figure(6); title('VD = 0.8 V');
subplot(2,3,1); plot(f_1,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f1(E+U)'); ylabel('ENERGY [eV]'); title('VD = 0.8 V');
subplot(2,3,2); plot(D/100,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('D(E)/100'); ylabel('ENERGY [eV]'); title('VD = 0.8 V');
subplot(2,3,3); plot(f_2,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f2(E+U)'); ylabel('ENERGY [eV]'); title('VD = 0.8 V');
subplot(2,3,5); plot(f_1-f_2,E,'--',D/100,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f1(E+U)-f2(E+U), D(E)/100'); ylabel('ENERGY [eV]'); title('VD = 0.8 V');
elseif (abs(V_D-1.0) <= dV/2)
figure(7); title('VD = 1.0 V');
subplot(2,3,1); plot(f_1,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f1(E+U)'); ylabel('ENERGY [eV]'); title('VD = 1.0 V');
subplot(2,3,2); plot(D/100,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('D(E)/100'); ylabel('ENERGY [eV]'); title('VD = 1.0 V');
subplot(2,3,3); plot(f_2,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f2(E+U)'); ylabel('ENERGY [eV]'); title('VD = 1.0 V');
subplot(2,3,5); plot(f_1-f_2,E,'--',D/100,E,'k-'); axis([-0.1 1.1 -1 1]);
xlabel('f1(E+U)-f2(E+U), D(E)/100'); ylabel('ENERGY [eV]'); title('VD = 1.0 V');
end
end end

BIN
PS1/q1c_1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

BIN
PS1/q1c_2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

BIN
PS1/q1c_3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

BIN
PS1/q1c_4.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

BIN
PS1/q1c_5.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB