I'm trying to use both the bbm (to write my preferred style of indicator variables) and the hyperref packages (to reference web URLs).  However, something strange seems to be going on whenever I use bbm in a subsection title. Any idea what might be going on here? Simple example:  \documentclass[12pt,titlepage]{article}  \usepackage{bbm} \usepackage{hyperref}  \begin{document}  \subsection{Model: Logistic Regression of $\mathbbm{1}\left[var\right]$}  \href{http://www.google.com}{This} is a hyperlink, and  this\footnote{footnote} is a footnote.  $\mathbbm{1}\left[x\in S\right]$ is an indicator in plain text  \end{document}   The math itself compiles to pdf just fine, as well as the body text, for that matter.  However, a red box tends to show up somewhere in the document (which goes away if I click somewhere in the .pdf). Further, my compiler (I'm using the LaTeXTools plugin to SublimeText 3 on Linux which operates on latexmk) gives me the following warning messages, which I've no idea how to interpret.   ./test.tex:8: Package hyperref Warning: Token not allowed in a PDF string (PDFDocEncoding):(hyperref)                removing `math shift' on input line 8. ./test.tex:8: Package hyperref Warning: Token not allowed in a PDF string (PDFDocEncoding):(hyperref)                removing `\left' on input line 8. ./test.tex:8: Package hyperref Warning: Token not allowed in a PDF string (PDFDocEncoding):(hyperref)                removing `\right' on input line 8. ./test.tex:8: Package hyperref Warning: Token not allowed in a PDF string (PDFDocEncoding):(hyperref)                removing `math shift' on input line 8.   If I exclude the mathbbm instance from the subsection title, the random red box still appears, but the warnings stop.
When compiling a beamer presentation and using the following \author command  \author{Name \\ \texttt{my.email@domain.com}}   I get the following hyperref warning in my logfile  Package hyperref Warning: Token not allowed in a PDF string (PDFDocEncoding): (hyperref)                removing `\\' on input line 15.   Package hyperref Warning: Token not allowed in a PDF string (PDFDocEncoding): (hyperref)                removing `\new@ifnextchar' on input line 15.   I understand that this has to do with hyperref setting the PDF metadata, where the linebreak does’t make much sense and should be removed.  Trying to set  \hypersetup{pdfauthor={Name}}   does’t change the situation, seems like hyperref is still looking at the author command.  How do I get the desired display of author name with email and still keep hyperref happy?
How to remove the top horizontal bar in fancyhdr? When using fancyhdr, how do you remove the top horizontal rule?  I do not want a header at all, just a footer.  This is what I do now:  \documentclass{article} \usepackage{fancyhdr} \pagestyle{fancy}  \lfoot{text} \cfoot{text 2} \rfoot{text 3}  \begin{document} Foo Bar \end{document} How to update to the latest numpy and scipy on Ubuntu 14.04LTS On my Ubuntu 14.04LTS, for python3, I have   &gt;&gt;&gt; import numpy  &gt;&gt;&gt; import scipy  &gt;&gt;&gt; numpy.__version__  '1.8.2'  &gt;&gt;&gt; scipy.__version__  '0.13.3'   I want to update numpy and scipy to the most , I tried with the following commands  sudo pip3 install --upgrade numpy sudo pip3 install --upgrade scipy   both commands ran successfully, but the version numbers didn't change to 1.9.2 and 0.16.0 at all for both python packages (after restarting the computer). Anyone knows how to update to the most version? Thank you very much!! Is it considered rude if you only ask Questions but almost never answer one yourself I have used the websites of SO a lot the past few months because I am busy with a large scale web project. I feel I get better answers here on SO than when I just do a Google search, maybe because I can be more specific here with my problem, and the responses are really fast.  Occasionally when I am not working I try to answer some questions, but the question almost always has an answer which is 'as good as' or 'better' than the answer I would supply.  So my question/answer ratio is about 20/1 something, if not more. When I look at my profile page I see a bucket-load of questions and almost nothing I answered myself.  Is this considered bad behaviour? I can see that this looks a little egoistic.  : One devoted to one's own interests and advancement. Why am I seeing a bomb icon on my files and folders in Ubuntu? Restoring original Settings Menu in QGIS customization? Making some tests in Windows XP for customizing a user interface in QGIS 1.8 (see ), I have unchecked, among other options, the Settings Menu. This means that, after restarting QGIS, there's no way of recovering the older settings because there is not already a Setting Menu. So, I cannot reload any ini file.  For your information, as a precaution, previously I have saved in a folder both the original ini file, with all the options, and the customized ini file with only some options (of course, not included here the necessary Settings Menu).  Before reinstalling QGIS (version 1,8), I would like to try other smarter options if there's any. Where and what does QGIS look at where this applications starts? Check if the application is already installed How to auto populate with conditions? Number of elements in a finite $\sigma$-algebra I have searched this for hours but still no luck, obviously doing something wrong.  The journal (Risk Analysis) wants "Reference style is based on the National Library of Medicine (NLM) style guide. In-text citations are numbered, superscripted and in parentheses, and the reference list is numbered in order of appearance within the manuscript. Footnotes are superscripted without parentheses".  Could someone please suggest an appropriate .bst file to use that will produce this? Thanks, J Is it worth encrypting email addresses in the database? How can I play encrypted DVD movies? I am stuck with the proof of below expression;  "If F is an infinite field, then no infinite subgroup of F* (the multiplicative group of F) is cyclic."  anyone can help? What defines a PC's consciousness of self, memories and knowledge? Can anyone help me out with how to make Bing Picture to my Desktop Wallpaper?    So it works by downloading the highest quality of todays picture. Then storing it ex in the Picture folder of your account. After that automatically changing the picture itself.  It should continue the same everyday without hassle in the background.  Probably something I have to add in the Startup Applications. Any differences between Ubuntu versions?    -Do I have to write a script?  This would be appreciated by many others too! Thank You in Advance :) I need a robust and simple way to remove illegal path and file characters from a simple string. I've used the below code but it doesn't seem to do anything, what am I missing?  using System; using System.IO;  namespace ConsoleApplication1 {     class Program     {         static void Main(string[] args)         {             string illegal = "\"M&lt;&gt;\"\\a/ry/ h**ad:&gt;&gt; a\\/:*?\"&lt;&gt;| li*tt|le|| la\"mb.?";              illegal = illegal.Trim(Path.GetInvalidFileNameChars());             illegal = illegal.Trim(Path.GetInvalidPathChars());              Console.WriteLine(illegal);             Console.ReadLine();         }     } } How to find all subgroups of a direct product? I am wondering how do we find all subgroups of a direct product? Is there a method to find it?  For example, how can we find all the subgroups of $\mathbb{Z}_2\times\mathbb{Z}_2$?  There is the answer: $\{(0, 0), (1, 0)\}, \{(0, 0), (0, 1)\}, \{(0, 0), (1, 1)\}$, and the improper and trivial subgroup. But I do not know the method how to find it.   All I can think about is the following: since the order of $\mathbb{Z}_2\times\mathbb{Z}_2$ is $4$, the order of a subgroup of it can be $1,2$ or $4$.   If order is $1$, then it is trivial, and if order is $4$, it is proper. Then, the order of a subgroup is $2$. We know all the elements of   $\mathbb{Z}_2\times\mathbb{Z}_2$, so we try all the pairs.   Is that the method?   But what if we are given a bigger order product, such as $\mathbb{Z}_2\times\mathbb{Z}_8\times\mathbb{Z}_3\times\mathbb{Z}_9$? It looks very long to try all possibilities.   Can anyone help?  Thanks Is 1+1 =2 a theorem? A theorem is defined to be a mathematical statement that is proven to be true. The statement $1+1=2$ has definitely been proven in the history of mankind (Russel and Whitehead had once proven it in the book Principia Mathematica).   So can it be considered as a theorem? What determines something to be a theorem (besides it being proven to be true)? Logical Volume, Physical Volume and Volume Groups Please can someone explain to me the meaning of Logical Volume, Physical Volume and Volume Groups? Of what importance and advantage are they in linux? Ubuntu Server 18.04 LVM out of space with improper default partitioning How can I override the OnBeforeUnload dialog and replace it with my own? I need to warn users about unsaved changes before they leave a page (a pretty common problem). window.onbeforeunload = handler  This works but it raises a default dialog with an irritating standard message that wraps my own text. I need to either completely replace the standard message, so my text is clear, or (even better) replace the entire dialog with a modal dialog using jQuery. So far I have failed and I haven't found anyone else who seems to have an answer. Is it even possible? Javascript in my page: &lt;script type=&quot;text/javascript&quot;&gt;        window.onbeforeunload = closeIt; &lt;/script&gt;  The closeIt() function: function closeIt() {   if (changes == &quot;true&quot; || files == &quot;true&quot;)   {       return &quot;Here you can append a custom message to the default dialog.&quot;;   } }  Using jQuery and jqModal I have tried this kind of thing (using a custom confirm dialog): $(window).beforeunload(function () {     confirm('new message: ' + this.href + ' !', this.href);     return false; });  which also doesn't work - I cannot seem to bind to the beforeunload event.