A few improvements

This commit is contained in:
Jan Benda 2015-11-16 23:33:07 +01:00
parent 11065f2b4a
commit ca9082520c
5 changed files with 37 additions and 36 deletions

View File

@ -13,6 +13,7 @@
%%%% layout %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage[left=25mm,right=25mm,top=20mm,bottom=30mm]{geometry}
\usepackage{pslatex} % nice font for pdf file
\usepackage[within=chapter]{newfloat}
%%%%% section style %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage[sf,bf,it,big,clearempty]{titlesec}
@ -151,6 +152,7 @@
aboveskip=1ex,
belowskip=2ex
}
\SetupFloatingEnvironment{lstlisting}{chapterlistsgaps=on}
%%%%%%%%%%%%% Table stuff %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage{multirow}
@ -237,7 +239,6 @@
%
% Info Box 1: Python
% The cooler programming language.
\usepackage[within=chapter]{newfloat}
\DeclareFloatingEnvironment[
fileext=lob,
listname={\tr{Info Boxes}{Info-Boxen}},

View File

@ -6,21 +6,21 @@ threshold = 20; % mV
figure()
hold on
plot(time, neuronal_data, 'color', [0.2 0.5 0.7], 'linewidth', 1., ...
'displayname', 'membrane voltage')
plot(spikes, ones(size(spikes)) .* threshold, 'ro', 'markersize', 5, ...
'displayname', 'spike times')
plot(time*1000.0, neuronal_data, 'color', [0.2 0.5 0.7], 'linewidth', 1., ...
'displayname', 'Membrane voltage')
plot(spikes*1000.0, ones(size(spikes)) .* threshold, 'r.', 'markersize', 15, ...
'displayname', 'Spike times')
line([time(1) time(end)], [threshold threshold], 'linestyle', '--', ...
'linewidth', 0.75, 'color', [0.5 0.5 0.9], 'displayname', 'threshold')
'linewidth', 0.75, 'color', [0.5 0.5 0.5], 'displayname', 'Threshold')
xlabel('time [s]', 'fontname', 'times', 'fontsize', 11)
ylabel('potential [mV]', 'fontname', 'times', 'fontsize', 11)
xlabel('Time [ms]', 'fontname', 'times', 'fontsize', 11)
ylabel('Potential [mV]', 'fontname', 'times', 'fontsize', 11)
title('ELL pyramidal neuron', 'fontname', 'times', 'fontsize', 12)
ylim([0 35])
xlim([0 2.25])
ylim([0 40])
xlim([500 1700])
box('off')
l = legend(gca,'show');
set(l,'location','northwest', 'fontsize', 7, 'linewidth', 1.);
set(l,'location','northeast', 'fontsize', 11, 'linewidth', 1.);
set(gca, 'xminortick','on','yminortick','on')
set(gca, 'tickdir','out', 'linewidth', 1.5, 'fontname', 'times', ...
'fontsize', 11)

View File

@ -387,7 +387,7 @@ Argument ist der Dateiname, und zuletzt muss das gew\"unschte Format
\lstinputlisting[caption={Skript zur Erstellung des Plots in \figref{spikedetectionfig}.}, label=niceplotlisting]{automatic_plot.m}
\begin{figure}
\begin{figure}[t]
\includegraphics{spike_detection}
\titlecaption{Automatisch erstellter Plot.}{Dieser Plot wurde vollst\"andig
mit dem Skript in Listing \ref{niceplotlisting} erstellt und

View File

@ -592,16 +592,16 @@ Eine elementweise Multiplikation (\code{.*} Operator, Listing
\end{lstlisting}
\begin{ibox}[t]{\label{matrixmultiplication} Matrixmultiplikation.}
Die Matrixmuliplikation definiert wie zwei Matrizen miteinander
multipliziert werden. Generell ist die Multiplikation nur dann
m\"oglich, wenn die Anzahl Spalten der ersten Matrize gleich der
Anzahl Zeilen in der zweiten Matrize ist. Formaler: zwei Matrizen A,
B k\"onnen mulipiziert $(A \cdot B)$ werden, wenn A die Gr\"o{\ss}e
$(m \times n)$ und B die Gr\"o{\ss}e $(n \times k)$ hat. Die
Mulitplikation ist m\"oglich wenn die ``inneren'' Dimensionen $(m
\times n) \cdot (n \times k)$ gleich sind. Daraus erkl\"art sich
auch die folgende Fehlermeldung in \matlab{}.
\begin{lstlisting}
Die Matrixmuliplikation aus der linearen Algebra ist nicht eine
elementweise Multiplikation. Die Matrixmultiplikation ist nur
dann m\"oglich, wenn die Anzahl Spalten der ersten Matrize gleich
der Anzahl Zeilen in der zweiten Matrize ist. Formaler: zwei
Matrizen A, B k\"onnen mulipiziert $(A \cdot B)$ werden, wenn A die
Gr\"o{\ss}e $(m \times n)$ und B die Gr\"o{\ss}e $(n \times k)$
hat. Die Mulitplikation ist m\"oglich wenn die ``inneren''
Dimensionen $n$ gleich sind. Daraus
erkl\"art sich auch die folgende Fehlermeldung in \matlab{}:
\begin{lstlisting}[caption={Fehlermeldung bei Matrixmultiplikation}]
>> A = [1 2 3; 4 5 6];
>> B = [2 4; 6 7];
>> A * B
@ -615,20 +615,20 @@ ans =
2 2
\end{lstlisting}
Gegeben sind folgende Matrizen:
\[A_{(3 \times 2)} = \begin{pmatrix} 1 & 2 \\ 5 & 4 \\ -2 & 3 \end{pmatrix} ,
B_{(2 \times 2)} = \begin{pmatrix} -1 & 2 \\ -2 & 5 \end{pmatrix} \]
Als Beispiel betrachten wir die beiden Matrizen
\[A_{(3 \times 2)} = \begin{pmatrix} 1 & 2 \\ 5 & 4 \\ -2 & 3 \end{pmatrix}
\quad \text{und} \quad
B_{(2 \times 2)} = \begin{pmatrix} -1 & 2 \\ -2 & 5 \end{pmatrix} \; . \]
Die ``inneren'' Dimensionen der Matrizen stimmen \"uberein ($(3
\times 2) \cdot (2 \times 2)$), die Matrixmultiplikation ist
m\"oglich. Das Produkt wird aus dem Skalarprodukt
also m\"oglich. Das Produkt wird aus dem Skalarprodukt
jeder Zeile von $A$ mit jeder Spalte aus $B$ berechnet. Nachdem
$A$ drei Zeilen und $B$ zwei Spalten hat, hat das Ergebnis von $A
\cdot B$ die Gr\"o{\ss}e $(3 \times 2)$.
\cdot B$ die Gr\"o{\ss}e $(3 \times 2)$:
\[A \cdot B = \begin{pmatrix} 1 \cdot -1 + 2 \cdot -2 & 1 \cdot 2 + 2\cdot 5 \\
5 \cdot -1 + 4 \cdot -2 & 5 \cdot 2 + 4 \cdot 5\\
-2 \cdot -1 + 3 \cdot -2 & -2 \cdot 2 + 3 \cdot 5 \end{pmatrix}
= \begin{pmatrix} -5 & 12 \\ -13 & 30 \\ -4 & 11\end{pmatrix}\]
= \begin{pmatrix} -5 & 12 \\ -13 & 30 \\ -4 & 11\end{pmatrix} \; . \]
\end{ibox}
\section{Boolesche Operationen}