title: Put a logo into frametitle

text: > **Possible Duplicate:**   >  Positioning logo in the front page as well as slides Preparing a presentation with the `beamer` class, I want to put a logo into the `\frametitle` of each slide. I tried               \newcommand{\ft}[1]{\frametitle{{#1}\hfill\includegraphics{picture}}}      but it seems that `\hfill` only insert a fixed length of space between `#1` and `picture`, rather than put the picture to the right most of the title line. Anyone has an idea? And how is `\hfill` defined in `beamer`?


title: How to extract the name and the content of a command?

text: I realize that the title might be not understandable. I want to have a command `\printit{}` which takes 1 arguments and display it after some test. Inside `\printit` I would like to test if `#1` is just a piece of text, or if it is itself a macro. For simplicity, I could assume the following cases :   * #1 is just some text, like `hallo`   * #1 has the form `\mycomA{content}`   * #1 has the form `\mycomB{content}` where `\mycomA{}` and `\mycomB{}` are commands defined by myself. Depending on the case, I want `\printit{}` to typeset `hallo`, or `content` with some formatting depending on the case. For simplicity I could also assume that the arguments of `\mycomA` and `\mycomB` are simple text. How should I proceed ? Here is the empty MWE :)               \documentclass{article}     \newcommand{\mycomA}[1]{\textbf{#1}}% just for the example     \newcommand{\mycomB}[1]{\textit{#1}}% just for the example     \newcommand{\printit}[1]{%     % If #1 has the form mycomA(...) THEN       case A : content = % extract the content of mycomA     % ElseIf #1 has the form mycomB(...) THEN       case B : content = % extract the content of mycomB     % Else THEN       case C : content = #1           \begin{document}         \printit{hallo}         \printit{\mycomA{123}}         \printit{\mycomB{qweqwe}}         \printit{hallo}          \end{document}


title: Change Enumerate Items to Khmer Unicode Alphabet

text: Here is my code that change default enumerate item to `roman number`               \documentclass{article}     \def\theenumi{\roman{enumi}}     \def\theenumii{\roman{enumii}}     \begin{document}         \begin{enumerate}             \item one             \begin{enumerate}                 \item one                 \item two             \end{enumerate}             \item two             \begin{enumerate}                 \item one                 \item two             \end{enumerate}         \end{enumerate}     \end{document}      My purpose is to change the second level `\enumii` to `khmer unicode alphabet`. Is there any way to do that? Or is there any way to map the `latin alphabet` to `khmer alphabet`, i.e. > a->ក > > b->ខ > > c->គ for example? And here is the link to download `Khmer fonts`


title: How do I use QTikZ on a standalone file

text: My file is quite simple, e.g.,               \documentclass{article}     \usepackage[landscape]{geometry}     \usepackage{tikz}     \begin{document}       \begin{tikzpicture}       \draw (-1.5,0) -- (1.5,0);       \draw (0,-1.5) -- (0,1.5);       \draw (0,0) circle (1cm);      \end{tikzpicture}     \end{document}      but QTikZ barfs on it, saying,               [LaTeX] Line 1: LaTeX Error: Can be used only in preamble.     [LaTeX] Line 1:      [LaTeX] Line 1: See the LaTeX manual or LaTeX Companion for explanation.         ...                                                                                l.-6     \documentclass                       {article}      [LaTeX] Line 1:  ==> Fatal error occurred, no output PDF f      Is there way to make QTikZ take standalone pictures and remove the preamble? === To clarify, I would like to interactively edit the file with QTikZ, and then when it is ready, run it through `pdflatex`. Later on, I would like to make fine tuning again with QTikZ, and then recompile the file. It is quite a nuisance to remove the preamble each time I go into QTikZ, and it is equally annoying to maintain two files, one with the preamble and the other one included in it, which has the actual figure. Is there a better way?


title: Why are LaTeX macros so inconsistent?

text: I use LaTeX daily to write my papers, and while I find it a very nice tool to make documents in, some things about the system outright bother me; such as the very inconsistent macro system. A few examples: Many, but not all block macros/commands look like this:               \begin{lstlisting}     ...     \end{lstlisting}      except for math blocks which look like this:               \[ ... \]      Inline macros usually look like this:               \footnote{...}      Except when they suddenly look like this:               {\em ...} % I'm aware that \emph{...} also exits      Or like this:               \lstinline|...|      Or even like this:               $ ... $      So why is it that LaTeX is so inconsistently designed? It seems that for every package I add, there's a new way of writing it, which makes the learning curve of LaTeX insanely steep, why not just keep it all consistent and uniform?


title: Help with figures in TikZ

text: How can we make Figures 1 and 2 below with TikZ and LaTeX? In Figure 2, I want to give different colors to different quadrants. ![Figure 1](http://i.stack.imgur.com/PVAuc.png) ![Figure 2](http://i.stack.imgur.com/wGu40.png)


title: Using a half-space with abbreviations in cleveref?

text: I'm using cleveref with abbreviated forms such as Fig. 1, and would like to have them typeset using a thin space/half-space rather than the ordinary non- breaking space. However, I'd only want this after the words that are actually abbreviated, which suggests I may have to do some manual hacking. (I guess I could use `\crefname` with a negative space…?) I know some other similar packages have an option for this, but not cleveref, as far as I can see. Neither do I see any easy way of modifying the behavior of cleveref myself. Or is this simply a bad idea, typographically? I've read that some typographical books do recommend it, and do think the spacing in `Fig.~1` looks excessive. Then again, I'm not sure what behavior would be desired when describing ranges, for example; is `Figs.\,1 to~3` acceptable? (I guess this latter issue is more of a matter of opinion, though…)


title: French typography recommendations

text: > **This question led to a new package:**   >  `impnattypo` The French government publications office (Imprimerie Nationale) publishes a list of recommendations for French typography. I'm wondering how to implement some of these in LaTeX. I might actually come up with more later as I continue reading this booklet. **End of chapters/parts** In addition to the recommendations of removing footers on the last page of chapters/parts, it is recommended that these pages do not have less than 6 lines. I am guessing (it is not written) that if there are less than 6 lines, it is recommended to increase that number by forcing a page break in (one of) the previous page. **Hyphenation rules**   * No odd page should finish with an hyphenated word;   * No more than 3 lines with hyphenated words should follow one another.


title: How to make correct pdfbookmarks for the nomenlature?

text: In this example the pdfbookmark for the nomenclature is linked to the list of tables. How to make here the correct bookmark?                \documentclass[listof=totoc,]{scrbook}            \usepackage{makeidx}      \usepackage{nomencl}      \makenomenclature        \usepackage{hyperref}           \begin{document}           \cleardoublepage\pdfbookmark{\contentsname}{toc}\tableofcontents      \listoffigures      \listoftables           \cleardoublepage\addcontentsline{toc}{chapter}{Nomenclature}\markboth{Nomenclature}{Nomenclature}      \printnomenclature           \chapter{Chapter One}      Test\nomenclature{i.e.}{id est}           \end{document}


title: TeXstudio: How to associate tex syntax color scheme to non tex file?

text: In TeXstudio I want to associate different files with tex coloring scheme. For example, I open **.stex** file and the syntax is not colored. This **.stex** file is the same tex file, I just renamed it for some reason. I've putted **.stex** extension in my ini file:                Files\Default%20File%20Filter=TeX files (*.tex *.bib *.sty *.cls *.mp      ***.stex**)      But it does nothing.


title: Includegraphics in the Appendix

text: The present question is related to this previous one.               \documentclass[11pt,a4paper,oneside]{report}     \pagestyle{headings}     \usepackage{setspace}     \usepackage{array}     \usepackage{covington}     \usepackage[danish,english]{babel}     \usepackage{pslatex}     \usepackage{float}     \usepackage[demo]{graphicx}     \usepackage{titlesec}     \usepackage{amssymb}     \usepackage{typearea}     \usepackage[a4paper]{geometry}     \geometry{includefoot=false, heightrounded=true, top=4.5cm, bottom=6cm, left=4.7cm, right=4.7cm}      \usepackage[toc,page]{appendix}     \usepackage{longtable}     \usepackage{caption}     \newif\ifappendix % snippet appendice     \makeatletter     \def\LT@c@ption#1[#2]#3{%       \LT@makecaption#1\fnum@table{#3}%       \def\@tempa{#2}%       \ifx\@tempa\@empty\else          {\let\\\space          \addcontentsline{\ifappendix toc\else lot\fi}{table}{\protect\numberline{\thetable}{#2}}}%       \fi}     \makeatother     \usepackage{multirow}     \usepackage{morefloats}     \usepackage{booktabs}     \newcolumntype{R}{>{\raggedleft\arraybackslash}p{2cm}}     \usepackage[bottom,norule]{footmisc}     \setlength\belowcaptionskip{1\baselineskip}           \begin{document}          \tableofcontents      \addcontentsline{file}{sec_unit}{entry}      \addcontentsline{toc}{chapter}{\bibname}          \chapter{Lorem}          Lorem ipsum. Lorem ipsum. Lorem ipsum.          \begin{appendices}          \appendixtrue     \setcounter{table}{0}     \renewcommand*{\thetable}{A.\arabic{table}}     \renewcommand*{\tablename}{Appendix}          \begin{figure}[H]\centering     \includegraphics[scale=1]{pic1.jpg} \caption{Metonymy}.\label{fig:Metonymy}     \end{figure}          \begin{figure}[H]\centering     \includegraphics[scale=1]{pic2.jpg} \caption{Synonymy}.\label{fig:Synonymy}     \end{figure}          \end{appendices}          \end{document}      My MWE outputs an appendix with two figures and no Appendix title. Besides the figure names, I would like to have an Appendix title at the top of the page. Something like the following does not work here because I have captions for the figures already.               \caption{Example\label{appendix: Example}}\\


title: Lightbox in Latex

text: Is there a package or simple code for a lightbox in LaTeX? (I'd like to display the solutions of some math problems in a clever way.) Could `hyperref` be used to prompt a small pdf or jpeg and have it be overlaid on the original pdf document (without the lightbox effect)?


title: Join arrows and wide nodes with tikz

text: I want to create a flow chart with tikz that looks like this:               -------------------------------     |  wide node                  |     -------------------------------                 |     -------------------------------     |  wide node                  |     -------------------------------                 |      -------------------------      |         |              |     ------   ------       ------     |sub1|   |sub2|       |sub3|     ------   ------       ------       |        |            |       -----------------------                |     -------------------------------     |  wide node                  |     -------------------------------      Looks like a pretty basic flow chart. I tried a lot of stuff to join the arrows and get the sub nodes as wide as the other nodes, but I could not get it to work, my current code looks like this:               \documentclass{minimal}     \usepackage{tikz}          \usetikzlibrary{shapes,arrows,arrows,decorations.pathmorphing,backgrounds,fit,positioning,     shapes.symbols,chains}          \begin{document}     \tikzstyle{block} = [rectangle, draw=black, thick, fill=white, text width=8em,      text centered, minimum height=4em]     \tikzstyle{dummyblock} = [rectangle]     \tikzstyle{line} = [draw, -latex']     \begin{center}     \begin{tikzpicture}[node distance=3.5cm]     \node [block] (A) {A};     \node [block,below of= A] (B) {B};     \node [dummyblock,below of=B] (BB) {};     \node [block, below of = BB] (D) {D};     \node [block, left of=D] (C) {C};     \node [block, right of=D] (E) {E};     \node [block, below of=D] (F) {F};     \path [line] (A.south) -| (B.north);     \path [line] (B.south) -| (BB.north);     \path [line] (BB.south) -| (C);     \path [line] (BB.south) -| (D);     \path [line] (BB.south) -| (E);     \path [line] (C.south) -| (F.north);     \path [line] (D.south) -| (F.north);     \path [line] (E.south) -| (F.north);     \end{tikzpicture}\end{center}     \end{document}      Does someone have any clue on how to fix this... any help would be much appreciated!


title: Change pagestyle to plain for first page of an unnumbered chapter

text: I'm writing my undergrad senior-thesis (at a German university) with the following specifications:               \documentclass[12pt,headsepline,footsepline]{scrreprt}     \usepackage{fancyhdr}     \pagestyle{fancy}     \renewcommand{\chaptermark}[1]{ \markboth{#1}{} }     \renewcommand{\sectionmark}[1]{ \markright{#1}{} }     \fancyhead[LO]{}     \fancyhead[RE]{\thechapter}     \usepackage{apacite}     ...     \begin{document}     \begin{titlepage}...\end{titlepage}     \pagenumbering{roman}     \tableofcontents     \listoffigures     \listoftables     \chapter*{List of Abbreviations}     \addcontentsline{toc}{chapter}{List of Abbreviations}     ...     \chapter*{Abstract}     \addcontentsline{toc}{chapter}{Abstract}          \chapter{Introduction}     \setcounter{page}{1}     \pagenumbering{arabic}     ...     ...     \bibliographystyle{apacite}     \bibliography{references}      Almost everything is working now, only one problem remains: the "list of figures" and "list of tables" chapters use pagestyle plain and appear in the TOC; however, the list of abbreviations (which I created with `\chapter*` because I don't want it to be numbered) uses the full header both on the first and the second page (which is not perfect but acceptable), plus it puts "LIST OF TABLES" in the header, i.e. the wrong name and in capital letters, even though all the other chapter-names in the headers are written in small letters (thanx to the `\renewcommand{\chaptermark}[1]{ \markboth{#1}{} } \renewcommand{\sectionmark}[1]{ \markright{#1}{} }` commands). Also, for the references chapter, which is created automatically by the `apacite`-package, the word "REFERENCES" in the header is written in capital letters. Does anyone know how I can change those two things?


title: How to change the font of paragraph titles in memoir?

text: I'm using the memoir class with the "veelo" chapter style and would like to display the title of a paragraph in italics rather than boldface.               \paragraph{This should be displayed in italics}      I found `\chaptitlefont` but nothing similar for paragraphs.


title: Text Mode Macros with MathJax

text: I find here that MathJax supports only math-mode macros (such as `\sqrt{}`) and not text-mode macros (such as `\begin{align}`). I am currently building a small wiki that will host mathematics articles, and so expect that both kinds of macros will be desirable. The page linked above recommends a TeX to HTML converter, but (unless I'm misunderstanding) these all seem to be _alternatives_ to MathJax. What is a good solution to get the attractive rendering of mathematical symbols (as in MathJax) combined with the standard text-mode alignment environments found in LaTeX?


title: beamer: How to make an outline document with modified frame environment

text: In LaTeX Beamer there is the frame environment that can be used to put certain information on a slide. I want to create an outline document where the frame environment is replaced by something else. I tried doing so by defining new commands `\newcommand{\beginframe}{\begin{frame}}` and `\newcommand{\endframe}{\end{frame}}` however I get errors that suggest that you cannot put environment commands in new commands. Can I abstract away the frame environment in such a way, that I can just remove the environment? I would prefer not to use `\newtheorem{frame}` to have lots of frame environments then that are possibly numbered.


title: AUCTeX region preview in Emacs

text: I've installed AUCTeX and passed the circ.tex preview, however, when I'm trying to add more elements (enumerate, tabular) to preview with `\PreviewEnvironment{..}` in the preamble, AUCTeX ignores these lines and render only math, table, sections, and other default elements. I've tried to add custom environments in `preview-default-preamble`, but no success. It's probably a part of the same problem, but if I try `C-c C-p C-e` (preview the environment with a pointer inside this environment), it says `no enclosing outer environment found` -- a pretty rare error, Google finds it only in preview.el sources. `preview-image-type` is set to `dvipng` (png and gswin32c.exe do not work properly). Emacs 23.3 and TeX Live 2011 are the counterpart.


title: mdframed with tikz method: putting line numbers outside of frame

text: I want to number the lines in a `mdframed` environment with the line numbers appearing on the left of the frame, outside of it.               \documentclass{article}     \usepackage[framemethod=latex]{mdframed}          \newdimen\linenumbersep          \newcommand{\linenumber}[1]{%       \linenumbersep 4pt%       \advance\linenumbersep\mdflength{innerleftmargin}%       \advance\linenumbersep\mdflength{innerlinewidth}%       \advance\linenumbersep\mdflength{middlelinewidth}%       \advance\linenumbersep\mdflength{outerlinewidth}%       \advance\linenumbersep\mdflength{linewidth}%       \makebox[0pt][r]{{\rmfamily\tiny#1}\hspace*{\linenumbersep}}}          \begin{document}          \ttfamily          \begin{mdframed}     \linenumber{1}(define fact\\     \linenumber{2}    (lambda (n)\\     \linenumber{3}        (if (= n 0)\\     \linenumber{4}            1\\     \linenumber{5}            (* n (fact (- n 1))))))     \end{mdframed}          \end{document}      After typesetting this document, I get ![enter image description here](http://i.stack.imgur.com/p0KSm.png) as expected. But when the `tikz` method is used for drawing the frame by changing the second line of the source document               \usepackage[framemethod=tikz]{mdframed}      the line numbers are not visible anymore, giving ![enter image description here](http://i.stack.imgur.com/FtH9l.png) Is it possible to make this example work with the `tikz` method? I want to use something like this in a package I am writing to typeset a program listing with the help of Pygments. The line numbers would be generated automatically.


title: How can I remove “Listing #: ” from listings caption?

text: I am working on a C++ reference manual for myself and I want good-looking listings. The Stack Overflow question entitled LaTeX source code listing like in professional books was very helpful but, for the life of me, I can't find anywhere on the Internet how to remove the "Listing #" part of the listing captions. Below is a screenshot of what I have at the moment. I want to remove the front part of the listing caption; I don't want to remove the caption altogether, though, because I want to use it to show the name of the source file. Any ideas? ![enter image description here](http://i.stack.imgur.com/21YOZ.png)


title: How to avoid that the \newenvironment text is placed on one single page

text: I am using the `\newenvironment` command for the first time and well it's causing troubles. I am using it for creating a new `theorem` environment               \documentclass{article}     \usepackage{amsmath, amssymb}     \usepackage{amsthm , amsfonts, latexsym}     \usepackage{tikz}     \usepackage{shadethm}     \usepackage[mathscr]{euscript}     \usepackage{graphics,graphicx}     \usepackage{enumerate}     \usepackage{color}                              \theoremstyle{definition}      \newshadetheorem{lems}{Lemma}[section]                              \newenvironment{lem}[1][]{       \definecolor{shadethmcolor}{HTML}{00FFFF}       \begin{lems}[#1]\hspace*{1mm}     }{\end{lems}}       ` Using this new `theorem` environment I am doing a proof of a lemma that needs some pages of space.               \begin{document}     \begin{lem}     Let $H$ be a connected S-thin hypergraph, and $A \boxtimes B$ and $C \boxtimes D$ be two     decompositions of $H$ with respect to the strong product. Then there exists a decomposition     $$ A_C \boxtimes A_D \boxtimes B_C \boxtimes B_D $$     of $H$ such that $A =  A_C \boxtimes A_D, B= B_C \boxtimes B_D , C= A_C \boxtimes B_C,      D=A_D \boxtimes B_D$.     \begin{proof}     The idea of the proof is by using the PFD of the cartesian skeleton $H^{\Box}$ of $H$  to define four proper factors, such that     each factor has as vertex set the set of one of our desired factors, e.g. $A_C$. Then we define the desired factors of $H$ by defining projections on $H$ where the vertex set is given by the composed factors of the cartesian skeleton and such that the     edges obey the definition of the strong product. Finally via those projections it is shown that $A=A_C \boxtimes A_D$.\                              Let $ H_1 \Box H_2 \Box ... \Box H_n $ be the unique PFD of a cartesian skeleton $H^{\Box}$ of $H$ . Let $I_A$ be the subset of the index set $ {1,2,...,n}$ with $V(A)=V(\Box_{i \in I_A} H_i)$     and $I_B, I_C$ and $I_D$ be defined analogously. Furthermore set      $$ H_{A,C} = \Box_{i \in I_A \cap I_C} H_i$$     and define $H_{A,D}, H_{B,C}$ and $H_{B,D}$ similarly. Then     $$ H^{\Box} = H_{A,C} \Box H_{A,D} \Box H_{B,C} \Box H_{B,D} . $$     It will be convenient to use only four coordinates $(x_1,x_2,x_3,x_4)$  for every vertex $x \in V(G)$ henceforth. Of course it is possible that not all of the intersections $I_A \cap I_C, I_A \cap I_D, I_D \cap I_C$     and $I_B \cap I_D$ are nonempty. Suppose that $I_B \cap I_C = \emptyset$ then $I_A \cap I_D \neq \emptyset$. If in addition $I_A \cap I_C$ were empty, then $I_A = I_D$ and thus $I_B=I_C$, but then      would be nothing to prove.   \     We can thus assume that all but possibly $I_B \cap I_D$ are nonempty and at least three of the four      coordinates are nontrivial, that is to say, there are at least two vertices that differ in the first, second     and third coordinates, but it is possible that all vertices have the same fourth coordinate. \     Clearly, for $y=(y_1,y_2,y_3,y_4),$      $$V(A^y) = { (x_1,x_2,y_3,y_4) | x_1 \in V(H_{A,C}), x_2 \in V(H_{A,D}) } $$     $$V(B^y) = { (y_1,y_2,x_3,x_4) | x_3 \in V(H_{B,C}), x_4 \in V(H_{B,D}) } $$     $$V(C^y) = { (x_1,y_2,x_3,y_4) | x_1 \in V(H_{A,C}), x_3 \in V(H_{B,C}) } $$     $$V(D^y) = { (y_1,x_2,y_3,x_4) | x_2 \in V(H_{A,D}), x_4 \in V(H_{B,D}) } $$     are the vertex sets of the $A-,B-,C-$ and $D-$ layers of $H$. \                              We now define $A_C$ as $p_1(H)$, namely $V(A_C) = V(H_{A,C})$ and  $${x_1^1,...,x_k^1 } \in E(A_C)$$     if and only if there are vertices $ \tilde x_1=(x_1^1,x_1^2,x_1^3,x_1^4),...,      \tilde x_k =(x_k^1,x_k^2,x_k^3,x_k^4) \in H \text { such that} $     $$ \exists e \in E(H) : \exists S \subseteq I={2,3,4} : p_1(e) = { x_1^1,...,x_k^1}  $$     \begin{itemize}                               \item[(i)] $ p_s(e) \subseteq e_s \in E_s , \forall s \in S$      \item[(ii)]$ |e| = |p_s(e)|,  \forall s \in S$      \item[(iii)] $|p_i(e)|=1, \forall i \in I \setminus S$     \end{itemize}                               It is clear what is meant by $A_D, B_C$ and $B_D$. For the proof of the lemma it suffices to show that     $A = A_C \boxtimes A_D$. Recall that $A$ is obtained by projection of $H$ onto the vertex set of $A$. We     call this projection $p_A$ and define $p_B,p_C,p_D$ analogously. With our present coordinatization we thus have      $$p_A(x_1,x_2,x_3,x_4) = (x_1,x_2,-,-), $$     $$p_B(x_1,x_2,x_3,x_4) = (-,-,x_3,x_4), $$     $$p_C(x_1,x_2,x_3,x_4) = (x_1,-,x_3,-), $$     $$p_D(x_1,x_2,x_3,x_4) = (-,x_2,-,x_4). $$     In order to show that $A=A_C \boxtimes A_D$, it suffices to prove that for $e={\tilde x_1,..., \tilde x_k  } \in H$ holds     $$ p_A(e) \in A $$ if and only if     $$ p_1(e) \in A_C \text{ and either is } e \text{ an edge in }A_D \text{, hence } p_2(e) \subseteq e \in A_D, |e|=|p_2(e)| $$     $$\text{ or not and thus  } |p_2(e)|=1 $$     (wlog. we assume that the edge of $A_C$ is of minimal rank, otherwise we could easily add a case to the above definition      where the edge of $A_D$ was the minimal one. But for the sake of clarity we omit this case).                                Suppose that $ {p_A \tilde x_1,..., p_A \tilde x_k } \subseteq e \in A$. We can assume, wlog., that     $\tilde x_1, ... , \tilde x_k $ are chosen such that ${ \tilde x_1 ,... , \tilde x_k } \in E(H).$ But then     $ {p_1 \tilde x_1, ... , p_1 \tilde x_k } \in A_C $ and ${p_2 \tilde x_1, ... , p_2 \tilde x_k } \in A_D$     by the definition of $A_C$ and $A_D$. \     On the other hand, suppose that the edge     ${ (x_1^1,-,-,-),(x_2^1,-,-,-),...,(x_k^1,-,-,-}$ is in $A_C$ and ${(_,x_1^2,-,-),...,(-,x_t^2,-,-)} $ is     in $A_D , t \leq t $. \     Then there are vertices $\tilde x_1, \tilde x_2, ... , \tilde x_k, ... , \tilde x_t$ of the form     $$ \tilde x_i = ( x_i^1, x_i^2, x_i^3, x_i^4) $$     with ${ \tilde x_1 , ... , \tilde x_k } \in E(H)$ and ${ \tilde x_1 , ... ,\tilde x_t } \in E(H)$. \     From this we infer that there are edges     $$ { (x_1^1,-,x_1^3,-),...,(x_s^1,-,x_s^3,-) } \in E(C) , k \leq s \leq t $$     $$ {(-,x_1^2,-,x_1^4),...,(-,x_r^2,-,x_r^4) } \in E(D), k \leq r \leq t $$     Since $H = C \boxtimes D$ this implies that     $$ {(x_1^1,x_1^2,x_1^3,x_1^4),...,(x_s^1,x_s^2,x_s^3,x_s^4) } \in E(H) \text{ where wlog. } s \leq r$$     and hence ${(x_1^1,x_1^2,-,-),...,(x_s^1,x_s^2,-,-) } \subseteq e \in E(A)$.      \end{proof}     \end{lem}     \end{document}      ` It isn't the proof that troubles me, hence no one has to check it for me ;). The problem is rather that the proof needs several pages but LaTeX puts it all on one page, which is obviously a bit disadvantageous. Therefore I would be glad if someone could tell me how to adjust the environment in such a way that the content flows across pages.


title: Specifying CJK fonts for pdftex and CJK.sty

text: I'm compiling a Japanese TeX file written with `CJK.sty`, and using the IPA fonts. I used `ttf2tfm` to generate `tfm` files. Is there a way to tell `pdftex` that a set of `tfm` files correspond to one Unicode truetype fonts, directly from inside a tex file? I'm currently using               \pdfmapfile{+ipamp.map}      with the `ipamp.map` file of the form               ipamp00 <ipamp.ttf <ipamp00.enc     ipamp01 <ipamp.ttf <ipamp01.enc     ipamp02 <ipamp.ttf <ipamp02.enc     ipamp03 <ipamp.ttf <ipamp03.enc     ... continuing to ipampff ...      which, I think, is rather stupid. Furthermore, the embedding of the fonts to the pdf file, which is done at the last stage of `pdftex`, is very slow. My question then is if there's a better way. For example, for `dvipdfmx`, you can just have one line               ipamp@Unicode@ unicode ipamp.ttf      Background: I'm preparing a Japanese TeX file for submission to a preprint server (arXiv) which doesn't unfortunately accept XeTeX or LuaTeX. The server only has the wadalab font for Japanese, which is rather ugly. So I'd like to use IPA instead. The way I described above works, but doesn't sound perfect.


title: Latex Coding for Table

text: \documentclass[12pt,a4paper]{article}     \begin {document}     \begin{table}         \begin{tabular}{llllll|lllllllll}         \hline         ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ \\ \hline         ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ \\         ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ \\         ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ \\         ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ \\         ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ \\         ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ \\         ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ \\         ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ \\         ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ \\         ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ & ~ \\         \end{tabular}     \end{table}     \end{document}      ![enter image description here](http://i.stack.imgur.com/jAm2E.png) **How to Create a blank row like now no 2? I mean which code is need to be added? How to bold the line three times and margin the cell space??**


title: How to make beamer overlays with Tikz node

text: I have a diagram of 4 nodes in my beamer slide.                 \begin{figure}[h]       \begin{centering}       \begin{tikzpicture}[system/.style={draw,rectangle,rounded corners=3,minimum width=2cm,text width=1.8cm,text centered}]         \node [system] (fe) {Feature Extraction};         \node [system] (am) [right=of fe] {Acoustic Model};         \node [system] (lm) [right=of am] {Language Model};         \node [system] (d) [below=of lm] {Decoder};              \draw[->] (fe) |- (am);         \draw[->] (am) |- (d);         \draw[->] (lm) -- (d.north);            \end{tikzpicture}       \end{centering}       \end{figure}      How can I in a second slide "highlight" one of the nodes, like I can do with `<alert@n>` for a item in a list? With highlighting I mean for example giving a color and thickening the lines.


title: How to make the PDFs produced by `pdflatex` smaller?

text: I feel that the PDFs produced by `pdflatex` are too huge. So for example my 50 page book with no illustrations is 500KB. I feel it should be more like 50K or even less. The `.tex` files together are just 40KB. Anyone knows why the final PDF is so huge and is there a way to compress it to make smaller?


title: How can I reduce the size of figures and/or the size of the final PDF document?

text: I usually include .pdf figures (vector graphics) in LaTeX files. The problem is that when I compile everything, the resulting file, which also has .pdf extension, is too large. The size of the final PDF document is approximately equal to the sum of the size of the PDF document without figures plus the total size of the .pdf figures that are to be included.


title: PDF Build Quality - TexStudio

text: I've written a technical report in LaTex using TexStudio. It is only 20 pages long, but it includes a lot of images and diagrams. The final build size is 7.5mb. Is there a way that you can build a lower quality PDF? I need it to be less than 5mb in order to submit it online. Any help or guidance will be appreciated. Thanks.


title: Is it possible to reduce pdf file size by optimizing images in texniccenter?

text: > **Possible Duplicate:**   >  How to make the PDFs produced by `pdflatex` smaller? I have some images in PNG. Those are large in size. I am editing using texniccenter, utilizing this pdflatex.exe. Now, my question is, is there any way to tell the texniccenter to take those original (large) PNG images and use resize it to a smaller size and then make the pdf? Thank you.


title: pdftex reduce PDF size: reduce image quality?

text: > **Possible Duplicate:**   >  How to make the PDFs produced by `pdflatex` smaller? I wrote my thesis in LaTeX and so far I always compiled with `pdflatex`. The thesis is 150 pages with many pictures and graphs. The resulting PDF file is 40 MB. Now, I'm facing the problem that for administrative purposes they need it in a file which shouldn't exceed 30 MB in size (don't ask me why). How can I reduce the size of the output PDF? I don't mind loosing a bit of quality in the images but I don't seem to find any way of doing that.


title: Multiple letters without spacing in Math

text: Is there something I can add to the preamble of my document such that multiple letters without spacing in a Math environment (such as `$NP$`) do not have extra spacing between them and are not considered multiple distinct variables? Right now, I have to use `$\mathit{NP}$` to prevent any extra spacing, but I feel that it is more natural to add a space between the letters if they are a different variable (`$N P$`). For example, if I want the multi-letter variable `NP`, I want to be able to say `$NP$` which would automatically be replaced by `$\mathit{NP}$`. If I want `N` and `P` to have the proper inter-variable spacing, I want to do that only when they are separated by a space, like so: `$N P$`. Is there a way to achieve this? Would it break something that I'm unaware of? # Edit: Here's a screenshot that shows what I mean: ![enter image description here](http://i.stack.imgur.com/3LXFh.png) So basically, is it possible for line 1 to automatically give me line 3 and for line 2 to give me line 2?


title: Two letter variable names

text: In math mode, TeX assumes "hidden multiplication" (so that two variable names put nearby have invisible multiplication between), so that, AFAICT, expressions like `$ABC$` are rendered with small distances between letters.   Now, what to do if I have a two-letter variable name, like for instance TP or FN (true positive or false negative)? Leave as they are? Put them in `\text`? Yet in the first option they will look like T*P or F*N and in the second one they will differentiate from one-letter symbols. In optics, the 2-letter variable _NA_ is used for numerical aperture.


title: organize table with dcolumn

text: I created this table. But, the text are not center. the columns are organized on decimal marker, but the space between columns are not correct. I don't understand the dcolumn packege.                  \documentclass[12pt,twoside,a4paper,openright]{report}         \usepackage[portuguese]{babel}         \usepackage[utf8]{inputenc}         \usepackage[inner=3cm,outer=2cm,tmargin=2.0cm,bmargin=2.0cm, includefoot, includehead]{geometry}         \usepackage{mathtools}         \usepackage{booktabs, multicol, multirow}         \usepackage{tabularx}         \usepackage{dcolumn}         \usepackage{layouts}         \usepackage{makecell}         \usepackage{threeparttable}              \newcolumntype{d}[1]{D{.}{.}{#1}}         \newcolumntype{,}{D{,}{,}{-2}}         \newcommand{\mc}{\multicolumn}         \newcolumntype{R}{>{\raggedleft\arraybackslash}X}         \newcolumntype{L}{>{\raggedright\arraybackslash}X}         \newcolumntype{C}{>{\centering\arraybackslash}X}              \begin{document}              \begin{table}[htbp]           \centering           \caption{Composição quimica (wt\%) dos GCC's originais e modificados.}           \begin{threeparttable}           \begin{tabularx}{\textwidth}{l*{6}{d{-2}}}         \cmidrule[0.8pt]{1-7}           \textbf{Composição}  & \multicolumn{2}{c}{\textbf{H60}} & \multicolumn{2}{c}{\textbf{H90}} & \multicolumn{2}{c}{\textbf{H90 E}} \\           \textbf{química (wt\%)}          &  \multicolumn{1}{X}{\centering Original} & \multicolumn{1}{X}{\centering Modificado} & \multicolumn{1}{X}{\centering Original} & \multicolumn{1}{X}{\centering Modificado} & \multicolumn{1}{X}{\centering Original} & \multicolumn{1}{X}{\centering Modificado}  \\          \cmidrule{1-7}         \textbf{Carbonato} & \multirow{2}{*}{103,2 \tnote{\textdagger}} & \multirow{2}{*}{55,5} & \multirow{2}{*}{97,4} &  \multirow{2}{*}{55,9} & \multirow{2}{*}{98,5} & \multirow{2}{*}{64,3} \\         \textbf{de cálcio} &  & &  &  & &  \\         \textbf{Água} & - & 3,9 & 0,2 & 3,2 & 0,3 & 2,5 \\         \textbf{Sílica} & - & 40,6 & - & 39,6 & - & 30,6 \\         \textbf{Impurezas} & - & - & 2,4 & 1,4 & 3,9 & 2,6 \\          \cmidrule[0.8pt]{1-7}           \end{tabularx}           \begin{tablenotes}             \item[\textdagger] Erro de medição.             \end{tablenotes}             \end{threeparttable}           \label{tg_tabela}         \end{table}


title: Automatically add vertical space /only/ between two sequential paragraphs

text: I am using KOMA-script scrreprt class. I know I can use `\usepackage{parskip}` or `\setlength{\parskip}{12pt}`, but both of these also affect headings. Adding `\vspace{12pt}` manually between all two sequential paragraphs seems to work, but that's anything but convenient. Is there a way to automate it?


title: TikZ - Rounded closed polygon

text: I would like to produce rounded closed polygon like in the following uggly draw. This shape will be defined by giving positions of the vertex. This will be used on sudoku grids. ![enter image description here](http://i.stack.imgur.com/Sac8K.png)


title: TikZ/PGF: Create a saved length as part of a shape definition

text: When I create a new shape using pgfdeclareshape, I want to be able to store a length for later reference. I might want to do simple arithmetic on this length later on. Here's a basic attempt:                \pgfdeclareshape{MyShape}      {         \saveddimen\mydimen         {             \pgf@x = 10pt         }         \backgroundpath         {             \pgfpathmoveto                 {\pgfpoint{0pt}{0pt}}             \pgfpathlineto                 {\pgfpoint{2\mydimen}{0pt}}             \pgfusepath{stroke}         }      }      This is intended to produce a line 20pt long -- but it actually draws a line 210pt long, presumably because \mydimen stores the value 10pt as plan text, not as a dimension. How can I save dimensional quantities upon shape creation?


title: Lualatex, Pdflatex fail with \externalize

text: Here is my problem: I have a 100+ page document with ~100 tikz plots. Some plots contain 9000+ points, and compiling them with pdflatex -shell-escape (or whatever main_memory_size) fails. I can compile it with lualatex though, but it takes forever. I decided to use:                   \usetikzlibrary{external}         \tikzset{external/system call={lualatex \tikzexternalcheckshellescape -shell-                escape -halt-on-error -interaction=nonstopmode -jobname "\image" "\texsource"}}         \tikzexternalize[prefix=TikzFigures/]         \tikzset{external/force remake}      And it fails with                   "16684 words still in use, bla-bla ...may be you did not enable shell-escape         ...bla-bla write18...please refer to picture-17.log",       but there is no error message in that log. If I switch back to pdflatex, with proper adjustments, error log says again that I'm out of memory. I thought lualatex manages memory dynamically, and externalize should work when regular compilation fails, but I got the opposite case. I have 4-core i7 with 8Gb RAM, hardly half is used.. What to do? I use TexNic center and MikTex, so in the editor options of course I hap put the -shell-escape as well as -enable- write18 in all possible combinations for both pdflatex output profile and lualatex profile. I have a main .tex file with several included chapters, with separate tikzpistures in .tex files as well. Moreover, if I delete all the images from the TikzFigures/ folder, now both lualatex and pdflatex fail already at the first image. If I comment out lines responsible for externalization, it compiles. It takes 5 minutes and 500Mb of memory, but it compiles with one warning about scrbook\float@addtolist that it is about to get outdated.                   \documentclass[fontsize=12,BCOR=0mm]{scrbook}         \usepackage{etex}         \usepackage[USenglish]{babel}         \usepackage{url}         \usepackage{natbib}         \usepackage{breakcites}         \usepackage{enumerate}         \usepackage{caption}         \usepackage{nomencl}         \usepackage{setspace}         \usepackage{listings}         \usepackage{booktabs}         \usepackage{tikz}         \usepackage{tikzscale}         \usepackage{pgf}         \usepackage{pgfplots}         \usepackage{subfig}         \pgfplotsset{compat=1.8}         \pgfplotsset{colormap={my_hot}{[1cm]color(0cm)=(black);         color(3cm)=(red);color(4cm)=(orange);color(5cm)=(yellow);color(8cm)=(white)}}              \pgfplotsset{every axis/.append style={line width=1pt,          tick style={tick align=outside, line width=0.6pt}}}         \pgfplotsset{ticks=both}%/.append style={thin}}         \pgfplotsset{ylabel shift=-4pt}         \pgfplotsset{yticklabel style={xshift=0.1cm}}         \pgfplotsset{label style={font=\small}}         \pgfplotsset{every axis legend/.style={inner ysep=1.5pt}}         \usetikzlibrary{automata, arrows}         \usepackage{color}         \definecolor{light-gray}{gray}{0.95}         \lstset{backgroundcolor=\color{light-gray}}%, xleftmargin=\noindent}                    \usepackage{multibib}                   \usetikzlibrary{external}         \tikzset{external/system call={lualatex \tikzexternalcheckshellescape          -enable-write18 -halt-on-error -interaction=nonstopmode          -jobname "\image" "\texsource"}}         \tikzexternalize[prefix=TikzFigures/]         \tikzset{external/force remake}              \makenomenclature         \newcommand{\keywords}[1]{\par\addvspace\baselineskip         \noindent\keywordname\enspace\ignorespaces#1}         \setcapindent{0pt}          \renewcommand{\nomname}{List of Symbols}              \makeatletter          \renewenvironment{thebibliography}[1]          {\subsection*{\refname}%           \@mkboth{\MakeUppercase\refname}{\MakeUppercase\refname}           \list{\@biblabel{\@arabic\c@enumiv}}         {\settowidth\labelwidth{\@biblabel{#1}}         \leftmargin\labelwidth         \advance\leftmargin\labelsep         \@openbib@code         \usecounter{enumiv}         \let\p@enumiv\@empty         \renewcommand\theenumiv{\@arabic\c@enumiv}}           \sloppy           \clubpenalty4000           \@clubpenalty \clubpenalty           \widowpenalty4000%           \sfcode`\.\@m}          {\def\@noitemerr            {\@latex@warning{Empty `thebibliography' environment}}           \endlist}          \makeatother              \makeindex         \begin{document}         \pagenumbering{roman}         \input{title.tex}         \maketitle                   \include{abstract}              \include{acknowledgements}              \tableofcontents         \listoftables          \listoffigures               \clearpage         \pagenumbering{arabic}              \include{Abstract}         \include{Introduction}         \include{Algorithms}         \include{Modeling}         \include{Performance}         \include{Conclusions}                   \pagestyle{plain}         \cleardoublepage         \addcontentsline{toc}{chapter}{List of Symbols}              \setlength{\nomitemsep}{-0.7\parsep}              \begin{spacing}{0.4}         \printnomenclature [14mm]         \end{spacing}              \bibliography{paper-bibfile-short}                   \end{document}          ! Package tikz Error: Sorry, the system call 'lualatex --shell-escape -intera     ion=nonstopmode -jobname "TikzFigures/phd_thesis-figure17" "\def\tikzexternal     aljob{phd_thesis}\input{phd_thesis}"' did NOT result in a usable output file     ikzFigures/phd_thesis-figure17' (expected one of .pdf:.jpg:.jpeg:.png:). Plea     verify that you have enabled system calls. For pdflatex, this is 'pdflatex -     ell-escape'. Sometimes it is also named 'write 18' or something like that. Or     aybe the command simply failed? Error messages can be found in 'TikzFigures/p     _thesis-figure17.log'. If you continue now, I'll try to typeset the picture.


title: Creating a background image on the title page only using Beamer

text: I am attempting to construct a Beamer presentation and I'm experiencing some difficulty. While I can insert a background image on the title slide using a "global setting", I don't want it to appear on every subsequent slide. Every subsequent slide (including the navigation/menu slide) should have a completely blue background with text of a currently undetermined color. Any help would be appreciated.               \documentclass{beamer}     \usetheme{Antibes}     \usepackage{graphicx}     \usepackage{tikz}          % \setbeamercolor{normal text}{fg=yellow}          \setbeamercolor{frametitle}{bg={}}     \title[...]{My title}          \usebackgroundtemplate{\includegraphics[width=\paperwidth, height=\paperheight]{08171830.jpg}}     \beamertemplatenavigationsymbolsempty     \date{}          \begin{document}              \AtBeginSection[]         {             \usebackgroundtemplate{}             \begin{frame}                 \setbeamertemplate{background canvas}[default]                 \frametitle{Outline}                 \tableofcontents[currentsection]             \end{frame}         }              \begin{frame}             \titlepage              \end{frame}              \section{Introduction}              \usebackgroundtemplate{}         \begin{frame}{History}             This is a test page!         \end{frame}          \end{document}


title: Defining mdframe style by reference to another style

text: I'm wanting to define an mdframe style "studies", by reference to mdframe style "mpdframe". In the example shown, the difference would be to add a frame title, "Studies". The following code does not produce errors, but neither does it produce the desired effect.               %   Principal MPD frame type     \mdfdefinestyle{mpdframe}{         frametitlebackgroundcolor   =black!15,         frametitlerule          =true,             roundcorner     =10pt,             middlelinewidth     =1pt,             innermargin     =0.5cm,             outermargin     =0.5cm,             innerleftmargin     =0.5cm,             innerrightmargin        =0.5cm,             innertopmargin      =\topskip,             innerbottommargin   =\topskip,                 }     %   Studies     \mdfdefinestyle{studies}{%     \mdfapptodefinestyle{mpdframe}{frametitle={Studies}}         }     \newmdenv[style=studies]{studies}      Can this be done another way? Ideally, I want to define numerous styles in this way, by reference to this base style, rather than continually repeating the option commands.


title: When can one use implicit braces instead of explicit braces?

text: For context, an implicit character is a control sequence that has been `\let` to a character. For example, both plain TeX and LaTeX use `\let\bgroup{ \let\egroup}` making `\bgroup` and `\egroup` into implicit braces. In some places, TeX accepts either, in other places, it does not. For example, implicit braces cannot be used to collect tokens for undelimited macro arguments, nor can they be used to delimit the replacement text of a macro assignment. Implicit braces can be used   * to form groups: `\bgroup...\egroup`;   * to construct boxes: `\hbox`, `\vbox`, and `\vtop`;   * to create vertical material with `\insert` or `\vadjust`;   * for alignment material with `\halign`, `\valign`, and `\noalign`; and   * to create a new math atom. Implicit _left_ braces—which must be matched with literal characters with category code 2 (e.g., `}2`)—can be used   * to assign to token variables;   * with `\hyphenation` and `\patterns`;   * to change case with `\uppercase` and `\lowercase`;   * to write messages using `\message` or `\errmessage`;   * to write files using `\write`;   * to construct a `\special`;   * for `\mark`;   * for `\discretionary`; and   * for a four-way `\mathchoice`. I tried to be thorough, but TeX is extremely complicated. Are there any other places where an implicit brace can be used instead of an explicit one?


title: ‘Bundle’ TeX output in a directory

text: (My personal interest in this question is mainly for OS X but solutions/approaches for other operating systems are also appreciated.) What I see as a main distraction with using TeX/LateX is that it creates too many auxiliary files beneath the files which are interesting. Especially, when browsing the folders to look for that certain file to print, I’m only interested in the PDF file which was generated. Of course, that’s a thing which is much easier with Word and OpenOffice files; you could have hundreds of those files in a directory and just quickview them. Since it is good practice to have only a single document per folder, I wonder if there is a tool to make that folder a bundle which hides its contents from the Finder and only opens the PDF file. Or is there a TeX editor which uses this technique for its project files? How is the best approach to deal with this distraction on the file system? **Edit:**   To clarify things, I’m not so much interested in deleting the auxiliary files or putting them somewhere else. The problem is that, even with a makefile and a clean target or a special command which removes all aux files, I’ll still need to have a separate folder for each PDF target anyway. Just because thing get messier and messier when you have multiple documents per directory. It’s just that folders are distracting in their very own way. You can’t really preview the contents (e.g. the PDF) of them and actually the OS X finder does not look as if it’s designed for folders containing only folders but that’s another story. I just want to have a way that the GUI layer of the file system shows my latex document folders in the same way it shows `.app` bundles. (Or XML Word/OpenOffice files, only that these files are actively bundled in a zip container, of course, but the principle is similar.)


title: Chapter title leading

text: I have a strange problem in my Chapter title as in figure: ![enter image description here](http://i.stack.imgur.com/22gJ5.png) How can I set the correct leading between the two last lines in the title?


title: latex-dvips-ps2pdf

text: I use pdflatex, Windows7, and TeXnicCenter. I am interested in using `\psbarcode` in combination with `\usepackage{auto-pst-pdf}`. A possible solution is to use latex-dvips-ps2pdf. The question is how to activate latex- dvips-ps2pdf. I found a detailed explanation on the TeXworks site > _Windows_   >  Create a file `latex-dvips-ps2pdf.bat` containing   >  `@latex -synctex=1 "%1.tex" && dvips "%1.dvi" && ps2pdf "%1.ps"`   >  If `-synctex=1` causes problems, simply remove it.   > I do not know how and where to create this `.bat` file for `latex-dvips- ps2pdf.` Could you please clarify this to me, or give me other suggestions, screenshots, etc. on how to proceed?


title: Define a TeXStudio keyboard shortcut macro that activates only in math mode

text: I am using TexStudio 2.6.6 and what I need is to create a custom keyboard shortcut macro that will insert `_{%|}` whenever I type `_` in math code only. Or a macro that will insert `^{%|}` whenever I type `^` in math code. But these macros should not work in text mode. So that in text mode I can type `_`. So I needed to know how to tell the macro to activate only when I am writing math code.


title: Unable to copy _ from pdf

text: \documentclass{article}     \usepackage[T1,OT4]{fontenc}     \begin{document}     Text with \_.     \end{document}      In PDF there is a correct output: `Text with _.`   But when I select and copy it I get: `Text with .` It happens on Adobe Reader, Foxit Reader and on Sumatra PDF so I think it is not a reader issue. How can it be fixed?


title: Compiling a Plain-TeX file that loads harvmac on TexWorks on windows

text: I had asked this question and it was suggested that I use plain TeX. On TeXworks among the compiling options there is no such thing. When I try running the file through pdfTeX I get the message,               This is pdfTeX, Version 3.1415926-2.3-1.40.12 (MiKTeX 2.9) entering extended mode     (C:\Users(some path)\MiKTeX\2.9\tex\plain\harvmac\harvmac.tex     big or little (b/l)?      What am I supposed to do?


title: How to include online postage in a scrlttr2 letter?

text: The class `scrlttr2` is well suited for using window envelopes by default. That means that it prints the address at the standardized position. In Germany, you can buy online postage which is supposed to be printed on the envelope or on the letter into the window area next to the address. Using the window area is of course more convenient. The German Post Office ('Deutsche Post') only provides an integration for Microsoft Word (of course ;)). Thus my question: How to include online postage in a `scrlttr2` document? The online postage is available at the Deutsche Post. I used the output format 'DIN A4 Normalpapier (Einlegeblatt)' (which is only available if a recipient is entered - a single character will do). You can get a sample file there. Since the page is in german I put the resulting sample PDF-file also on a private web-server. The standardized position of the window is well explained in Wikipedia - the article is in german, but the figure contains all the information.


title: Reset counter after each item

text: How to reset the counter of equation numbering after each item in the enumerate environment?


title: Better way to produce V\llap{--}

text: Is there a better way to get the symbol produced by `V\llap{--}`? I need it in math mode. The symbol is someitmes used to represent volume. The above hack is not the right symbol but something close.


title: Reduce spacing between lines

text: I have alternating lines and texts. Example may be a sign-in sheet where there is a line on which a person sign and his name is written immediately below this line. The following code generate the desired output except the last entry. There is relatively more space between the line and the name. Is there a way to reduce that space between the last line and Dr. EEEEE.                 \vspace{1.5cm}            \line(1,0){300}\\       Dr. AAAAA\\       \vspace{1.1cm}          \line(1,0){300}\\       Dr. BBBBB\\       \vspace{1.1cm}          \line(1,0){300}\\       Dr. CCCCC  \\       \vspace{1.1cm}       \line(1,0){300}\\       Dr. DDDD \\       \vspace{1.1cm}          \line(1,0){300}\\       Dr. EEEEE      Thanks


title: Auto-completing lists

text: Please, if at all possible, can anyone help with a generic, grand scheme for completing general lists, such as seen below. pgf's `\foreach` can handle some of them, but I have a need for auto-completion outside of `\foreach`. Must one define a completion scheme for each list type, as I am doing now?               \def\lista{1,...,10,13,...,21}     \def\lista{1,2,...,10,13,15,...,21}     \def\lista{1pt,2pt,...,10pt,13pt,15pt,...,21pt}     \def\lista{1ex,2ex,...,10ex,13ex,15ex,...,21ex}     \def\lista{a,b,1,...,10,13,...,21}     \def\lista{a,b,1,2,...,10,13,...,21}     \def\lista{1,2,a,b,1,...,10,13,...,21}     \def\lista{A,...,S,a,...,s}     \def\lista{A,B,...,S,a,b,...,s}     \def\lista{A,B,1,...,10,a,b,...,f}     \def\lista{a,A,1,...,10,13,...,21}     \def\lista{2^1,2^2,2^3,...,2^10,a^1,a^2,...,a^9}     \def\lista{1_2,2_2,...,5_2,a_2,b_2,...,h_2}     \def\lista{c_2,d_2,...,e_2}     \def\lista{1\pi,...,3\pi}     \def\lista{0\pi,0.5\pi,...,3\pi}     \def\lista{1^\pi,1.5^\pi,...,5.5^\pi}      Completion-wise, a folded list such as               \def\lista{1,...,10,13,...,21}      is basically the same as               {1,...,10}     {13,...,21}


title: TikZ Intersection missing the true intersection slightly

text: I'm having issues with the intersection feature. It works, but it seems to "miss" the true intersection a bit. The code below produces the error for me. See this image (can't post it directly because <10 rep points): ![http://i.imgur.com/WfRBQ.jpg](http://i.stack.imgur.com/DpAWb.jpg) Notice how the point E2 is slightly below and to the right of the true intersection. Is this just a calculation error? Or am I doing something wrong? Cheers, Trevor               \usepackage{tikz}     \usetikzlibrary{arrows,shapes,trees,calc}     \usetikzlibrary{intersections}     \usepackage{relsize}          \begin{tikzpicture}[         scale=2.2,         dot/.style={circle, fill=black, minimum size=4pt, inner sep=0pt},]     \newcommand\Sshift{0.8cm}          \coordinate (D_1L) at (0.2,1.8); % DL begin     \coordinate (D_2L) at (2.3,0.2); % DL end     \coordinate (S_1L) at (0.2,0.2); % SL begin     \coordinate (S_2L) at (1.8,1.8); % SL end     \coordinate (S_21L) at ([xshift=\Sshift] S_1L);     \coordinate (S_22L) at ([xshift=\Sshift] S_2L);          \draw[axis,<->] (2.8,0) node(Sxaxis)[right] {$Q_{sec}$}           -| (0,2) node(Syaxis)[above] {$P_{sec}$};          \draw[line, thick] (S_1L) -- (S_2L) node[right] {$S_1$};     \draw[line] (D_1L) -- (D_2L) node[right] {$D$};     \draw[line, thick] (S_21L) -- (S_22L) node[right] (S_22L) {$S_2$};          % intersections     \coordinate (E1L) at (intersection of S_1L--S_2L and D_1L--D_2L);      \draw[dashed] (Syaxis |- E1L) node[left]{$P_1$}      -| (Sxaxis -|E1L) node[below]{$Q_1$};      \node[dot, label=above:{$E_1$}] (E1) at (E1L) {};     \coordinate (E2L) at (intersection of S_21L--S_22L and D_1L--D_2L);      \draw[dashed] (Syaxis |- E2L) node[left]{$P_2$}      -| (Sxaxis -|E2L) node[below]{$Q_2$};      \node[dot, label=right:{$E_2$}] (E2) at (E2L) {};          \end{tikzpicture}


title: On the second page of my PDF, the margin gets larger

text: I'm not quite into this Latex yet, and I have a bit of a problem.. My preamble looks like this:               \documentclass[a4paper,article]{memoir}     \usepackage[utf8]{inputenc} \usepackage[danish]{babel} \usepackage[T1]{fontenc}     \usepackage{amsmath,amssymb} \usepackage{bm} \usepackage{amsthm} \usepackage{mathtools}     \usepackage{listings}     \usepackage{siunitx}     \usepackage{graphicx}      Every time I get to the second page, the left margin on the PDF increases. When I've managed to write enough to fill 3 pages, the margin on the third page moves back to normal. So I only have this problem on the second page. Can anybody help?


title: How to numbering subs in a definition nicely?

text: The code what I've got:               \documentclass[a4paper]{article}     \usepackage{amsthm}          \begin{document}          \textbf{Definition 1.1} The definition contains following contents:     \begin{enumerate}       \item The first item       \item The second item       \item This item may long enough to take up more than a line like this sentence. Line Breaking \ldots     \end{enumerate}          \end{document}      Result of this code: ![enter image description here](http://i.stack.imgur.com/Unglx.png) The result what I want: ![enter image description here](http://i.stack.imgur.com/dPkeM.png) The things have to be changed: space between lines, item format.


title: How to remove part and section numbers from titles

text: Using XeLaTeX and Book package. I'd like to remove "part #" and "section #" from the \part and \section titles, thus keeping the part and section titles only. How can I accomplish this? Thanks in advance for any help.


title: Draw two circles with line connecting them as in attachment

text: Would you please help me in drawing two circles with a line (middle arrow) connecting them. O-->--O Sorry I could not post the image. _**_**_Edit_ ***** Thank you so much. Can you help me more? Here is my code. I need to draw that mid-arrowed line between the dot-filled circles. Thank you               \begin{tikzpicture}     \draw [dotted] (0,1) -- (0,10);     \draw [dotted] (1.5,1.3) -- (1.5,10);     \draw [dotted] (3.0,1.3) -- (3.0,10);     \draw [dotted] (4.5,1.3) -- (4.5,10);     \draw [dotted] (6.0,1.3) -- (6.0,10);     \draw [dotted] (7.5,1.3) -- (7.5,10);          % Lower Row     \filldraw[pattern=dots] (7.5,1) circle (0.2) ;     \filldraw[pattern=dots] (6.0,1) circle (0.2);     \filldraw[pattern=dots] (4.5,1) circle (0.2);     \draw (3.0,1) circle (0.2);     \end{tikzpicture}


title: elsarticle.cls not found when using TexMaker, but texlive-latex-extra is installed

text: I am trying to get my TeX document to build. I know this works because I've done it on another system, but I recently put Lubuntu on my linux partition, so everything is new again. I've installed TexMaker as well as texlive and texlive-latex-extra and a few other related latex packages. elsarticle.cls is supposed to be part of texlive-latex-extra but when I quick build my document I still get               ! LaTeX Error: File `elsarticle.cls' not found.      Is there something I have to do to tell TexMaker that I've installed extra packages, and that it can look for elsarticle.cls in texlive-latex-extra? How do I fix this? Additional info: here are screenshots of my TexMaker settings. Please let me know if I should include anything else.


title: PGF stacked bar graph not drawn correctly

text: I am having problem with the following code which is supposed to produce a simple stacked graph.               \documentclass[tikz,border=2pt]{standalone}          \usepackage{pgfplots}     \usepackage{tikz}          \begin{document}     \begin{tikzpicture}     \begin{axis}[ybar stacked]     \addplot[fill=black]    coordinates {(0.00,0.10)};     \addplot[fill=black!66] coordinates {(0.00,0.20)};     \addplot[fill=black!33] coordinates {(0.00,0.30)};     \addplot[fill=white]    coordinates {(0.00,0.40)};     \end{axis}     \end{tikzpicture}           \end{document}      Below is the output it generates which is not clearly well-aligned. If I explicitly specify `ymin = -0.1`, `ymax = 1.1`, the bar looks almost right, but it starts slightly below `(0,0)`. If I replace coordinates `(0.00,0.10)` with `(0.00,0.00)`, the bar looks just fine. I have absolutely no idea what the problem could be. ![enter image description here](http://i.stack.imgur.com/iupNI.jpg)


title: Tikz footer and page numbering issues

text: I put a footer on all my pages using:               \newcommand\Footer{     \begin{tikzpicture}[remember picture, overlay]     \node[anchor=south, inner sep=0pt, outer sep=0pt] (footer)      at (current page.south) {\includegraphics[width=\paperwidth]{footer.png}};     \draw [fill=nicedarkblue, draw=none] (footer.north west) rectangle      ($(footer.north east)+(0,0.1cm)$);     \node[anchor=east, inner sep=0pt, outer sep=0pt] (footerpage)      at ($(footer.east)-(1cm,0)$) {\textcolor{white}{{\sffamily\bfseries\thepage}}};     \end{tikzpicture}     }          \pagestyle{plain}     \AtBeginShipoutFirst{\Footer}     \AtBeginShipout{\Footer}      But it fails for 3 aspects:   * the page number appears two times (the "normal" one and the footer one)   * the numbering in the footer is wrong: I got 1, 1, 2, 3, 4 (instead of 1, 2, 3, 4)   * I got an extra empty page at the end for no reason How to solve these problems? EDIT: here is the whole document               \documentclass[12pt,a4paper]{report}     \usepackage[utf8]{inputenc}     \usepackage[T1]{fontenc}     \usepackage[french]{babel}     \usepackage[margin=10pt,font=footnotesize,labelfont=bf]{caption}     \usepackage{lipsum}     \usepackage{soul}     \usepackage{ulem}     \usepackage{fancyhdr}     \usepackage{fancybox}     \usepackage{amsmath}     \usepackage{amssymb}     \usepackage{mathrsfs}     \usepackage{array}     \usepackage{makeidx}     \usepackage{graphicx}     \usepackage{icomma}     \usepackage{floatrow}     \usepackage{subfigure}     \usepackage{enumerate}     \usepackage{appendix}     \usepackage{pdfpages}     \usepackage{multicol}     \usepackage{sistyle}     \usepackage{wasysym}     \usepackage{textcomp}     \usepackage{cellspace}     \usepackage{color}     \usepackage{xcolor}     \usepackage{cancel}     \usepackage[explicit]{titlesec}     \usepackage{titletoc}     \usepackage{tikzpagenodes}      \usepackage{lmodern}     \usepackage{epigraph}     \usepackage{xpatch}     \usepackage{calc}     \usetikzlibrary{calc}      \definecolor{nicedarkblue}{RGB}{0, 0, 102}     \definecolor{otherdarkblue}{RGB}{0, 32, 96}     \def\headergraphics{\includegraphics[width=\paperwidth]{header.png}}     \newlength\headerheight     \setlength\headerheight{\heightof{\headergraphics}}     \newlength\headerleftshift     \setlength\headerleftshift{2cm}     \newcommand\Header{     \begin{tikzpicture}[remember picture, overlay]     \node[anchor=north, inner sep=0pt, outer sep=0pt] (header) at (current page.north) {\headergraphics};     \node[anchor=north west, inner sep=0pt, outer sep=0pt] (headerleft) at ($(current page.north west)+(\headerleftshift,0cm)$) {\includegraphics[height=\headerheight]{headerleft.png}};     \draw [fill=white, draw=none] (header.north west) rectangle ($(header.south west)+(\headerleftshift,0cm)$);     \draw [fill=nicedarkblue, draw=none] (header.south west) rectangle ($(header.south east)-(0cm,0.1cm)$);     \end{tikzpicture}     }     \newcommand\Footer{     \begin{tikzpicture}[remember picture, overlay]     \node[anchor=south, inner sep=0pt, outer sep=0pt] (footer) at (current page.south) {\includegraphics[width=\paperwidth]{footer.png}};     \draw [fill=nicedarkblue, draw=none] (footer.north west) rectangle ($(footer.north east)+(0cm,0.1cm)$);     \node[anchor=east, inner sep=0pt, outer sep=0pt] (footerpage) at ($(footer.east)-(1cm,0cm)$) {\textcolor{white}{{\sffamily\bfseries\thepage}}};     \end{tikzpicture}     }          \pagestyle{empty}     \AtBeginShipoutFirst{\Header\Footer}     \AtBeginShipout{\Header\Footer}          \usepackage[top=1in, bottom=1in, left=1in, right=1in]{geometry}     \usepackage{hyperref}     \renewcommand{\headrulewidth}{0pt}     \renewcommand{\footrulewidth}{0pt}     \captionsetup{figurewithin=none}       \captionsetup{tablewithin=none}     \renewcommand{\subfigbottomskip}{-10pt}     \let\oldcite\cite     \renewcommand\cite[1]{\textsuperscript{\oldcite{#1}}}     \hypersetup{         colorlinks,%         citecolor=blue,%         filecolor=blue,%         linkcolor=blue,%         urlcolor=blue     }          \makeatletter     \long\def\@makefntextFB#1{%         \ifx\thefootnote\ftnISsymbol             \@makefntextORI{#1}%         \else             \rule\z@\footnotesep             \setbox\@tempboxa\hbox{\@thefnmark}%                 \ifdim\wd\@tempboxa>\z@                     \kern2em\llap{\@thefnmark.\kern0.5em}%                 \fi             \hangindent2em\hangafter\@ne#1         \fi}     \makeatother          \newcommand*\eqbox[1]{     \definecolor{shadowcolor}{RGB}{0, 0, 102}\setlength\shadowsize{2pt}\shadowbox*{#1}     }          \begin{document}     \chapter*{First chapter}     Test          \chapter{Second chapter}     Test          \end{document}      and the problem remains with `\pagestyle{empty}`


title: epstopdf creating blank .pdf file -eps-converted-to.pdf file

text: I am a newbie trying to use the most recent pdfLaTeX. Whenever I try to add an eps file to my document epstopdf just creates a blank .pdf file and I just see blank space where there should be my image. Here's my code:               \documentclass{revtex4-1}     \usepackage{graphicx}     \begin{document}     \begin{figure}[h!]     \centering     \includegraphics[scale=0.1]{prototype}     \caption{\label{fig:prototype}test}     \end{figure}     \end{document}      Thanks


title: show acronym in bold

text: I'm using the `acronym` package. The first time I use the acronym the full name will be written. What I would like is to have the acronym in bold while the full name is NOT in bold is that possible? Ex: I need: Kalman Filter ( **KF** ) but `\textbf{\ac{KF}}` gives: **Kalman Filter (KF)**


title: Subequations and align environment

text: I am trying to use `subequations` with a complicated alignment. The alignment in the MWE is not satisfactory. I am seeking for a solution where I can specify `lrc` such as in `array`, but `subequations` doesn't work with `array` like `equation` does. Is there a way to get the features from both sides: subequations numbering and referencing; and flexible alignment?               \documentclass{article}     \usepackage{mathtools}     \usepackage{array}          \begin{document}     \noindent     \begin{subequations}     \begin{align}     I+J & \to & K & + & L & A \\         & \to & M & + & N & B \\         & \to & O & + & P & CA     \end{align}     \end{subequations}     \begin{equation}     \begin{array}{lllllc}     I+J & \to & K & + & L & A \\         & \to & M & + & N & B \\         & \to & O & + & P & CA     \end{array}     \end{equation}     \end{document}


title: Table using array

text: I'm creating Latex Tables using Array One of the sample table is mentioned below with merging multi-cell of rows. ![enter image description here](http://i.stack.imgur.com/RtdFr.png) Can you please help me to understand, how can i merges rows in arrays Sample Latex table with Array is mentioned below;               \[\begin{array}{*{20}{|c}}     \hline        {{\text{Differentiation}}} & {{\text{Integration}}} & {}  \\        {{\text{The problem of finding SLOPE}}} & {} & {}  \\        {} & {{\text{Leibnitz}}} & {{\text{Archimedes}}}  \\        a & b & c  \\        d & e & f  \\        g & h & i  \\        j & k & l  \\        m & n & o  \\     \hline     \end{array} \]


title: Adding code at the end of each list item

text: My question is actually a generalization of this scenario: I'm using the `xhfill` package to fill the last line corresponding to each item in a given list (set through the `enumitem` package) with a horizontal filling rule (terrible typesetting, but it's required for some legal documents). I wonder if there is a way to automate adding the rule command after the text for each list item instead of having to add it manually. My point is actually if there is a way to do this so that any command or macro may be added at that point.


title: pgfplotstable: How to access column name?

text: I have used `\pgfplotstableset` to assign column names in the preamble. However, I don't know how to access them.               \documentclass{article}     \usepackage{amsmath}     \usepackage{pgfplots, pgfplotstable, filecontents}     \pgfplotsset{compat=1.6}          \begin{filecontents}{test.dat}       Time Distance        0 0         1 1         3 2      \end{filecontents}          \pgfplotstableset{        columns/Time/.style={          column name={$t_{\alpha}$},        },        columns/Distance/.style={           column name={$D_{\alpha}$},        },     }          \begin{document}       \pgfplotstableread{test.dat}\loadedtable            \pgfplotstabletypeset{\loadedtable}            \pgfplotstableforeachcolumn\loadedtable\as\col{%          column name is ‘\col’; index is \pgfplotstablecol;\par       }     \end{document}      The column names are modified correctly in the table but when I try to access them using `\col` I don't get the modified names. What is the key for column names? As `pgfplots` does not support mathmode expressions in the column names, I am planning to use `\pgfplotstableset` in the preamble to create a document wide list of column names and then use it for legends in the figures throughout the document. **Edit:** I also tried               \foreach \y in {0,1}{       \pgfplotstablegetcolumnnamebyindex{\y}\of{\loadedtable}\to{\colname}       \colname     }      to get the column names. But with the same result. Also, `\pgfplotstablegetcolumnnamebyindex` is not mentioned in the manual for `pgfplotstable` v1.6. I got it from another post here. **Edit2:** Further exploration of the issue. Consider the following code and the output of the latex file.               \documentclass{article}     \usepackage{amsmath}     \usepackage{tikz,pgfplots,pgfplotstable,filecontents}     \pgfplotsset{compat=1.6}     \begin{filecontents}{test1.dat}       Time Distance       1 1     \end{filecontents}          \begin{filecontents}{test2.dat}       Time Velocity       2 3     \end{filecontents}          \begin{document}     \pgfplotstableread{test1.dat}\tableone \pgfplotstableread{test2.dat}\tabletwo          \noindent \pgfplotstabletypeset{\tableone}\\     \pgfplotstabletypeset{\tabletwo}\newline\line(1,0){80}          \pgfplotstableset{        columns/Time/.style={          column name={$t_{\alpha}$},        }     }              \noindent \pgfplotstabletypeset{\tableone}\\     \pgfplotstabletypeset{\tabletwo}\newline\line(1,0){80}          \pgfkeyssetvalue{/pgfplots/table/column name}{$t_{\beta}$}          \noindent \pgfplotstabletypeset{\tableone}\\     \pgfplotstabletypeset{\tabletwo}\newline\line(1,0){80}          \pgfkeysvalueof{/pgfplots/table/column name}     \end{document}      Output is: ![enter image description here](http://i.stack.imgur.com/N9qKG.png) So here I show that `\pgfplotstableset` is indeed useful. Once an association has been made between a column header (as read from the input file) and the column name that one wants displayed it will be useful across multiple tables. As pointed out by @percusse and as mentioned in the `\pgfplotstable` manual, this function cannot be used as the scope of the definition is limited to `\pgfplotstabletypeset`. I hope to use `\pgfkeys` instead. After going through `pgfplotstable.code.tex` to see the implementation of `column name` key, I tried to (unsuccessfully) use `\pgfkeys`. I am new to the `\pgfkeys` and hence I was not able to figure out how to access individual column names. Waiting for new ideas.


title: Bibtex problem: It doesn't always work

text: My BibTeX just does not work after a certain citation. After this citation, every one is a question mark.               @book{digital,      author = {J.G.Proakis},      title = {Digital Transmission},      year = {2001},      publisher = {McGraw-Hill},     }      And LaTeX also gives error messages.               *Command \c@lofdepth already defined.      You requested the `dvips' driver but I think that(crop) the `pdftex' driver works better in the current(crop) context. You can force me to respect your decision(crop) by adding an exclamation point as in [dvips!].      Font shape `T1/cmss/m/n' in size <40> not available(Font) size <35.83> substituted on input line 52. Font shape `T1/cmss/m/n' in size <40> not available(Font) size <35.83> substituted      Citation `niklas' on page 9 undefined on input line 310. Citation `niklas' on page 9 undefined      There were undefined citations.      Size substitutions with differences(Font) up to 4.17pt have occurred.*      I am going crazy with those errors. When BibTeX does work, LaTeX compiles without those errors. here is my code               \documentclass[11pt,twoside]{eitExjobb}     \usepackage[T1]{fontenc}     \usepackage{color}     \usepackage{graphpap}     \usepackage{subfigure}     \unitlength=1mm     \begin{document}     %%% Title page     \Title{A Test of \texttt{Exjobb.cls}}     \Author{Stefan Höst\\\texttt{stefan}}     \Date{\today}     \Advisor{Stefan Höst}     %%\Company{Company\\Address}     \MakeTitlePage     %%%%% Page numbering for front pages     \frontmatter     %%%%% Abstract     \chapter*{Abstract}               %% ToC     \tableofcontents     %\cleardoublepage     \listoffigures     \listoftables     \cleardoublepage     %%%%% Page numbering for the main thesis     \mainmatter     %%%%%          \chapter*{Introduction}          \cite{9999}     \cite{niklas}     \cite{Boyd:2004:CO:993483}     %%%%%%%%%%%%%%%%%%%                    \bibliographystyle{unsrt}     \bibliography{reference}          \end{document}      In the code I cite three references. Only last one works. My reference.bib is.               @ARTICLE{372015,     author={Zou, W.Y. and Yiyan Wu},      journal={Broadcasting, IEEE Transactions on}, title={COFDM: an overview},      year={1995},      month={mar},      volume={41},      number={1},      pages={1 -8},      keywords={8-VSB;ACATS;ATV channel model;Advisory Committee on Advanced Television Service;COFDM;Europe;FCC;OFDM;QAM;USA;channel coding;coded OFDM;development;digital audio broadcasting;digital modulation;digital television broadcasting;history;imperfect channel conditions;orthogonal frequency division multiplexing;performance;research;terrestrial HDTV broadcasting;channel coding;digital television;encoding;frequency division multiplexing;high definition television;quadrature amplitude modulation;reviews;television broadcasting;},      doi={10.1109/11.372015},      ISSN={0018-9316},}          @ARTICLE{54342,      author={Bingham, J.A.C.},      journal={Communications Magazine, IEEE}, title={Multicarrier modulation for data transmission: an idea whose time has come},      year={1990},      month={may },      volume={28},      number={5},      pages={5 -14},      keywords={channel impairments;coding;data transmission;duplex operation;frequency division multiplexing;general switched telephone network;multicarrier modulation;undistorted channel;data communication systems;encoding;frequency division multiplexing;modulation;},      doi={10.1109/35.54342},      ISSN={0163-6804},}          @ARTICLE{713060,      author={Merchan, S. and Armada, A.G. and Garcia, J.L.},      journal={Broadcasting, IEEE Transactions on}, title={OFDM performance in amplifier nonlinearity},      year={1998},      month={mar},      volume={44},      number={1},      pages={106 -114},      keywords={16QAM;ACTS project;BER degradation;Europe;OFDM performance;OFDM signals;QPSK;RACE project;Signal Processing Worksystem simulator;additive Gaussian noise;amplifier nonlinearity;amplitude clipping;amplitude limiting;bandwidth;bit error rate;digital TV broadcasting;impulsive noise;multipath effects;nonlinear distortion;optimized output power back off;orthogonal frequency division multiplexing;power amplifier efficiency;Gaussian noise;coding errors;digital television;error statistics;frequency division multiplexing;multipath channels;quadrature amplitude modulation;quadrature phase shift keying;radiofrequency amplifiers;television broadcasting;},      doi={10.1109/11.713060},      ISSN={0018-9316},}


title: Customized numbering of figures/schemes

text: I am currently writing my thesis in the field of chemistry. In my experimental part I present some schemes and I would like to know if and how it is possible to customize the numbering of these schemes. To be more specific: I'd like to number these schemes as 'Scheme E.x', with x the number of the scheme (starting at 1; so Scheme E.1, Scheme E.2, Scheme E.3, ...). This customized numbering should only start from the experimental part, so schemes in the previous parts of the LaTeX document schould be numbered in a normal way. This is how my rudimental document looks like:                   \documentclass[a4paper]{report}              \usepackage{a4wide}                                  \usepackage[pdftex]{graphicx}                            \usepackage[small,bf,hang]{caption}              \usepackage[latin1]{inputenc}                                    \usepackage{fancyhdr}                            \usepackage{titlesec}                            \usepackage{subfig}                              \usepackage[superscript,biblabel]{cite}          \usepackage{chngcntr}                            \usepackage[nottoc,notlot,notlof]{tocbibind}             \usepackage{fixltx2e}                            \usepackage{wrapfig}                             \usepackage{arevtext,arevmath}                   \usepackage{enumitem}                            \usepackage[Gray,squaren,thinqspace,thinspace]{SIunits}               \usepackage[version=3]{mhchem}                       \usepackage{chemscheme}         \usepackage{epstopdf}                            \usepackage[varioref=true,journal=jcp]{chemstyle}           \usepackage{float}              \setlength{\parindent}{0cm}                      \renewcommand{\baselinestretch}{1.3}             \pagenumbering{arabic}                           \fancyhead[L]{\nouppercase{\leftmark}}         \fancyhead[R]{\thepage}              \usepackage[scaled=.95]{helvet}                  \usepackage{sectsty}         \allsectionsfont{\sffamily}         \renewcommand{\familydefault}{\sfdefault}                 \usepackage{titlesec}         \titleformat{\chapter}[display]           {\sffamily\huge\raggedleft}               {\MakeUppercase{\chaptertitlename}             \rlap{ \resizebox{!}{1.4cm}{\thechapter} \rule{5cm}{1.45cm}}}            {10pt}{\Huge}  % Chaptertitelgrootte         \titlespacing*{\chapter}{0pt}{2pt}{90pt}              \captionsetup{         margin=1ex,         font={small, sf},         labelfont={bf, sf},         labelsep= endash}              \makeatletter          \def\@seccntformat#1{\llap{\csname the#1\endcsname\quad}}         \makeatother              \setcounter{secnumdepth}{3}         \setcounter{tocdepth}{3}         \newcommand{\Schemeref}[1]{\textbf{Scheme\,\ref{scheme:#1}}}              \title{This is the title}         \author{Machaeri}         \date{}         \pagenumbering{arabic}          \begin{document}          \maketitle     \tableofcontents     \listoffigures     \setlength{\parindent}{0pt}          \chapter{Chapter one}          Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.              \begin{scheme}             \includegraphics[scale=1]{Test.eps}             \caption{Caption text}             \label{Test}         \end{scheme}          Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.          \end{document}


title: texshop cannot find xelatex or LuaLatex

text: I recently reinstalled MacTex on my mac (OS 10.8.4). The distribution of TexShop is new, version 3.26. For some reason, xelatex and lualatex have disappeared from the pull down menu of tex options. I've tried putting these lines at the top of the files: % !TEX TS-program = xetex or % !TEX TS-program = xelatex but my papers still won't tex. I've checked the path, there is a copy of xetex (xelatex) in that location. The paper will tex on a different machine which mysteriously has xelatex in the pull down menu. Can anybody help me to turn on that option?


title: Footnotes next to each other in a sideways table?

text: How can I put footnotes next to each other in a sideways table? The `para` option for `footmisc` does not work here. Minimum working example:               \documentclass[11pt]{article}          \usepackage{rotating} % to rotate e.g. table     \usepackage[multiple,para]{footmisc} % separate footnotes by a comma          \usepackage{tablefootnote} % footnotes in tables          \begin{document}          \begin{sidewaystable}               \centering         \begin{tabular}[h]{| l |l  |l| }              \hline             1 & 2 & 3 \tablefootnote{Remark 1} \\             \hline             7 & 8 & 9 \tablefootnote{Remark 2} \\             \hline         \end{tabular}               \caption{Caption}          \label{tab:natural}          \end{sidewaystable}      \end{document}


title: How to bold the chapter number

text: I have removed the "Chapter" text. Now I want to make the number of chapter bold. How can I do this               \titleformat{\chapter}{\rmfamily\huge}{\thechapter.}{25pt}{\huge\textbf}      ![enter image description here](http://i.stack.imgur.com/xu565.png)


title: Indentation of list in a theorem environment

text: Typically, the body in a theorem environment begins on the same line as the heading. If the text begins with a list, the first line looks a little funny due to the indentation before the label. I'm feeling too lazy to figure out how to put in an image myself. I'm talking about the effect in Theorem 1.2 here; compare to Theorem 1.1 at the same link. I _don't_ want to address this issue by making the text start on the next line (as in the linked question). Instead, I'd like for the first item not to be indented, i.e., the label of the first item should appear in the same position that the first letter would appear if the body began with text. I'm using `amsthm` and `enumitem`, if it matters.


title: Removing one blank page between two chapters

text: How can I remove one of the blank page between two chapters.                    \documentclass[12pt,titlepage,a4paper]{book}               \input{chapter1}          \newcommand*\NewPage{\clearpage\thispagestyle{empty}\null}           \NewPage          \input{chapter2}


title: Multicols Supertabular and fancy columns

text: I have quite a lot of data I "want" to print regularly, and the best option seems to be a prepared LaTeX template, where I just `\input{data}`, and `data.tex` is the result of minor sed and awk voodoo. I read a lot about varying tabular environments and how they behave in multicols environments. I have had an issue which I can attribute to my fancy column definitions. I specify four columns like this (see bottom for the entire document)               >{\begin{lrbox}{\trickbox}}l<{\end{lrbox}\raisebox{-4pt}[12pt][12pt]{\unhcopy\trickbox}}      This apparently results in supertabular being unable to correctly determine when it hits the bottom of the page. Completely guessing, I'd say supertabular does its calculations before `<{}` takes effect and therefore never sees the additional height used for the raisebox. I'd like to know: how can I make supertabular correctly calculate when it reaches the end of the page? This is the whole desaster:               \documentclass[10pt,paper=a3]{scrreprt}     \usepackage{supertabular}     \usepackage{color}     \usepackage{colortbl}     \usepackage{multicol}     \usepackage[latin1]{inputenc}          \newcommand{\alternaterow}{\rowcolor[rgb]{0.8,0.8,0.8}}     \newsavebox{\trickbox}          \makeatletter     \let\mcnewpage=\newpage     \newcommand{\TrickSupertabularIntoMulticols}{%       \renewcommand\newpage{%         \if@firstcolumn           \hrule width\linewidth height0pt           \columnbreak         \else           \mcnewpage         \fi       }%     }     \makeatother                    \begin{document}     \sffamily               \tablefirsthead{             \cline{2-5}     \multicolumn{1}{c|}{~} & \textbf{sampleid}&\textbf{in}&\textbf{a}&\textbf{out} \\ \cline{2-5} }          \tablehead{             \cline{2-5}     \multicolumn{1}{c|}{~} & \textbf{sampleid}&\textbf{in}&\textbf{a}&\textbf{out} \\ \cline{2-5}      }          \tabletail{}     \tablelasttail{}               \begin{multicols*}{4}     \TrickSupertabularIntoMulticols          \begin{supertabular}{|c     |>{\begin{lrbox}{\trickbox}}l<{\end{lrbox}\raisebox{-4pt}[12pt][12pt]{\unhcopy\trickbox}}     |>{\begin{lrbox}{\trickbox}}l<{\end{lrbox}\raisebox{-4pt}[12pt][12pt]{\unhcopy\trickbox}}     |>{\begin{lrbox}{\trickbox}}l<{\end{lrbox}\raisebox{-4pt}[12pt][12pt]{\unhcopy\trickbox}}     |>{\begin{lrbox}{\trickbox}}l<{\end{lrbox}\raisebox{-4pt}[12pt][12pt]{\unhcopy\trickbox}}     |}             \input{data}     \end{supertabular}     \end{multicols*}     \end{document}


title: Creating a BibTex Bibliography, TexMaker doesn't find the bibliography file

text: I'm working with LaTeX for a short time, and I am currently trying to write my thesis with it, but unfortunately something just doesn't work. When I compile my files there is no Bibliography output generated. I am using JabRef as a help for organizing my bibliography stuff. But when I compile my files theres always the following mistake: Citation 'LemmerichGeschichteOzon' on page 2 undefined. So obviuosly something must be wrong, because Texmaker can't finf my bibtex file or what is wrong? Why doesn't it work? //Sorry for my English, It isn't my mother tongue. So this is How my file looks like:               \documentclass[11pt,a4paper]{article}     \usepackage[utf8]{inputenc}          \usepackage[T1]{fontenc}          \usepackage[german]{babel}     \usepackage{amsmath}     \usepackage{amsfonts}     \usepackage{amssymb}     \usepackage{makeidx}     \usepackage{graphicx}     \usepackage{lmodern}     \usepackage{url}          \usepackage[     style=authoryear-icomp     ]{biblatex}     \setlength{\bibitemsep}{1em}     % Abstand zwischen den Literaturangaben     \setlength{\bibhang}{2em}        % Einzug nach jeweils erster Zeile          **\bibliography{Maturaarbeit1_Easy_Version}**  % Bibtex-Datei wird schon in der Preambel eingebunden               %\usepackage{kpfonts}     \usepackage{fourier}     \author{NAME}     \begin{document}         \pagestyle{empty}          \subsection{Geschichte von Ozon}         \subsubsection{Entdeckung durch Schönbein}     ... etwa in einem Universitätslaboratorium machte, sondern mit einfachen Mitteln in seinem Wohnhaus \cite{LemmerichGeschichteOzon}.\\     Im Jahr 1800 entdeckte Alessandro Volta die Voltasche Säule, die erste elektrolytische Batterie...          %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     \begin{appendix}     \section{Daten}     \end{appendix}          %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     \newpage     \listoffigures          **\nocite{*}**           **\bibliographystyle{alpha}**          **\printbibliography**          \end{document}


title: How to force part of a paragraph title to correctly align with right marging (using e.g. \hfill)

text: I would like to have a `\paragraph{A paragraph title 2000}` with the term '2000' aligned to the right margin. If I use `\subsubsection{A subsubsection title \hfill 2000}`the term `2000`is correctly aligned to the right margin. Using the same reasoning for the paragraph (i.e. `\paragraph{A paragraph title \hfill 2000}`) will push the term 2000 to the right margin but the alignment is not perfect. There is some space left between `2000`and the margin. It may be relevant to add that I want the subsequent text to start on the next line. Hence the entire command looks like this:               \paragraph{A paragraph title \hfill 2000}  \mbox{}\\     \noindent     Here comes the text....      How can I force a right alignment? (I am using TexLive) The following code may illustrate the problem:               \documentclass[11pt,a4paper]{article}     \begin{document}          \subsubsection{My title \hfill 2000}     Here is my text\dots          \paragraph{My title \hfill 2000} \mbox{} \\     Here goes some other text.          \end{document}      Here is the result: ![enter image description here](http://i.stack.imgur.com/hwkUr.jpg)


title: Problem when imitating one-sided printing with double-sided printing in Memoir Class

text: I use `memoir` class and I imitate one-sided printing with double-sided printing thanks to the command (find in the `memoir` manual)               \setlength{\evensidemargin}{\oddsidemargin}      The problem is that I have modified the header width with the command `\makerunningwidth` (see the minimal example below). On odd-numbered pages, the header ends in the fore-edge margin but I want it begins in the spine margin. To understand my problem it is easier to compile this code with PDFLaTeX.               \documentclass[a5paper]{memoir}     \usepackage{xcolor, calc}          % Laying out the page     \newlength{\myuppermargin}     \setlength{\myuppermargin}{20mm}     \newlength{\mylowermargin}     \setlength{\mylowermargin}{30mm}     \newlength{\myspinemargin}     \setlength{\myspinemargin}{30mm}     \newlength{\myedgemargin}     \setlength{\myedgemargin}{15mm}     \newlength{\myheadheight}     \setlength{\myheadheight}{7mm}     \newlength{\myfootskip}     \setlength{\myfootskip}{10.5mm}     \newlength{\myheadsep}     \setlength{\myheadsep}{5mm}     \newlength{\mymarginparsep}     \setlength{\mymarginparsep}{3mm}     \newlength{\mymarginparwidth}     \setlength{\mymarginparwidth}{12mm}     \newlength{\mymarginparpush}     \setlength{\mymarginparpush}{10mm}     \setlrmarginsandblock{\myspinemargin}{\myedgemargin}{*}     \setulmarginsandblock{\myuppermargin}{\mylowermargin}{*}     \setmarginnotes{\mymarginparsep}{\mymarginparwidth}{\mymarginparpush}     \setheadfoot{\myheadheight}{\myfootskip}     \setheaderspaces{*}{\myheadsep}{*}     \checkandfixthelayout{}     % Imitate one-sided printing but the page style can be customized     \setlength{\evensidemargin}{\oddsidemargin}          % Page style     \newcommand*{\evenheadfont}{\sffamily\mdseries\itshape\normalsize\color{blue}}     \newcommand*{\pagenumfont}{\normalfont\mdseries\itshape\small}     \newcommand*{\oddheadfont}{\evenheadfont}     \setlength{\headwidth}{\textwidth + \marginparsep + \marginparwidth}     \makepagestyle{custom}     \makerunningwidth{custom}{\headwidth}     \makeheadrule{custom}{\headwidth}{\normalrulethickness}     \makeheadfootruleprefix{custom}{\color{blue}}{}     \makeheadposition{custom}{flushright}{flushleft}{}{}     \makepsmarks{custom}{%       \nouppercaseheads       \createmark{chapter}{both}{nonumber}{}{}       \createmark{section}{right}{shownumber}{}{. \space}       \createplainmark{toc}{both}{\contentsname}       \createplainmark{lof}{both}{\listfigurename}       \createplainmark{lot}{both}{\listtablename}       \createplainmark{bib}{both}{\bibname}       \createplainmark{index}{both}{\indexname}       \createplainmark{glossary}{both}{\glossaryname}%     }     \makeevenhead{custom}%       {\raisebox{-1.2pt}{\colorbox{blue}{\textcolor{white}{\pagenumfont\thepage}}}}%       {}%       {\evenheadfont\leftmark}     \makeoddhead{custom}%       {\oddheadfont\rightmark}%       {}%       {\raisebox{-1.2pt}{\colorbox{blue}{\textcolor{white}{\pagenumfont\thepage}}}}     \pagestyle{custom}          \newcommand{\sample}{Some text to experiment with page styles.}          \begin{document}       \chapter{My chapter}       \section{My section}       \newpage       \sample{} \sample{} \sample{} \sample{} \sample{} \sample{} \sample{}       \newpage       \sample{} \sample{} \sample{} \sample{} \sample{} \sample{} \sample{}     \end{document}


title: Is there a way to animate table columns in beamer?

text: I have a beamer presentation with a `tabular` environment. I want to expose the `tabular` environment column by column, on separate slides. I tried using `\pause` in the `tabular` header, or in the cells themselves, but they don't show a whole column at once. I want even the headers not to show until the next click. Is it possible to do that without having to copy partial tables into multiple frames? (I also want each header of a new column appearing to be alerted, compared to the previous columns, but that's not a must if it is hard.)


title: Adding page number to the even page right after \part

text: Friends, I've never used `\part{}` before, so bear with me. `=)` Consider the following code:               \documentclass[twoside]{book}     \usepackage{lipsum}          \begin{document}          \pagestyle{empty}     \begin{titlepage}     My title page.     \end{titlepage}          \cleardoublepage     \pagestyle{plain}          \frontmatter     \tableofcontents     \clearpage     \mainmatter          \part{Hello World}     \chapter{Test one}     \lipsum[1]     \section{My section one}     \lipsum[1]          \part{Goodbye World}     \chapter{Test two}         \lipsum[1]     \section{My section two}     \lipsum[1]          \end{document}      I'd like to have page numbers in the even pages right after the **Part x** titles. It would be pages 6 and 10 of my example. ![Pages](http://i.stack.imgur.com/aKWxa.png) I could redefine the `empty` pagestyle to act as `plain`, but I didn't want to do that. In fact, I tried that - and it works - but I also need `empty` pagestyles in my original document. I suppose `\part` is like a book division, so it should look like another "cover" (what would explain why there's no number in the _hm_... back of the page). In my particular case, I need that number to be in there. Does anybody have an idea?


title: extract cited entries from bibliography with biber

text: According to the manual and many posts I should be able to do:                   biber --output_format=bibtex test.bcf      And I'll get a new .bib file called test_biber.bib containing all cited entries in test.tex, in citation order. But, when I do that, and then I get:                Biber: Output format 'bibtex' is only valid in tool mode      So I added the --tool, but then biber expects a bib file and looks for test.bcf.bib. So it doesn't work. And if I use mybibfile.bib as an argument, then it just rewrites mybibfile_biber.bib with nicer format. So, am I doing something wrong?


title: How to let all the pagestyle of pages from \frontmatter to \mainmatter empty

text: `\frontmatter` may include   * Table of Contents   * List of Figures   * List of Tables   * Preference   * and other parts Now, I want to set up the pagestyle of **pages** range from the tag `\frontmatter` to the tag `\mainmatter` be **plain**. that is said all of `\tableofcontents`,`\listoffigures`,`\listoftables`,`preference` parts should not contain page number, page head, page foot. I dont want to set them one by one with `\thispagestyle`. the `\pagestyle` of all **pages** in `\mainmatterpart` should be **fancy**. I think if I can deal with `\frontmatter`, I also can apply the method to `\mainmatter` to `\backmatter`. Am I right?


title: Using \emph and a subscript

text: How would I go about adding a subscript to a symbol I'm defining from an equation. For example I have an equation `E_m = \alpha_m x + y` How can I then do something like `\emph \alpha\textsubscript{m}` The above gives me errors and I can't figure out how to correct this.


title: Dealing with Images in a Multiple Column Environment, The Idiomatic Method?

text: I've been using multiple column formats for a while now. Sometimes it's through the multicol package, sometimes it's using the twocolumn option for the document class. In both cases, dealing with mixed column numbers can be a pain. It's less of a pain, and, more importantly, more predictable using a twocolumn document class, but it's less flexible. What is, at this point, the idiomatic way of dealing with multiple column environments? In particular, what is the best way to deal with needing an environment with figures and tables spanning multiple columns? My current solution is using the multicol package and ending the multicols environment, placing the figure, and starting the multicols environment. This can ruin space optimisation, though. Another way this is done is by creating a nonfloat minipage. Neither solution is particularly appetizing, and it really seems like there must be a better way at this point.


title: How to reassign -- and --- in unicode fonts?

text: In XeTeX, after loading the font `lmroman10-regular.otf`, -- and --- are not matched to en- and em-dashes.               Here-have--some---text.          \font\rm="[lmroman10-regular.otf]"     \rm     Here-have--some---text.     \bye      ![enter image description here](http://i.stack.imgur.com/oSO09.png) How can I remap them?