Buffalo explanation
How should I parse the sentence "Buffalo buffalo Buffalo buffalo buffalo buffalo Buffalo buffalo."
Implement a Selective Comment Ban I have the following code:  Using cmd As SqlCommand = Connection.CreateCommand     cmd.CommandText = "UPDATE someTable SET Value = @Value"     cmd.CommandText &amp;= " WHERE Id = @Id"     cmd.Parameters.AddWithValue("@Id", 1234)     cmd.Parameters.AddWithValue("@Value", "myValue")     cmd.ExecuteNonQuery End Using   I wonder if there is any way to get the final SQL statment as a String, which should look like this:  UPDATE someTable SET Value = "myValue" WHERE Id = 1234   If anyone wonders why I would do this:   for logging (failed) statements for having the possibility to copy &amp; paste it to the Enterprise Manager for testing purposes Show that $A\in\mathbb{C}_n$ is normal $\iff$ $tr(A*A) = \sum_{i = 1}^n|\lambda_i|^2$, where $\lambda_1,...,\lambda_n$ are the eigenvalues of $A$. Proof a $(2n-1)$-compact manifold I have no idea how prove that $$\{(z_0,\ldots,z_n)\in\mathbb{C}^{n+1} \quad| \quad z_0^d+z_1^2\ldots+z_n^2=0, \quad |z_0|^2+|z_1|^2\ldots+|z_n|^2=2\}$$ is a $(2n-1)$-compact manifold.  How give the charts. For $n=1$ and $d=2$ not distinguish which 1- manifdold is? When does $\lim_{n\rightarrow \infty} a_n = 0$ imply $\sum_{n = 0}^{\infty} a_n$ converges? This is just a general question. I know the opposite statement is always true. I'm just asking when the converse holds. I know that the converse is not true in some cases, such as for harmonic series. What additional restrictions are needed to make this statement true? I got the following problem: Right now I am checking my equations, which are usually written in align. This looks great in most of the cases, but sometimes the pagebreaks are weird, ie there is a lot of vertical whitespace left (like 2.5cm) at the end of a page. I made the following MWE to illustrate this.  \documentclass[a4paper, 12pt, headsepline]{scrreprt} \usepackage[onehalfspacing]{setspace} \usepackage{amsmath, amssymb, mathtools} \usepackage{mathptmx} \usepackage[a4paper]{geometry} \geometry{left=2cm,right=5cm,top=2cm,bottom=2cm} % \usepackage{lipsum} %\lipsum \usepackage[pangram]{blindtext}  \begin{document} \Blindtext[1][3]%1 paragraph, 3 pangrams \begin{align} X_{t+1} &amp;=  \frac{X_{t+1}+X_{t+1}}{Y_t}  \label{eq:1}  \intertext{Solving...:} \notag  X_{t}  &amp;=  \frac{X_{t+1}+X_{t+1}}{Y_{t+1}} \notag \\ \intertext{Solving further...:} \notag  % ===PAGEBREAK HERE: 2nd page begins=== &amp;= \frac{X_{t+1}+X_{t+1}}{Y_t} +  \frac{X_{t+1}+X_{t+1}}{Y_t}  \notag \\ &amp;= \frac{X_{t+1}+X_{t+1}}{Y_t}...  \notag \\ \intertext{Solving further...:} &amp; = \frac{X_{t+1}+X_{t+1}}{Y_t}  \notag \end{align}  \end{document}   In the MWE, the first 'Solving further' should be on the first page instead (to save space and it would also look better I guess?). The position where I would like the pagebreak to be is also marked as a comment in the MWE.  My question is first on a general basis: Which is the best environment to achieve multiple line equations, which can be aligned as in align, and to save space at the same time? Or to be more precise: If possible, I'd like to stick with align and adapt the pagebreaks only if necessary.  Thanks! How to evaluate a math expression given in string form? Converting Polygon into single or all Points using QGIS? This is problem 6.2 from the 3rd edition of Principles of Mathematical Analysis.      Problem 6.2: Suppose $f\geq 0$, f is continuous on $[a, b]$, and $\int_a^b f(x) \, dx = 0$. Prove that $f(x)=0$ for all $x \in [a, b]$.   I'm looking for a critique of my proof. It's a pretty easy problem, but I am always wary of making too bold of assumptions, especially on these low level/fundamental proofs. I'll be using Rudin's notation and refer to theorems from the text (If I should include the text of each theorem, feel free to leave a comment... I'm lazy but could probably use the TeX practice :p)  Proof: Assume, for contradiction, that $f&gt;0$. Then, for any partition $P$ we have the Lower Riemann Sum: $L(P, f)=\sum_{i=1}^n m_i \, \Delta x_i$. At least one $\Delta x_i$ must be positive, since $a &lt; b$, and each $m_i$ must be positive since we have $f&gt;0$ by assumption, so certainly $\sup f &gt; 0$. That means $L(P, f)&gt;0$. Thus, we have: $$0 = 0(b-a) &lt; L(P,f)\leq \sup L(P, f) = \inf U(P,f) =L$$ where the last string of equalities holds because our function is continuous on a compact interval, so is integrable by theorems 6.8 and 6.6. So our integral has value $L&gt;0$. This is in contradiction to our given assumption that $\int_a^b f(x) \, dx = 0$, so we must have that $f=0$ on $[a, b]$. $\Box$  So, I am wondering if my proof is correct (and is presented well). Also if someone could enlighten me as to what Rudin means when he say "Compare this with exercise 1," I'd be appreciative. Is it a hint or is there something else he expects you to notice? there are a lot of things I could compare :)...  Exercise 6.1: Suppose $\alpha$ increases on $[a, b]$, $a \leq x_0 \leq b$, $\alpha$ is continuous at $x_0$, $f(x_0)=1$, and $f(x)=0$ if $x\neq x_0$. Prove that $f$ is Riemann-Stieltjes Integrable and that $\int f \, d\alpha = 0$ Viruses: Adaptation to a new host through repeated host jumps Is there a way in Java to have a map where the type parameter of a value is tied to the type parameter of a key? What I want to write is something like the following:  public class Foo {     // This declaration won't compile - what should it be?     private static Map&lt;Class&lt;T&gt;, T&gt; defaultValues;      // These two methods are just fine     public static &lt;T&gt; void setDefaultValue(Class&lt;T&gt; clazz, T value) {         defaultValues.put(clazz, value);     }      public static &lt;T&gt; T getDefaultValue(Class&lt;T&gt; clazz) {         return defaultValues.get(clazz);     } }   That is, I can store any default value against a Class object, provided the value's type matches that of the Class object. I don't see why this shouldn't be allowed since I can ensure when setting/getting values that the types are correct.  EDIT: Thanks to cletus for his answer. I don't actually need the type parameters on the map itself since I can ensure consistency in the methods which get/set values, even if it means using some slightly ugly casts. What is the difference between a function decorated with  and one decorated with ? PHPUnit skips all tests I have removed Windows 7 using GParted, and want my computer to boot straight into Ubuntu, but I still get the dual boot screen, how can I fix this? Adding Favorites to the Stack Exchange global inbox We're considering adding favorite notifications to the global inbox, and are looking for feedback on the idea (as we're not completely sold on it).  But first, some history.  Favorites are kind of like bookmarks, in that they're kept in a handy centralized place.  They also follow you across browsers.  Ok, ok... "bookmarks, on the internet" is not the most compelling feature, but Favorites also opted you into notices for those questions as if you were the owner (edits and new answers, at least).  This was probably the most confusing part (though a  feature) of the old envelope behavior judging by erroneous bug reports, so a way to opt out of this .  Now, favorite updates go nowhere.  But we could* put them into the inbox.  Here's how we envision this feature working:   Every current user has their "notify me on favorite changes" preference cleared (new users start with it cleared). The first time someone favorites a question, they're prompted to opt-in to favorite notices. Whenever a question is commented on or answered (or, possibly, edited) a new notice is pushed into the inbox of users who have favorited it, and have opted in.   Opt-in would be per-site, and it would remain possible to opt-out from your profile page.   This is not a final design, but the basic idea is correct  As I mentioned above, we're not 100% sold on this idea.  We've had a policy to date that nothing goes into the inbox that isn't specifically targeted at a user; this would be tweaking that policy.  *We could also put changes into their tab on the user page, but that reduces their visibility. When to use “that” and when to use “which”, especially in relative clauses When is it appropriate to use that as opposed to which with relative clauses? How to prove the midpoint of a chord is also the midpoint of the line segment defined by the points of intersection of other two chords with it? Bernhard Elsner, alias MathOMan, posted this exercise in plane Geometry,  on January $29$th, $2010.$  "Let $\mathcal{C}$ be a circle, $A,B$ two distinct points on $\mathcal{C}$ and $M$ be the midpoint of the chord $[AB]$. Take two other chords,$[PQ]$ and $[SR]$, that pass through $M$. Let $C$ (resp. $D$) be the intersection of $[AB]$ with $[PS]$ (resp. $[RQ]$). Prove that $M$ is the midpoint of the chord $[CD]$."    To prove it I've written the following (failed) argument, in the  of this post (translation of mine):    The figure is symmetric with respect to $M$: $\overline{AM}=\overline{MB}$, $\overline{PM}=\overline{MU}$, $\overline{RM}=\overline{MW}$, $\overline{QM}=\overline{MV}$, $\overline{QR}=\overline{VW}$, $\overline{SM}=\overline{MT}$. From $\dfrac{\overline{SC}}{\overline{DT}}=\dfrac{\overline{CM}}{\overline{MD}}=1$ follows that $\overline{CM}=\overline{MD}$.  Here is an extract of the author's reply (translation of mine):   "It is not clear that  $\overline{QM}=\overline{MV}$. Is the point $V$ on the line $(QM)$ defined by this equality or is $V$ defined as the intersection point of the lines $(QM)$ and $(WC)$? Why are both definitions to give the same point?  Let $C^{\prime }$ be the intersection of $(SP)$ and $(VW)$, and $D^{\prime }$ the intersection of $(TU)$ and $(QR)$. (...)  One still has to show that $C^{\prime }=C$ and $D^{\prime }=D$."   I have agreed with these objections.  Until now no proof has been posted. The author considers that the "proof is not quite simple".  Q. What is the theorem this exercise refers to? Or how does one prove it? Putting altered social media logo icons on my website, can I get sued? I would say most websites with a somewhat thought-through graphical design use social media icons (i.e Twitter, Facebook, YouTube, etc) which are altered to fit the theme and design of the site.  Now, my boss insist we only use the ones provided by say Facebook or Twitter themselves (in fear of getting sued or lose credibility), but sometimes it just doesn't look very good on the site.   What is the common practice for these things? What do you risk by using an altered logo? What should I tell my boss?  I'll provide a few examples, what'd happen if I put any of these on a site? How do I enumerate the properties of a JavaScript object? If one uses Shadow Evocation on a willing ally (e.g. Telekinetic Charge) can they choose not to disbelieve? Shadow Evocation  Nondamaging effects have normal effects except against those who disbelieve them. Against disbelievers, they have no effect.  Disbelief  Creatures encountering an illusion usually do not receive saving throws to recognize it as illusory until they study it carefully or interact with it in some fashion. A successful saving throw against an illusion reveals it to be false, but a figment or phantasm remains as a translucent outline. A failed saving throw indicates that a character fails to notice something is amiss. A character faced with proof that an illusion isn't real needs no saving throw. If any viewer successfully disbelieves an illusion and communicates this fact to others, each such viewer gains a saving throw with a +4 bonus.  (my emphasis) Voluntarily Giving up a Saving Throw  A creature can voluntarily forego a saving throw and willingly accept a spell's result. Even a character with a special resistance to magic can suppress this quality.  If I understand the above correctly,  If the ally believes the caster actually cast Telekinetic Charge, it seems they get a save which they could forgoe and so be guaranteed the benefit of the spell. &gt;&gt; We're good here. If the ally knows the caster didn't cast Telekinetic Charge, (say because of a high Spellcraft check or because she knows the caster's spell list) they have proof that the illusion isn't real and so need no saving throw. &gt;&gt; Even though she &quot;needs no saving throw&quot;, can she still choose to forego the save and be effected by the spell?  In other words, I think the question boils down to: Does one always have a choice not disbelieve an illusion, even when one has proof that it's not real?