How do you vertically align an image to the middle of a div?
How to vertically align an image inside a div
Unable to lock the administration directory (/var/lib/dpkg/), are you root? I get this error in Lubuntu 12.04 when I try to update in terminal:  $ apt-get update E: Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied) E: Unable to lock directory /var/lib/apt/lists/ E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied) E: Unable to lock the administration directory (/var/lib/dpkg/), are you root? Read two column CSV as dict with 1st column as key Learning Python programming with generic GIS goals in mind? I have had several business loans and understand that this is not by any means typical.  I noticed that for a year my payments were not decreasing the principal on the loan. When I asked the bank why, I found out that at some point my payments were getting applied to principal only. Now I am paying interest off that was not paid for 6 months or so.  My banker states that he can change all the interest payments to principal payments. I am confused to why this would be. If I make all my principal payments first then would the bank lose a substantial amount of interest?  This has happened on 2 of the 3 loans I have looked at so far.  If they are willing to change all the payments to principal only, would this be beneficial to paying less interest ultimately? I assume there would be an interest account accruing somewhere that would need to be paid off at the end of the loan.  I understand that typically you have a loan balance that would include interest and principal. My balance owed did not change when I continued to make same payment? It gets applied to interest. The balance on the statement must not be a true balance. There must be interest owed above the balance showed but why would they do this to start with? They applied full payments to principle only first in order for interest to get to be more than several payments AIC versus Likelihood Ratio Test in Model Variable Selection The software that I am currently using to build a model compares a "current run" model to a "reference model" and reports (where applicable) both a chi-squared p-value based on likelihood ratio tests and AIC values for each model.  I know that one advantage of AIC over likelihood ratio tests is that AIC can be compared on non-nested models.  However, I am not aware of any reason why AIC couldn't or shouldn't be compared on nested models.  In my model, when comparing nested models for variable selection, I'm finding several cases where the likelihood ratio test and the AIC comparison are suggesting opposite conclusions.  Since both are based on likelihood calculations, I'm struggling to interpret these results.  However the documentation of my software says (without explaining),   "If two models are nested (i.e. one is a sub-set of the other) then the more usual chi-squared test is the most appropriate to use. If the models are not nested, the AIC can be used..."  Can anyone elaborate on this and/or explain why AIC is not as helpful as likelihood ratio tests on nested models? How do I remove log out, reboot, and shut down from GNOME shell application list? I’m new to Ubuntu. I don't know where the log out, reboot and shut down icons in my application list came from. I just need to remove this from here. latex : Exclude draftwatermark from specific pages I am using draftwatermark package. Is there any option to exclude watermark from some specific pages? Say no watermark from pg 3-4. I can not use xwatermark package. It conflicts with the geometry package of my document.  MWE:  \documentclass[12pt,a4paper]{exam} \usepackage{draftwatermark}  \usepackage{lipsum}   \SetWatermarkAngle{45}  \SetWatermarkLightness{.8}  \SetWatermarkFontSize{10cm}  \SetWatermarkScale{5}  \SetWatermarkText{\tt{12345}}  \begin{document}  \lipsum[1-20]  \end{document} How many times has the matter in our solar system been recycled from previous stars? I've got a basic understanding of these facts:   The Universe is a little over 13 billion years old.  Our galaxy is almost that old. Our solar system is roughly 4.6 billion years old. The heavier elements (Carbon, oxygen, etc...) are only produced by stars.   When our solar system coalesced, the matter that makes up the planets came from a previous generation of stars.  (Meanwhile our Sun is busy making its own slightly-heavier elements, but those aren't ours.  Those belong to the next "generation" after our star dies.)  So we're all sitting on a rock whose matter was spewed out of a star (or stars) that preceded this solar system. But what I want to know is:  How many cycles of coalescing, fusing, nucleosynthesis, exploding -- and then repeating the cycle -- have this atoms in this ball of rock I'm standing on been through?    How do you know this?  Can you tell by the make-up of the matter in the solar system?  Looking around the Orion arm to see remnants of our former home? This is not a duplicate question because I am looking for an explanation directed to a general audience as to the mistakes (if any) in  (reproduced below). (Numberphile is a YouTube channel devoted to pop-math and this particular video has garnered over 3m views.)   By general audience, I mean the same sort of audience as the millions who watch Numberphile. (Which would mean, ideally, making little or no mention of things that a general audience will never have heard of - e.g. Riemann zeta functions, analytic continuations, Casimir forces; and avoiding tactics like appealing to the fact that physicists and other clever people use it in string theory, so therefore it must be correct.)  Numberphile's Proof.  The proof proceeds by evaluating each of the following:  $S_1 = 1 - 1 + 1 - 1 + 1 - 1 + \ldots$   $S_2 = 1 - 2 + 3 - 4 + \ldots $   $S = 1 + 2 + 3 + 4 + \ldots $   "Now the first one is really easy to evaluate ... You stop this at any point. If you stop it at an odd point, you're going to get the answer $1$. If you stop it at an even point, you get the answer $0$. Clearly, that's obvious, right? ... So what number are we going to attach to this infinite sum? Do we stop at an odd or an even point? We don't know, so we take the average of the two. So the answer's a half."   Next:  $S_2 \ \ = 1 - 2 + 3 - 4 + \cdots$  $S_2 \ \ = \ \ \ \ \ \ \ 1 - 2 + 3 - 4 + \cdots$  Adding the above two lines, we get:  $2S_2 = 1 - 1 + 1 - 1 + \cdots$  Therefore, $2S_2=S_1=\frac{1}{2}$ and so $S_2=\frac{1}{4}$.  Finally, take  \begin{align} S - S_2 &amp; = 1 + 2 + 3 + 4 + \cdots           \\ &amp; - (1 - 2 + 3 - 4 + \cdots)          \\ &amp; =   0 + 4 + 0 + 8 + \cdots           \\ &amp; = 4 + 8 + 12 + \cdots           \\ &amp; = 4S \end{align}  Hence $-S_2=3S$ or $-\frac{1}{4}=3S$.  And so $S=-\frac{1}{12}$. $\blacksquare$ What is the recommended way to encrypt user passwords in a database? How to determine if a string is a valid variable name? ERROR 000212: Cannot create XY event source Failed to execute (MakeXYEventLayer)? I have a csv file that is 133mb in size and has over 1.3 million lines of data.  Each line of data has its own lat/long and I was wondering what would be the best way to display those points based off the lat/longs in ArcGIS Desktop 10 and ultimately turn it into a point shapefile?  So far I have tried the "Make XY Event Layer" tool but that keeps failing...  ERROR 000212: Cannot create XY event source Failed to execute (MakeXYEventLayer).  The csv file is properly formatted and the lat/long fields are numeric so I have no idea why it keeps crashing.  Here is what the first 2 lines of my CSV look like, the first line is what should be the header:  "LAT","LONG","CUSTOMER_MASTER_ID","STORE_NBR","TRANSACTION_DT","SKU_DIVISION_ID","SKU_DEPARTMENT_ID","SKU_CLASS_ID","SKU_CATEGORY_ID","SKU_NBR","SALES_AMT" "32.363544","-110.969778","2000000792627","2940","8/11/2010","2060","3920","5120","84021","5127866","13.99"   Any ideas? How to get the current directory in a C program? I'm making a C program where I need to get the directory that the program is started from.  This program is written for UNIX computers. I've been looking at opendir() and telldir(), but telldir() returns a off_t (long int), so it really doesn't help me.   How can I get the current path in a string (char array)? What's a way to implement a flexible buff/debuff system? How to redirect stderr and stdout to different files and also display in terminal? I want to see the output of a command in the terminal as if there was no redirection.  Also, stderr needs to be redirected to err.log and stdout needs to be redirected to stdout.log.  It would be nice to also have the exact copy of what is shown in terminal, i.e. errors printed as and when it occurs, in a separate file: stdouterr.log. How do I reset my manor so I can rebuild it with different options? I currently have Windstad Manor and built it all. Now I regret some choices and I'd like to rethink and rebuild it.  Is there any console way to "nuke" the manor and rebuild it from ground up? Vertical line for the the right margin in Notepad++ How to extract images from Word Document from Linux Is there a (Linux) command-line tool to extract all the images from a MS Word document, (preferably one that could handle the .docx format)? Keyboard macro to change default audio device Windows 7, Logitech G110 keyboard  2 audio devices (headphones and speakers)  I am hoping to find a quick way to macro a key to switch to headphones, and a key to switch to speakers.  Anyone have a good program or anything of that nature?  EDIT:  Using AHK to try and get this task working as hoped is sadly not doing the trick.  I have included a screenshot of my audio set, as well as a screenshot of my script as it sits now.    I have also tried to uncheck "show disabled devices" and modified the script to be Down 1, and Up 1 respectively.  It will work for one device, but it refuses to switch to the secondary. Why do some tests have a (nonzero) minimum score?