How can I put pagenumber into longtable header?
Change running heads in longtable (or other "long table" package)
Conjunction Puzzle: Is this clause dependent or independent? Third grade teacher here. I plan to teach students to distinguish between simple, compound and complex sentences — but only if I can demonstrate a clear and meaningful difference between the latter two!  Complex or Compound? Each sentence in the following pairs is similar to its partner.   All dogs are mammals, so huskies are mammals. All dogs are mammals, therefore huskies are mammals. I come bearing soup, for Kate is sick. I come bearing soup, because Kate is sick.   Are the sentences above complex or compound?   First, we need to decide whether each italicized clause is independent or dependent. To me, they all look dependent. If that is the case, there's not much need to teach about compound sentences. Is there a meaningful difference between the sentences in each pair that I am missing? (Are the FANBOYS as special as they'd like to think?) Multi-window: prevent the out-of-focus app from pausing? I'm using a class I've derived from DocumentPaginator (see below) to print simple (text only) reports from a WPF application. I've got it so that everything prints correctly, But how do I get it to do a print preview before printing? I have a feeling I need to use a DocumentViewer but I can't figure out how.  Here's my Paginator Class:  public class RowPaginator : DocumentPaginator {     private int rows;     private Size pageSize;     private int rowsPerPage;      public RowPaginator(int rows)     {         this.rows = rows;     }      public override DocumentPage GetPage(int pageNumber)     {         int currentRow = rowsPerPage * pageNumber;         int rowsToPrint = Math.Min(rowsPerPage, rows - (rowsPerPage * pageNumber - 1));         var page = new PageElementRenderer(pageNumber + 1, PageCount, currentRow, rowsToPrint)                        {                            Width = PageSize.Width,                            Height = PageSize.Height                        };         page.Measure(PageSize);         page.Arrange(new Rect(new Point(0, 0), PageSize));         return new DocumentPage(page);     }      public override bool IsPageCountValid { get { return true; } }      public override int PageCount { get { return (int)Math.Ceiling(this.rows / (double)this.rowsPerPage); } }      public override Size PageSize     {         get { return this.pageSize; }         set         {             this.pageSize = value;             this.rowsPerPage = PageElementRenderer.RowsPerPage(this.pageSize.Height);             if (rowsPerPage &lt;= 0)                 throw new InvalidOperationException("Page can't fit any rows!");         }     }      public override IDocumentPaginatorSource Source { get { return null; } } }   The PageElementRenderer is just a simple UserControl that displays the data (at the moment just a list of rows).  Here's how I use my Row Paginator  PrintDialog dialog = new PrintDialog(); if (dialog.ShowDialog() == true) {     var paginator = new RowPaginator(rowsToPrint) { PageSize = new Size(dialog.PrintableAreaWidth, dialog.PrintableAreaHeight) };      dialog.PrintDocument(paginator, "Rows Document"); }   Sorry for the code dump, but I didn't want to miss something relevant. Should reputation from SO carry over to Meta? How do I add new wallpapers? I have Ubuntu 11.10 installed and want to download and install additional wallpapers on my desktop.   How do I do this? Can you use another material as input to material nodes in cycles? I have this run.sh file, and I've create a symbolic link into my desktop.   When I double-click on it the file the following dialog appearsr    And I have to click on "run" each time. How can I create a link that runs by default? Is it posible to upload file in Lists Attachments in SharePoint in custom way I tried to install wine using these commands: sudo apt-get install -y wine  And: sudo apt-get install wine  But terminal says that: Reading package lists... Done Building dependency tree        Reading state information... Done Package wine is a virtual package provided by:   winehq-staging 2.16.0~zesty   winehq-stable 2.0.2~zesty   winehq-devel 2.16.0~zesty   wine-development 2.0-3ubuntu1 You should explicitly select one to install.  E: Package 'wine' has no installation candidate  So there are 4 different version of wine. What is the difference between these versions. Which one is better? I wanted to install Internet Explorer from it and I installed winehq-stable. But I couldn't see that among applications in Winetricks. Do the other versions of wine have more applications to install? What is the difference? Opening document library files in popup or new window Is there any easy way to open the document library files in a new window or popup depending on the file types?  e.g. PDF - In Adobe reader (currently opens in IE)  Image file (currently opens in IE) Prove upper bound for recurrence I am working on  problem 3 from MIT's Fall 2010 OCW class 6.042J. This is covered in  which is about recurrences.  Here is the problem:  $$A_0 = 2$$ $$A_{n+1} = A_n/2 + 1/A_n, \forall n \ge 1$$  Prove   $$A_n \le \sqrt2 + 1/2^n,  \forall n \ge 0$$  I have graphed the recurrence and the upper bound and they seem to both converge on $\sqrt2$.    Also, if you ignore the boundary condition $A_0 = 2$ then you find that $\sqrt2$ is a solution to the main part of the recurrence. i.e. $\sqrt2 = \sqrt2/2 + 1/\sqrt2$.  The chapter and videos on recurrences have a lot to say about a kind of cookbook solution to divide and conquer recurrences which they call the Akra-Bazzi Theorem. But this recurrence does not seem to be in the right form for that theorem. If it were in the form $A_{n+1} = A_n/2 + g(n)$ then the theorem would give you an asymptotic bound. But $1/A_n$ is not a simple function of $n$ like a polynomial. Instead it is part of the recurrence.  Also, the chapter has a variety of things to say about how to guess the right solution and plug it into an inductive proof, but I haven't had much success. I have tried possible solutions of various forms like $a_n = \sqrt2+a/b^n$ and tried solving for the constants $a$ and $b$ but to no avail.  So, if someone can point me in the right direction that would be great. I always assume that the problem sets are based on something taught in the videos and in the text of the book but I am having trouble tracking this one down.  Bobby I can successfully tether my Mac (10.7.3) to my iPhone4 (5.0.1) via wifi, no problem, been doing it for months.  However, when I try to tether via bluetooth instead, I can't seem to see the internet from my mac.  Network Settings reports a green light for Bluetooth PAN, but my browser can't connect to anything at all.  My Mac reports very similar IP addresses for both, starting with 172.20.10 and differing only in the last octet.  Any idea why I can't successfully tether via bluetooth? Does any test actually prove causation? Is there a way to export large multi-layered Illustrator file to Photoshop?  When I export with preserve layers and text edit-ability, the complex layers are flattened. I've reorganized my layers to have simple groupings but that's time consuming.  Is there a more effective way of doing this? Or script to automate it? Is there an alternative to Cantor's cardinalities that makes proper subsets smaller than their sets? Cantor defined an infinite set as a set whose subset can be placed in a one-to-one correspondence with its subset. That is, take the set of all natural numbers: {0, 1, 2, 3, 4,...}. From that set, you can form a subset of all even numbers: {0, 2, 4, 6,...}. There is a one-to-one correspondence between both these sets. After all, you can multiply each member in the set of all natural numbers by 2, and you’ll get the set of all even numbers. Because of this one-to-one correspondence, the two sets have the same cardinality, despite the set of even numbers being a subset of the set of natural numbers. This is counter-intuitive to me. How can a subset of a set be as big as the set itself? To make the intuition more concrete, consider the set of multiples of 1,000,000: {0, 1,000,000, 2,000,000,...}. There is a one-to-one correspondence between this set and the set of all natural numbers. So they have the same cardinality. This is really counter-intuitive.  From as far as I can tell, there are basically two axioms at play here:  A1: If all members of set A can be placed in a one-to-one correspondence with all the members of set B, then both sets have the same cardinality.  A2: If set A is a proper subset of set B, then A has a smaller cardinality than set B.  How Cantor defined infinite sets is that he accepted A1 and rejected A2. That is counter-intuitive to me. But mathematicians might say that my intuition is just wrong. So my question is whether we can define infinite sets in another way, i.e. accept A2 but reject A1. That is, the set of even numbers is smaller than the set of all natural numbers, even though both sets have a one-to-one correspondence. If you think this is counter-intuitive because sets with one-to-one correspondence with each other should have the same cardinality, and thus think this is wrong, why can’t I say the same when Cantor accepted A1 and rejected A2? Either way, there is something counter-intuitive and paradoxical.   So, my questions are:   Can we accept A2 and reject A1 for the definition of an infinite set? What arguments, if any, are given for accepting A1 and rejecting A2? I'm sorry if this is a broad question but can someone explain to me how to interpret these regression diagnostic plots? I understand the Normal Q-Q show's how normal the spread of the data is, but the other three I am confused by. For the Residuals vs Leverage, what does it mean for a point to be outside of the bounds? What does it mean if the red lines are parabolic and curved like in the first two? Why do we care about residuals, and what do they tell us? I've searched the web multiple times for some guide to interpret these and I can't get any straight forward answers. Any help is appreciated, thank you. How do I disable Aero Shake in Windows 7? I'm always accidentally minimizing most of my windows. This is really annoying. How do I disable Aero Shake? For creating the graphics for my thesis (function graphs, flow charts, line art sketches) I've chosen to use the sans serif font by  \renewcommand\familydefault{\sfdefault}    However when I use mathematical symbols like $p_{s}$, they are still typeset in roman font and that looks weird:    So I wonder:   how could I force mathematical expressions also be typeset in \sfdefault if I do, are there any negative sideeffects to expect (with greek signs or other special symbols?) OR should I typeset all "mathematical" graphs (axis labels etc.) in roman font, and only make the other graphics like flow charts and sketches with sans serif font? What's the simplest way to wrap extruded text around a cylinder? What's the simplest way to wrap extruded text around a cylinder that has a specific radius (for example, the label on a can of baked beans)?  I've tried using the Simple Deform modifier, but that (a) doesn't allow you to choose a radius and (b) requires the text to be converted to a curve.  I'm trying to model a cylinder with radius of 30, which has a line of embossed text that runs around the curved side, facing outward.  Thanks! Unbiased estimator for geometric distribution parameter p