# Sum of weighted binomial coefficients [duplicate]

I am struggling with computing the following sums:

$$\sum_{k=1}^{n}k\binom{n}{k}=\binom{n}{1}+2\binom{n}{2}+...+n\binom{n}{n}$$

and

$$\sum_{k=0}^{n}\frac{1}{k+1}\binom{n}{k}=\binom{n}{0}+\frac{1}{2}\binom{n}{1}+\frac{1}{3}\binom{n}{2}+\dots+\frac{1}{n+1}\binom{n}{n}$$

At first, I tried just rewriting the general terms in a form where the Binomial Theorem could be applied, but could not do so. ($k$ should be in the exponent of something with $n-k$ in the exponent of something else.)

Then, for the first sum, I re-wrote it in the following manner:

\begin{align} S &=\binom{n}{n}+\dots+\binom{n}{3}+\binom{n}{2}+\binom{n}{1}\\ &+\binom{n}{n}+\dots+\binom{n}{3}+\binom{n}{2}\\ &+\binom{n}{n}+\dots+\binom{n}{3}\\ &\quad\vdots\\ &+\binom{n}{n} \end{align}

Noting that:

$$\binom{n}{0}+\binom{n}{1}+\binom{n}{2}+\dots+\binom{n}{n}=\sum_{k=0}^{n}\binom{n}{k}1^k1^{n-k}=(1+1)^n=2^n,$$

I can rewrite the first line in $S$ as $2^n-1$ (the $-1$ is there because I'm over-counting the $\binom{n}{0}=1$).

Then I tried to say that if all the "blanks" were filled (if all the lines were like the first line), since there are $n$ lines, then I have $n(2^n-1)$. From this point, we should have:

$$S+\text{blanks}=n(2^n-1)\Longrightarrow S=n(2^n-1)-\text{blanks}$$

However, the problem of finding the value of "blanks" seems as hard as the original problem and I can't get to the right answer of $n2^{n-1}$ (according to WA). In one of my attempts, I ended up with a geometric series but that still didn't work.

I have not spent much time on the second sum as I feel I should be able to do the first one before even tackling the second one. Am I going in the right direction with this? Is there a more intelligent way of working this out?

Thanks in advance for any help/hints.

## marked as duplicate by N. F. Taussig combinatorics StackExchange.ready(function() { if (StackExchange.options.isMobile) return; $('.dupe-hammer-message-hover:not(.hover-bound)').each(function() { var$hover = $(this).addClass('hover-bound'),$msg = $hover.siblings('.dupe-hammer-message');$hover.hover( function() { $hover.showInfoMessage('', { messageElement:$msg.clone().show(), transient: false, position: { my: 'bottom left', at: 'top center', offsetTop: -7 }, dismissable: false, relativeToBody: true }); }, function() { StackExchange.helpers.removeMessages(); } ); }); }); Aug 11 '18 at 8:55

• You may just differentiate/integrate $\sum_{k=1}^{n}\binom{n}{k}x^k = (1+x)^n-1$. – Jack D'Aurizio Aug 11 '18 at 3:13
• Oh, I really should have thought of that. I tunnel-visioned myself into thinking this should be do-able with just basic counting tricks, not calculus. Thanks for the tip, I will try. – orion2112 Aug 11 '18 at 3:17
• It is doable with basic tricks, but the solution via $\frac{d}{dx},\int(\ldots)dx$ is a one-liner. – Jack D'Aurizio Aug 11 '18 at 3:26

One of my preferred methods of proof for these types of identities is to use a combinatorial proof which generally takes the form of describing a counting problem and finding the answer using two different methods thereby proving that the expressions achieved by each answer must be equal.

Suppose we have a committee of $n$ distinct people. We ask, in how many ways may we choose a subcommittee of any size where the subcommittee has one member designated as the leader (including the case of the leader being the only person on the subcommittee by himself)?

• Counting Method 1

Let us first break into cases based on the number of members on the committee. Since the committee must have a leader, the committee size must be at least $1$ and can be at most $n$. Let $k$ be the number of people on the subcommittee

Next, let us select all of the members of the subcommittee (including the leader). This can be done in $\binom{n}{k}$ ways.

Then, from those people selected, let us choose one of them to be the leader. This can be done in $k$ ways.

Applying multiplication principle and summing over all possible cases gives us the total number of subcommittees possible as being:

$$\sum\limits_{k=1}^nk\binom{n}{k}$$

• Counting Method 2

Let us before anything else select a person to serve as the leader for the subcommittee. This can be done in $n$ ways.

From the remaining $n-1$ people, let us choose some subset (possibly empty) to act as the followers in the subcommittee. This can be done in $2^{n-1}$ ways.

Applying multiplication principle, we arrive at a total number of subcommittees as being:

$$n2^{n-1}$$

We have as a result the identity:

$$\sum\limits_{k=1}^nk\binom{n}{k}=n2^{n-1}$$


1. ## Linear interpolation

Hello,

I need to find the pressure of steam at $98C^{o}$

however my steam table does not give a value for 98C, however does give a value for 95C and 100C,

I am told in order to find the pressure of steam at 98C I have interpolate from the tables,

I am not sure how to do this?

at 95C the pressure is 0.08453MPa
and at 100C the pressure is 0.1013MPa

and since 98C is not half way between, how would I interpolate?

is it $\frac{3}{5} ( 0.08453 + 0.1013) ?$ Multiplying by 3/5 as its 3 units away from 95 and after that another 5 units to 100C

Is this correct?

Thanks.

2. Your expression is incorrect. Find the equation of the line of pressure as a function of temperature. Then just plug in 98. What do you get?

3. Originally Posted by Ackbeet
Your expression is incorrect. Find the equation of the line of pressure as a function of temperature. Then just plug in 98. What do you get?

Okay, but I am not sure how to do that? I dont have any variables to work with?

Thank you.

4. Well, use P for pressure, and T for temperature. Then postulate that P = m T + b. Plug in two data points where you know both P and T in order to get two equations. Use those two equations to solve for m and b. Then plug in T = 98. How does that sound?

5. Thanks I get it, I got 0.093182, which seems about right, as it should be higher than the pressure at 95 but lower than the pressure for 100C.

6. Great. And the value is closer to the 100C value than the 95C value, right?

7. (3/5) of the way from a to b is NOT (3/5)(a+ b). The distance from a to b is b- a and 3/5 of that is (3/5)(a- b). Now add that to b: b+ (3/5)(a- b)= (3/5)a+ (2/5)b. (notice that 2+ 3= 5)

8. $\begin{array}{ccc}\mbox{Temp(T)} & \mbox{Pressure(P)} & \Delta \\ 95 &0.08453 & \mbox{ } \\ \mbox{ } & \mbox{ } & 0.01677 \\ 100 & 0.1013 & \mbox{ } \end{array}$

$P(98) \approx 0.08453 + (3/5)0.01677 = 0.09460$

9. Both ways give a different answer, which one is more accurate? And can you please explain why you add the value of 'b' ?

10. The two methods are equivalent. If, instead of the numerical values, you call the pressure at 95, $a$, and the pressure at 100, $b$, then, using my notation, $\Delta =b-a$.
Then,

$P(98)\approx a + (3/5)(b-a) = (2/5)a+(3/5)b,$

(and now substituting the numbers),

$=(2/5)0.08453+(3/5)0.1013=0.094592.$

11. Hello, Tweety!

$\text{At }95^oC\text{ the pressure is 0.08453 MPa}$
$\text{and at }100^oC\text{ the pressure is 0.1013 MPa.}$

$\text{Use linear interpolation to find the pressure at }98^oC.$

We are given two points: . $(95,\,0.08453)\,\text{ and }\,(100,\,0.1013)$

Find the equation of the line through those two points.

. . The slope is: . $m \:=\:\frac{0.1013 - 0.08453}{100-95} \:=\:\frac{0.01677}{5} \:=\:0.003354$

. . Then: . $y - 0.08453 \:=\:0.003354(x - 95)$

. . The equation of the line is: . $y \:=\:0.003354x - 0.2341$

If $x = 95\text{, then: }\:y \:=\:0.003354(95) - 0.2341 \:=\:0.094592$


rat

Rational fraction approximation

Syntax

• ```[N,D] = rat(___)``` example

Description

example

````R = rat(X)` returns the rational fraction approximation of `X` to within the default tolerance, `1e-6*norm(X(:),1)`. The approximation is a string containing the truncated continued fractional expansion.```

example

````R = rat(X,tol)` approximates `X` to within the tolerance, `tol`.```

example

``````[N,D] = rat(___)``` returns two arrays, `N` and `D`, such that `N./D` approximates `X`, using any of the above syntaxes.```

Examples

collapse all

Approximate Value of π

Approximate the value of π using a rational representation of the quantity `pi`.

The mathematical quantity π is not a rational number, but the quantity `pi` that approximates it is a rational number since all floating-point numbers are rational.

Find the rational representation of `pi`.

```format rat pi ```
```ans = 355/113 ```

The resulting expression is a string. You also can use `rats(pi)` to get the same answer.

Use `rat` to see the continued fractional expansion of `pi`.

`R = rat(pi)`
```R = 3 + 1/(7 + 1/(16)) ```

The resulting string is an approximation by continued fractional expansion. If you consider the first two terms of the expansion, you get the approximation $3+\frac{1}{7}=\frac{22}{7}$, which only agrees with `pi` to 2 decimals.

However, if you consider all three terms printed by `rat`, you can recover the value `355/113`, which agrees with `pi` to 6 decimals.

$3+\frac{1}{7+\frac{1}{16}}=\frac{355}{113}\text{\hspace{0.17em}}.$

Specify a tolerance for additional accuracy in the approximation.

```R = rat(pi,1e-7) ```
```R = 3 + 1/(7 + 1/(16 + 1/(-294))) ```

The resulting approximation, `104348/33215`, agrees with `pi` to 9 decimals.

Express Array Elements as Ratios

Create a 4-by-4 matrix.

```format short; X = hilb(4)```
```X = 1.0000 0.5000 0.3333 0.2500 0.5000 0.3333 0.2500 0.2000 0.3333 0.2500 0.2000 0.1667 0.2500 0.2000 0.1667 0.1429```

Express the elements of `X` as ratios of small integers using `rat`.

`[N,D] = rat(X)`
```N = 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 D = 1 2 3 4 2 3 4 5 3 4 5 6 4 5 6 7```

The two matrices, `N` and `D`, approximate `X` with `N./D`.

View the elements of `X` as ratios using ```format rat```.

```format rat X```
```X = 1 1/2 1/3 1/4 1/2 1/3 1/4 1/5 1/3 1/4 1/5 1/6 1/4 1/5 1/6 1/7 ```

In this form, it is clear that `N` contains the numerators of each fraction and `D` contains the denominators.

Input Arguments

collapse all

`X` — Input arraynumeric array

Input array, specified as a numeric array of class `single` or `double`.

Data Types: `single` | `double`
Complex Number Support: Yes

`tol` — Tolerancescalar

Tolerance, specified as a scalar. `N` and `D` approximate `X`, such that `N./D - X < tol`. The default tolerance is `1e-6*norm(X(:),1)`.

Output Arguments

collapse all

`R` — Continued fractionstring

Continued fraction, returned as a string. The accuracy of the rational approximation via continued fractions increases with the number of terms.

`N` — Numeratornumeric array

Numerator, returned as a numeric array. `N./D` approximates `X`.

`D` — Denominatornumeric array

Denominator, returned as a numeric array. `N./D` approximates `X`.

collapse all

Algorithms

Even though all floating-point numbers are rational numbers, it is sometimes desirable to approximate them by simple rational numbers, which are fractions whose numerator and denominator are small integers. Rational approximations are generated by truncating continued fraction expansions.

The `rat` function approximates each element of `X` by a continued fraction of the form

$\frac{N}{D}={D}_{1}+\frac{1}{{D}_{2}+\frac{1}{\left({D}_{3}+...+\frac{1}{{D}_{k}}\right)}}\text{\hspace{0.17em}}.$

The Ds are obtained by repeatedly picking off the integer part and then taking the reciprocal of the fractional part. The accuracy of the approximation increases exponentially with the number of terms and is worst when `X = sqrt(2)`. For `X = sqrt(2)` , the error with `k` terms is about `2.68*(.173)^k`, so each additional term increases the accuracy by less than one decimal digit. It takes 21 terms to get full floating-point accuracy.


# Can asymptotes be curved?

When I was first introduced to the idea of an asymptote, I was taught about horizontal asymptotes (of form $y=a$) and vertical ones ( of form $x=b$).

I was then shown oblique asymptotes-- slanted asymptotes which are not constant (of the form $y=ax+b$).

What happens, though, if we've got a function such as $$f(x)=e^x+\frac{1}{x}?$$

Is $y=e^x$ considered an asymptote in this example?

Another example, just to show you where I'm coming from, is $$g(x)=x^2+\sin(x)$$-- is $y=x^2$ an asymptote in this case?

The reason that I ask is that I don't really see the point in defining oblique asymptotes and not curved ones; surely, if we want to know the behaviour of $y$ as $x \to \infty$, we should include all types of functions as asymptotes.

If asymptotes cannot be curves, then why arbitrarily restrict asymptotes to lines?

-
Of course you can. There's, e.g., the notion of polynomial branch, parabolic branch, etc. but then they might not be called asymptotes. –  gniourf_gniourf Jun 28 '14 at 21:32
–  David H Jun 28 '14 at 21:40
In a way, the notion of asymptotic analysis generalizes the concept of line asymptotes. This site has an asymptotics tag. –  Antonio Vargas Jun 28 '14 at 21:45
I would think that a Taylor series expansion is a pretty good example of a general-purpose usage of a curved line for an asymptote. –  fluffy Jun 29 '14 at 1:23

The concept of asymptotes is quite common for curved graphs, although somehow the terminology is not much used outside of the context of lines. The way in which the concept is used is that if one is given a function $f(x)$, it is interesting to study other functions $g(x)$ that are "asymptotic to $f(x)$" in various ways. One meaning of this phrase would be that $$(1) \quad \lim_{x \to +\infty} |f(x)-g(x)|=0$$ which is exactly what "asymptotic" means in the ordinary sense when the graph of $f(x)$ is a line. Another somewhat different notion is that $$(2) \quad \lim_{x \to +\infty} \frac{f(x)}{g(x)} = 1$$ which only really makes sense when $f(x)$ and $g(x)$ are nonzero near $+\infty$. There are many other variations on this concept. This discussion falls under the name of "growth types of functions", which are important in computer science and other places; these notes look like a good basic discussion, for example.

And regarding your question of whether $g(x) = x^2 + \sin(x)$ is asymptotic to $y=x^2$, it is asymptotic in sense (2) but not in sense (1).

-

"Asymptote," in my view, essentially refers to some kind of limiting behavior of a function. So for instance, we talk about asymptotic series expansions. So from an analytic geometry perspective, we might think of an "asymptote" as a function or relation that describes how another function approaches it arbitrarily closely. For example, $$f(x) = \frac{x-x^2+x^4}{x^2-1}$$ might be thought of as having a parabolic asymptote and two vertical asymptotes, since for "large" $x$, $f(x) \sim x^2$. But I hesitate to say $f(x) = x^2 + \sin x$ has such an asymptote, because the magnitude of $\sin x$ does not diminish as $x$ gets large.

-
Though it is still true that $x^2 + \sin x \sim x^2$ as $x \to \infty$ in the usual sense of $\sim$. –  Antonio Vargas Jun 28 '14 at 21:48
Yes, of course. –  heropup Jun 28 '14 at 21:50
@heropup Is it the fact that $\sin(x)$ oscillates for large $x$ that means that $y=x^2$ wouldn't be considered an asymptote in my case, or is it the fact that $\sin(x)$ doesn't decay to zero? –  alexqwx Jun 28 '14 at 21:54
What about $x^2 + \frac{\sin x}{x}$? Would you say that had an asymptote in the same way that the first function you gave had horizontal/vertical asymptotes? –  Zubin Mukerjee Jun 28 '14 at 22:18
@ZubinMukerjee In that $\frac{\sin{x}}{x} \rightarrow 0$, yes. –  ClickRick Jun 29 '14 at 3:29

terminology is up to you. However, it is useful, when graphing rational functions, to realize that they are essentially polynomial (or the reciprocal of a polynomial) for large absolute values of the argument. Graph $$y = \frac{x^5 - 7}{x^3 - 12 x},$$ for large $|x|,$ $y$ is pretty much $x^2.$

-
I was sad because I had no readily available computer graphing software. Then I met a man who had no fish. –  Will Jagy Jun 28 '14 at 21:52


# Is there an algebraic proof for $\sum_{m=k}^{n-k} \binom{m}{k}\binom{n-m}{k} = \binom{n+1}{2k+1}, n\ge2k\ge0$

$\sum_{m=k}^{n-k} \binom{m}{k}\binom{n-m}{k} = \binom{n+1}{2k+1}, n\ge2k\ge0$

An combinatorial proof of the identity above states as follow:

(1)Number of ways of picking (2k+1) numbers from 1 to (n+1) should be $\binom{n+1}{2k+1}$

(2)We pick (2k+1) numbers from 1 to (n+1) with median value (m+1). Then, k numbers must be selected from 1~m, and the other k numbers must be chosen from (m+2)~(n+1). Thus there are $\binom{m}{k}\binom{n-m}{k}$ ways for picking (2k+1) numbers with median value (m+1). Since $n-k\ge m\ge k$, there are total $\sum_{m=k}^{n-k} \binom{m}{k}\binom{n-m}{k}$ ways.

Since (1)=(2), the statement is true. But is it possible to sketch an algebraic proof that doesn't require building combinatorial models?

• Consider coefficient of $x^{n}$ in $[x^k(1-x)^{k+1}][x^k(1-x)^{k+1}]$. – Lord Shark the Unknown Jan 1 '18 at 11:22

Here is an algebraic proof based upon generating functions. It is convenient to use the coefficient of operator $[z^n]$ to denote the coefficient of $z^n$ in a series. This way we can write for instance \begin{align*} [z^k](1+z)^n=\binom{n}{k} \end{align*}

We obtain \begin{align*} \color{blue}{\sum_{m=k}^{n-k}}&\color{blue}{\binom{m}{k}\binom{n-m}{k}}\\ &=\sum_{m=0}^{n-2k}\binom{m+k}{m}\binom{n-m-k}{k}\tag{1}\\ &=\sum_{m=0}^{n-2k}\binom{-k-1}{m}(-1)^m\binom{n-m-k}{k}\tag{2}\\ &=\sum_{m=0}^\infty[z^m](1-z)^{-k-1}[u^k](1+u)^{n-m-k}\tag{3}\\ &=[u^k](1+u)^{n-k}\sum_{m=0}^\infty\left(\frac{1}{1+u}\right)^{m}[z^m](1-z)^{-k-1}\tag{4}\\ &=[u^k](1+u)^{n-k}\left(1-\frac{1}{1+u}\right)^{-k-1}\tag{5}\\ &=[u^k](1+u)^{n-k}u^{-k-1}(1+u)^{k+1}\tag{6}\\ &=[u^{2k+1}](1+u)^{n+1}\tag{7}\\ &\color{blue}{=\binom{n+1}{2k+1}}\tag{8} \end{align*} and the claim follows.

Comment:

• In (1) we shift the index to start with $m=0$ and use the binomial identity $\binom{p}{q}=\binom{p}{p-q}$.

• In (2) we use the binomial identity $\binom{-p}{q}=\binom{p+q-1}{q}(-1)^q$.

• In (3) we apply the coefficient of operator twice and we set the upper bound of the series to $\infty$ without changing anything since we are adding zeros only.

• In (4) we use the linearity of the coefficient of operator and we apply the rule $[z^{p-q}]A(z)=[z^p]z^qA(z)$.

• In (5) we apply the substitution rule of the coefficient of operator with $z=\frac{1}{1+u}$
\begin{align*} A(u)=\sum_{m=0}^\infty a_m u^m=\sum_{m=0}^\infty u^m [z^m]A(z) \end{align*}

• In (6) we do some simplifications.

• In (7) we do some more simplifications and apply the same rule as we did in (4).

• In (8) we select the coefficient of $u^{2k+1}$.

More generally:

Theorem 1. For every nonnegative integers $$x$$, $$y$$ and $$n$$, we have $$$$\dbinom{n+1}{x+y+1}=\sum_{m=0}^{n}\dbinom{m}{x}\dbinom{n-m}{y}.$$$$

This equality rewrites as $$$$\dbinom{n+1}{x+y+1} = \sum_{m=x}^{n-y} \dbinom{m}{x}\dbinom{n-m}{y} ,$$$$ because all addends $$\dbinom{m}{x}\dbinom{n-m}{y}$$ are zero except for those where $$x \leq m \leq n-y$$.

Your identity is the particular case of the latter equality for $$x = k$$ and $$y = k$$.

Your nice bijective proof of the original identity can easily be generalized to a proof of Theorem 1; just count all ways of picking an $$\left(x+y+1\right)$$-element subset of $$\left\{1,2,\ldots,n+1\right\}$$ according to the value of the $$\left(x+1\right)$$-th-lowest element of the subset. Indeed, for any given $$m \in \left\{0,1,\ldots,n\right\}$$, picking an $$\left(x+y+1\right)$$-element subset $$S$$ of $$\left\{1,2,\ldots,n+1\right\}$$ whose $$\left(x+1\right)$$-th-lowest element is $$m+1$$ is tantamount to picking an $$x$$-element subset of $$\left\{1,2,\ldots,m\right\}$$ (which will contain the $$x$$ elements of $$S$$ lower than $$m+1$$) and picking a $$y$$-element subset of $$\left\{m+2,m+3,\ldots,n+1\right\}$$ (which will contain the $$y$$ elements of $$S$$ higher than $$m+1$$). This gives $$\dbinom{m}{x}\dbinom{n-m}{y}$$ for the number of choices.

As for other proofs:


# Combinatorial proof of binomial coefficient summation

While doing some Computer Science problems, I found one which I thought could be solvable using combinatorics instead of programming:

Given two positive integers $n$ and $k$, in how many ways do $k$ numbers, all of which are between $0$ and $n$ (inclusive), add up to $n$?

In the problem, order does matter. For example, 0+20 is not equivalent to 20+0. This led me to the following solution:

Assume you do want to create the sum without any of the terms being zero. Then, the problem can be looked at as if you have $n$ rocks, and you want know the number of ways you can place $k-1$ sticks between them, such that no stick may be placed between the same two rocks. This is obviously equal to $\binom{n-1}{k-1}$.

If you then want to count the number of ways you can create the sum with exactly one of the terms being zero. Then the solution is (number of ways to get to $n$ using $k-1$ non-zero terms)*(the number of ways we can choose 1 element among k). Then, when wanting to count the number of ways with exactly $x$ zeroes, the answer is (number of ways to get to n using $k-x$ non-zero terms)*(the number of ways we can choose $x$ elements among $k$).

The solution to the original problem will basically the sum of the above expression, with x ranging between $0$ and $k-1$ (since there needs to be at least 1 non-zero term).

This leads to $\displaystyle\sum_{i=0}^{k-1}\left[ \binom{n-1}{k-i-1}\binom{k}{i}\right]$

I later went on to search on Google if there existed any simpler solution, and found that $\binom{n+k-1}{n}$ worked as well, but without explanation and proof.

Both solutions give the same answer for any positive $n$ and $k$, but I really have trouble understanding why. I've tried to simplify my summation, and proving it inductively, but I have not been successful.

Could somebody help me prove the equality?

$\binom{n+k-1}{n} = \displaystyle\sum_{i=0}^{k-1}\left[ \binom{n-1}{k-i-1}\binom{k}{i}\right]$

• Hint: Find instead the number of ways of dividing $n+k$ into $k$ parts, all $\ge 1$. – André Nicolas Jul 23 '11 at 14:32
• That was a really nice solution too, and a bit more mathematical I suppose. :-) – Johan Sannemo Jul 23 '11 at 14:53
• Very related... – J. M. is a poor mathematician Jul 23 '11 at 14:59
• Your final equation is an example of Vandermonde's identity en.wikipedia.org/wiki/Vandermonde%27s_identity – user940 Jul 23 '11 at 15:00
• @Byron - cool, even an algebraic proof there! – Johan Sannemo Jul 23 '11 at 15:07

There is no need to break into cases concerning the existence of piles of "0 rocks". A pile of zero rocks can be represented by having two "sticks" between the same two rocks (between those two sticks there are zero rocks!). Indeed, I can represent any number of consecutive piles of zero rocks by having the appropriate number of sticks between the same two rocks.

So, with that in mind, I am really looking to count the number of ways that I can place $k-1$ sticks among $n$ rocks. (By the way, why does this representation still retain the ordering? Try finding sticks and rocks representations of $0 + 20$ and $20 + 0$, and other combinations.) Now, this is equivalent to choosing from $n + k - 1$ objects, exactly $n$ of them to be our "rocks" (leaving the other $k-1$ to be our "sticks"). And there are $\binom{n+k-1}{n}$ ways to do that.

Hope this helps!

• By the way, your piecewise identity can be written as a single formula! What happens when $n = 1$? In the summation, there is a binomial coefficient with $n-1 = 0$ on the top, which evaluates to $0$ unless the bottom is also $0$ (in which case, $\binom{0}{0} = 1$), which occurs only when $k - i - 1 = 0$, or $i = k-1$. But then the second factor would be $\binom{k}{i} = \binom{k}{k-1} = k$. The sum is exactly equal to $k$ when $n = 1$. – Shaun Ault Jul 23 '11 at 14:48
• Ah, of course! Makes sense now that you say it. Thanks! – Johan Sannemo Jul 23 '11 at 14:49
• Yeah, of course 0 choose 0 = 1. Silly me. – Johan Sannemo Jul 23 '11 at 14:52

Taking your rocks and sticks example, your basic question is how many ways are there to place $n$ rocks and $k-1$ sticks in order as each pattern (of the rocks) is one solution to your problem. This is ${n+k-1 \choose n}$.

If $n=1$ then all your discussion of $i$ zero terms will come out at $0$ except when $i=k-1$ and in that case you will have $\left[ \binom{0}{0}\binom{k}{k-1}\right] = k$, so you do not need to distinguish $n=1$ in your expression.


# Permuting elements of a set around a circle

Given $15$ objects placed around a circle, is it possible to permute their order such that the distance between any two elements is different in the second permutation from that in the original state?

-
Are the 15 positions on the circle necessarily uniformly spaced? – Henning Makholm Jan 18 '13 at 1:13
@joriki: I haven't tried very hard to understand your code, but what is wrong with 5 objects and (0 2 4 1 3)? (Or in general any prime number $p\ge 5$ of objects and doubling positions modulo $p$, or even more generally $q$ objects and multiplying positions by $k$ modulo $q$ where $\{k-1,k,k+1\}$ are each coprime with $q$ (which requires that $q$ is not a multiple of $3$))? – Henning Makholm Jan 18 '13 at 1:23
My own computer search confirms that there is no solution for $n=15$, and quickly finds a number of solutions for $n=11$, including 1 3 5 7 9 11 2 4 6 8 10, and many solutions for $n=13$, such as 1 3 10 6 11 5 12 4 13 7 9 2 8. I will make the code available if anyone cares. – MJD Jan 18 '13 at 1:35
You're right, there was a bug in my code. I've fixed it, and am now getting the same results as @MJD. I'll delete my first comment since it might mislead if people don't read further. – joriki Jan 18 '13 at 1:42
@AlexanderGruber gist.github.com/4561589 ; please feel free to email me if you want to discuss anything. – MJD Jan 18 '13 at 2:07

OEIS notes that this is closely related to the problem of whether there is a solution to the toroidal $N$ queens problem, which is the problem of arranging $N$ chess queens on an $N\times N$ chessboard so that none attacks another, where the opposite pairs of edges of the board are identified. It refers to The Cyclic Complete Mappings Counting Problems, Hsiang, Shieh, and Chen, 2002. Theorem 2 on page 6 of that paper states: $$TQ(n) = 0 \text{ if and only if } 2 | n \text{ or } 3 | n.$$

$TQ(n)$ is the number of solutions to the toroidal $N$-queens problem, and is easily seen to be equal to $n\cdot A(n)$, where $A(n)$ is the number of solutions to the circle arranging problem we are solving. In particular, $TQ(15) = 0$, so $A(15) = 0$.

Unfortunately, the paper does not provide a proof. However, as Joriki notes in the comments, the theorem is due to Pólya, probably in Über die 'doppelt-periodischen' Lösungen des $n$-Damen-Problems, Mathematische Unterhaltungen und Spiele., (1918), pp. 364–374; according to Wikipedia, this appears in George Pólya: Collected papers Vol. IV, G-C. Rota, ed., MIT Press, Cambridge, London, 1984, pp. 237–247. Web search for "toroidal $n$-queens" may produce something more immediately useful.

Mathworld cites Vardi, I. "The $n$-Queens Problems." Ch. 6 in Computational Recreations in Mathematica. Redwood City, CA: Addison-Wesley, pp. 107–125, 1991.

-
Very nice, problem solved. – joriki Jan 18 '13 at 2:00
Under other circumstances I might have made this a CW post, since I didn't solve the problem myself, but in this case the research effort was significant, and I feel that I have added some value. – MJD Jan 18 '13 at 2:01
@joriki Don't you have an OEIS account? If so, you might let them know that their hyperlink to the Hsiang paper is no good, and that they should replace it with the CiteSeer link I provided. – MJD Jan 18 '13 at 2:04
"and I feel that I have added some value" -- You did. It would have been very difficult to find this connection without writing the code to determine the numbers up to $A(13)=348$. By the way the related OEIS entry A007705 gives a reference from $1921$ and says that Polya proved the result that $TQ(n)\ne0$ if and only if $n$ is coprime to $6$. – joriki Jan 18 '13 at 2:05

This sci.math post says that the literature contains several independent proofs of the result that the toroidal $n$-queens problem has a solution iff $\gcd(n,6)=1$ and gives six references. I have access to one of them, Torleiv Kløve, The modular $n$-queens problem, in Discrete Mathematics 19 (1977), 289-91. The proof there is short enough to be worth typing out here.

We want a function $f:\Bbb Z/n\Bbb Z\to\Bbb Z/n\Bbb Z$ such that $f$, $f+\mathrm{id}_{\Bbb Z/n\Bbb Z}$, and $f-\mathrm{id}_{\Bbb Z/n\Bbb Z}$ are all injections. The theorem is that such an $f$ exists iff $\gcd(n,6)=1$.

Proof. Suppose that $f$ is such a function, and let

$$S=\sum_{k\in\Bbb Z/n\Bbb Z}k^2\quad\text{and}\quad T=\sum_{k\in\Bbb Z/n\Bbb Z}kf(k)\;.$$

Then $\displaystyle\sum_{k\in\Bbb Z/n\Bbb Z}f(k)^2=S$, since $f$ is injective. Since $f+\mathrm{id}_{\Bbb Z/n\Bbb Z}$ and $f-\mathrm{id}_{\Bbb Z/n\Bbb Z}$ are also injective,

$$S=\sum_{k\in\Bbb Z/n\Bbb Z}\big(f(k)\pm k\big)^2=\sum_{k\in\Bbb Z/n\Bbb Z}f(k)^2\pm 2\sum_{k\in\Bbb Z/n\Bbb Z}kf(k)+\sum_{k\in\Bbb Z/n\Bbb Z}k^2=2S\pm 2T\;,$$

$2S=4S$, and $2S=0$ in $\Bbb Z/n\Bbb Z$. In $\Bbb Z$, therefore, we have

$$2\sum_{k=0}^{n-1}k^2=\frac{n(n-1)(2n-1)}3\equiv 0\pmod n$$

and hence $\gcd(n,3)=1$.

He now appeals to N.J. Fine’s solution of problem E 1699 (Amer. Math. Monthly 72 (1965), 552-3). Specialized to the present setting, the argument (which may have given Kløve the idea for his proof) is that

$$\sum_{k\in\Bbb Z/n\Bbb Z}\big(f(k)+k\big)=2\sum_{k\in\Bbb Z/n\Bbb Z}k$$

in $\Bbb Z/n\Bbb Z$, but if $n$ is even, then $$\sum_{k=0}^{n-1}k=\frac{n(n-1)}2\equiv-\frac{n}2\equiv\frac{n}2\pmod n\;,$$

so in $\Bbb Z/n\Bbb Z$ we have $$\sum_{k\in\Bbb Z/n\Bbb Z}\big(f(k)+k\big)=2\cdot\frac{n}2=0\ne\sum_{k\in\Bbb Z/n\Bbb Z}k\;,$$ and $f+\mathrm{id}_{\Bbb Z/n\Bbb Z}$ cannot be injective. Thus, $n$ must be odd, and $\gcd(n,6)=1$.

Conversely, if $\gcd(n,6)=1$, then $f(k)=2k$ is a solution. $\dashv$

-


# Cardinality Question

1. Sep 9, 2007

### MrJB

I'm fairly sure that the intervals (0,1) and [0,1] of real numbers have the same cardinality, but I can't think of a bijection between them. Any thoughts?

2. Sep 9, 2007

### Hurkyl

Staff Emeritus

Can you find a bijection between the set of all nonnegative integers and the set of all positive integers?

Once you've answered that, can you think of a way to apply this very example to your problem? Or at least this technique?

3. Sep 9, 2007

### MrJB

Well, for the warm-up, I'd define f(n)=n+1 as my map from the set of nonnegative integers to the set of positive integers. Thus, 0,1,2... would get mapped to 1,2,3... etc.
I don't see the connection to my problem though.

4. Sep 9, 2007

### morphism

I'm wondering why you want to find a bijection. Very rarely does one produce an explicit bijection to show that two sets have the same cardinality. One of the main tools is the Shroeder-Bernstein theorem: it says that if you have an injection from A into B and an injection from B into A, then there exists a bijection between A and B (note: this is an existence result; it doesn't tell us how to construct the bijection). You can apply it to your problem.

In regards to Hurkyl's hint, try using this to find a bijection between [0,1] and (0,1], for example.

5. Sep 9, 2007

### MrJB

I was just curious what such a bijection might look like.

In regards to the Schroeder-Bernstein Theorem, the injection from (0,1) into [0,1] is obvious, and the injection from [0,1] into (0,1) I can define as f(x)=x/2+1/4. So there is a bijection between them.

I'm still lost on Hurkyl's hint. With the integers, my map just moved all the elements to the next integer, but with the reals there is no 'next' real.

6. Sep 9, 2007

### morphism

How about, say, the sets {1/n : n a positive integer} and {1/n : n a nonnegative integer} in [0,1]?

7. Sep 9, 2007

### Hurkyl

Staff Emeritus
What this tells you is that, if you're given a countable set, you know how to make an individual point "appear" or "disappear".

Now, if you could find a countable subset of [0, 1], then you know how to make a point of that subset disappear...

8. Sep 9, 2007

### MrJB

I think I can work with that...

So my map would take the set {1/n : n a positive integer} to {1/(n+1) : n a positive integer}. That is, 1,1/2,1/3... would map to 1/2,1/3,1/4... and the rest of the reals would map to themselves, thus defining a bijection from [0,1] to [0,1). Then I would repeat a similar technique to the other side.

Thanks.

9. Sep 9, 2007

### Hurkyl

Staff Emeritus
Yep. That is the basic technique for "removing" individual points from an infinite set. The core idea works in a wide variety of situations.

10. Sep 9, 2007

### MrJB

Awesome.
You could use the same idea to 'remove' infinite sets of points too? If I wanted to map the closed unit disc to the open unit disc, I would map the sets of points with distances from the origin 1,1/2,1/3 to the sets of points with distances 1/2,1/3,1/4 from the origin?

11. Sep 10, 2007

### Hurkyl

Staff Emeritus
That certainly seems to work!

12. Sep 10, 2007

### fopc

Thoughts on an example construction of f:[0,1] -> (0,1) that's bijective. (There are many such f's.)

1. The sets differ only at two points, 0 and 1.
2. Must find images for 0 and 1 somewhere in (0,1) while still keeping f bijective.
3. Let A={0,1,1/2,1/3,...,1/n,...}. (Something like this has already been suggested.)
4. Send 0 to 1/2, and 1 to 1/3.
5. This can be effected by, f(0)=1/2, f(1/n)= 1/(n+2) for n >= 1.

6. Then complete the definition of f by, f(x)=? for all x in ?

The final step is to actually verify that f is bijective.

Typically, it's easier to find two injections than one bijection.
This example brings the point out a little bit.
So yes, in many cases Schroeder-Bernstein has considerable practical value.
But, it's greatest value is theoretical, not practical.
I'd say there's something to be learned by actually constructing an f (like the one above), and demonstrating that's it's bijective.

EDIT: I'll complete the definition of f.
f(x)=x for all x in [0,1]-A. (Obviously there was a reason for A.)

Last edited: Sep 10, 2007
13. Sep 10, 2007

### HallsofIvy

Staff Emeritus
Try this: irrational numbers between 0 and 1 map into themselves.

The rational numbers between 0 and 1 are countable so the can be written in a list:
$r_1, r_2, r_3, \cdot\cdot\cdot$. Now map $r_1\rightarrow 0$, $r_2/rightarrow 1$, $r_3\right arrow r_1$, $r_4\rightarrow r_2$,$\cdot\cdot\cdot$, $r_n\rightarrow r_{n-2}$.

14. Sep 20, 2007

### grossgermany

Still why would this be bijective? How do you know that step A 1/n->1/(n+1)
and step B f(x)=x for all x in [0,1] won't end up in the same number.
I know intuitively it makes sense, but it doesn't seem very mathematically rigorous.

15. Sep 21, 2007

### fopc

I suspect you didn't read the EDIT.
It reads, f(x) = x for all x in [0,1]-A.

Not mathematically rigorous?
Well, I defined an f, and made a claim that f is a bijection; nothing more. I then suggested the need to demonstrate this by showing f is injective and surjective. There's hidden value here. It forces you to think about definitions.

You question that f is bijective (in particular you seem to doubt that it's injective). Well?

Finally, I apologize to Ernst. It should be Schröder.


# Associativity and De Morgan's for more than 2 literals

Do logical operators have meaning when used with more than 2 literals "associatively", e.g.: $(A \land B \land C)$?

I.e., are statements such as $(A \land B \land C)$ meaningful, as opposed to $((A \land B) \land C)$, which is meaningful?

If yes, is it possible to prove De Morgan's for any finite n by induction like so:

1. For $n = 2$, base De Morgan's applies: $\neg(A_{1} \lor A_{2}) \Leftrightarrow \neg A_{1} \land \neg A_{2}$.
2. Assume that for $n = k$, $\neg (A_{1}\lor A_{2}\lor \ldots \lor A_{k}) \Leftrightarrow (\neg A_{1}\land \neg A_{2} \land \ldots \land \neg A_{k})$.
3. Then for $n = k + 1$: $\neg (A_{1}\lor A_{2}\lor \ldots \lor A_{k} \lor A_{k+1}) \Leftrightarrow \neg ((A_{1}\lor A_{2}\lor \ldots \lor A_{k})\lor A_{k+1})\Leftrightarrow \neg (A_{1}\lor A_{2}\lor \ldots \lor A_{k}) \land \neg A_{k+1} \Leftrightarrow \neg A_{1} \land \neg A_{2} \land \ldots \land \neg A_{k} \land \neg A_{k+1}$
4. Therefore, $\neg (A_{1}\lor A_{2}\lor \ldots \lor A_{n}) \Leftrightarrow (\neg A_{1}\land \neg A_{2} \land \ldots \land \neg A_{n})$ is true for any finite n.

?

Thank you.

• Yes; $(A∧B∧C)$ is an abbreviation for $(A∧(B∧C))$ or, equivalently : $((A∧B)∧C))$, as your proof shows. Jan 17 '15 at 10:15
• No, take a look at the formation rules. Also, the rule of uniform substitution would fail if (A∧B∧C) were meaningful. Jan 17 '15 at 19:25
• @DougSpoonwood Could you please elaborate on that? Thank you. Jan 19 '15 at 3:12
• @DougSpoonwood I feel like it even though it is formally incorrect to use that kind of notation, it is still meaningful intuitively. For example, for both $\land$ and $\lor$ the truth table of an expression consisting of $n$ literals and $n-1$ operators of one kind is the same whatever the placement of parentheses is (out of $2^n$ possible variants). Therefore, the notation in this case is logically insignificant. Jan 19 '15 at 3:35
• No, it's logically significant, because if (A∧B∧C) is an expression, than the rule of uniform substitution fails. The rule of uniform substitution is important for having an axiomatic system of propositional logic. If say A∧B is meaningful (which you implied), and we have the rule of uniform substitution, then substituting B with CvD we obtain A∧CvD. Suppose A=0, C=0, D=1. Then [A∧(CvD)]=0, while [(A∧C)vD]=1. So, I started with an expression assumed as meaningful and deduced a contradiction, which renders either the expression or the rule of uniform substitution as not meaningful. Jan 19 '15 at 3:57

Certainly $\land$ and $\lor$ can be used meaningfully in this way. This is because we can prove (e.g. by truth tables, a straightforward exercise) that they are associative, i.e.:

$$A \land (B \land C) \iff (A \land B) \land C \qquad A \lor (B \lor C) \iff (A \lor B) \lor C$$

so that we can argue that it doesn't really matter whether we use parentheses or not. From there on, you have given a proper proof that De Morgan's laws generalise to these expressions.

Do note, however, that this does not apply to every logical operator out there. This question deals with associativity of $\to$; it is shown not to be associative:

$$A \to (B \to C) \not\iff (A \to B) \to C$$

• You can only use ∧ and ∨ in this way, if we have a system where the only binary expression is either ∧ or ∨ (but you can't have both around). Associativity only ensures that such expressions are meaningful when we have a pure semigroup. If we have two associative operations around, such as the two-valued logical operations "∧" and "∨", then an expression like A∧B∨C can be ambiguous. It's not associativity which makes such work, but rather that for any binary operations B$_1$, B$_2$, for all x, y, z, ((xB$_1$y)B$_2$z)=(xB$_1$(yB$_2$z)). Associativity is a special case of that. Jan 19 '15 at 4:03
• This answer combined with Doug Spoonwood's note that the only logical operator used should be ($\land$ XOR $\lor$) answers my question completely. Jan 19 '15 at 5:19
• @Doug Nowhere did I imply that expressions combining $\lor$ and $\land$ without parentheses are meaningful. Jan 19 '15 at 6:07

No. For example, (A$\land$B$\lor$C) is not meaningful, even though both $\land$ and $\lor$ associate.

If we have that for any binary operations B1, B2, for all x, y, z, ((xB1y)B2z)=(xB1(yB2z)), then we can drop parentheses as you've suggested. Thus, if we just have a semigroup, then we can drop all parentheses. But, if we have more than one binary operation, we can't drop parentheses.

Also, if (A∧B∧C) is an expression, than the rule of uniform substitution fails. The rule of uniform substitution is important for having an axiomatic system of propositional logic. If say A∧B is meaningful (which you implied), and we have the rule of uniform substitution, then substituting B with CvD we obtain A∧CvD. Suppose A=0, C=0, D=1. Then [A∧(CvD)]=0, while [(A∧C)vD]=1. So, I started with an expression assumed as meaningful and deduced a contradiction, which renders either the expression or the rule of uniform substitution as not meaningful.

• Surely the rule of uniform substitution applies only to wffs. You can replace $B$ with the complete wff $(C\lor D)$; you cannot replace it with the non-wff $C\lor D$ any more than you can replace it with the non-wffs $C\lor$ or $(C\lor D$.
– MJD
Jan 19 '15 at 4:42
• Thank you for your answer. Is it right then, that if ($\lor$ is used) XOR ($\land$ is used) multiple times within the initial expression AND we do not move the parentheses enclosing a substituted expression, then such usage would always be meaningful? Jan 19 '15 at 5:09
• @MJD By substitution I meant exactly that: plugging in a formula as if it was a complete logical "block". Jan 19 '15 at 5:12
• @AndreyPortnoy I'm not sure. Jan 19 '15 at 18:08


# What equation can produce these curves?

Does an equation exist that can produce the curves shown in the attached image, by varying a single variable?

• Do you mean in principle, or are you asking for specific examples? – PyRulez Jul 5 '16 at 3:17

Consider the equilateral hyperbola $xy=1$ and map the points $(1,0)$ and $(0,1)$ to two symmetrical points on the hyperbola $(t,t^{-1})$ and $(t^{-1},t)$ by translation/scaling (as if you were zooming in).

$$(x(t-t^{-1})+t^{-1})(y(t-t^{-1})+t^{-1})=1.$$

The straight line corresponds to two infinitely close points, $t=t^{-1}=1$, which is a degenerate case of the equation.

You can think of a pencil of parabolas, $y=\frac1{\sqrt2}+\frac\lambda{\sqrt2}(2x^2-1)$, which you rotate by $45°$ right, giving

$$x+y=1+\lambda\left((x-y)^2-1\right).$$

You can solve the quadratic equation for $y$.

• If I take $(x,y)$ to be $(1,0)$ or $(0,1)$, it seems to me that your equation is not satisfied. – Jeppe Stig Nielsen Jul 4 '16 at 21:51
• @JeppeStigNielsen: right, I forgot a $\sqrt2$ factor. Now fixed (hopefully). – Yves Daoust Jul 4 '16 at 22:11
• This has become promising, since the it goes through the two points as required, and is has the symmetry that swapping $x$ and $y$ leaves the equation unchanged. However for some values of $\lambda$ it may look different than expected. Like when $\lambda$ is close to $1$, the vertex of the parabola is close to the origin, and the parabola (after rotation) crosses the coordinate axes in the "opposite" direction, I think. – Jeppe Stig Nielsen Jul 4 '16 at 22:34
• @JeppeStigNielsen: the exponent $2$ can be lessened, but at some point we are lacking curve specifications. – Yves Daoust Jul 4 '16 at 22:36
• At what value of $\lambda$ will the two axes be tangents at the two "fixed" points? – Jeppe Stig Nielsen Jul 4 '16 at 22:40

Try a superellipse: $|x|^a + |y|^a =1$ with $0 <a \le 1$.

• Yes, but that curve will not intersect (pass through) the coordinate axes and continue into the 2nd/4th quadrant as shown in the image. But maybe that was not a requirement. – Jeppe Stig Nielsen Jul 4 '16 at 22:02
• @JeppeStigNielsen You could try analytic continuation, or simply remove the $|\cdot|$ – Tobias Kienzler Jul 5 '16 at 6:01
• @TobiasKienzler The superellipse with $a<1$ has a cusp at the point in question. It is not meeting the axis at a non-zero angle like in the drawing of the question. – Jeppe Stig Nielsen Jul 5 '16 at 9:11
• @JeppeStigNielsen Right you are, I spoke to soon... – Tobias Kienzler Jul 5 '16 at 9:50

Try also a quadratic Bézier curve $$\gamma(t) = (1 - t)^{2} P_0 + 2(1 - t)t P_1 + t^{2} P_2$$ where $P_0=(1,0), P_1=(a,a), P_2=(0,1)$, with $a \in [0,0.5]$.

You can first of all use a tool such as Engauge Digitizer to obtain tables of data points for each curve. Then either try a Log-log plot to determine a polynomial approximation or use a fitting tool of your choice to obtain fits of the same kind for each curve. Finally, find a parameter describing each curve such that all the fit-parameters previously obtained can also be fitted by simple functions, ideally linear or a low-order polynomial.

Assuming what you drew to be a parabola, and $p$ a constant to push each parabola along the line of symmetry,

$$y = p (1-x^2)$$

Now rotate them clockwise by $\pi/4 \, , (x,y) \rightarrow ( x+y, x-y)/\sqrt2.$

EDIT1:

As you left it free as regards shape within constraints, we could use a cosh curve, sec curve etc.

In fact, we can generalize this using any open even function E(x) , passing through $(\pm 1/\sqrt{2},1/\sqrt{2} ).$

Letting

$$y(x,p) = (1 + p *(1/2 - x^2) E(x)) /\sqrt{2} \,$$

and building a differentiable function, rotating the curve by $-\pi/4$, we can make the family pass through singular points $(0,1),(1,0)$as shown above and illustrated below in a particular case.

In graph below $E(x) = \cos^2(x)$is chosen with $p= (\pm 2,0).$

For the earlier special case you got parabolas using $E(x)=1$ perturbed by arbitrary $p$ values.

Use Lagrange Interpolation formula: For a variable point $(t,t)$ on the line $x-y=0$ with $0<t\leq \sqrt2/2$, fit a degree 2 polynomial curve that passes through the three points $(0,1), (t,t)$ and $(1,0)$.

For $t=\sqrt2/2$ the three points will be collinear and it will automatically give a straight line. This must produce the same result as Yves Daoust's answer above, but using different interpretation.


My Math Forum Probability Distribution and Standard Deviation

 December 21st, 2013, 05:14 PM #1 Senior Member   Joined: Oct 2013 From: New York, USA Posts: 608 Thanks: 82 Probability Distribution and Standard Deviation I read something somebody else posted and it made me wonder something. If you guess on every multiple choice question without eliminating any choices first, your expected score will be 100/x where x is the number of choices for each question. Assume that all questions have exactly x choices and that there is no penalty for guessing. If you guessed like this on many tests: 1. Are your scores going to be normally distributed? 2. What is the standard deviation of this distribution in terms of x? 3. Can Questions 1 and 2 be answered in general or is it necessary to know the number of choices and/or number of questions? It's possible to calculate the probability of getting at least a certain value given a mean and standard deviation for normally distributed data, but even if this data is normally distributed the number of questions matters. For example, the probability of scoring at least a 20 (the mean) is only 0.2 if there are five choices and there is only one question. With two questions the probability rises to 0.36, with three questions it's 0.488, with four questions it's 0.5904, and with five questions it's 0.67232. With six questions the probability drops to 0.39328 (I think) because it is now necessary to get more than 1 question right to get at least a 20. 4. The number of choices is x and the number of questions is y. Is it a general rule that increasing the number of questions from y to y+1 will increase the probability of getting at least a score of 100/x if y is not a multiple of x and decrease the probability of getting at least a score of 100/x if y is a multiple x? 5. The number of choices is x and the number of questions is y. Let's say instead of wanting to get as high a score as possible you want to get a score of exactly 100/x. This is only possible y is a multiple of x. How many questions would you want there to be to maximize your chance of getting a score of exactly 100/x? I would guess that you would want x and y to be equal because if you flip a coin and want exactly half heads and half tails you would want to flip the coin 2 times.
 December 21st, 2013, 08:11 PM #2 Senior Member   Joined: Aug 2012 Posts: 229 Thanks: 3 Re: Probability Distribution and Standard Deviation Hey Evan3. For 1) You should think about whether the Central Limit Theorem (CLT) applies here or whether there is some other justification for the normal distribution assumption or approximation. If you think the CLT holds, this should help you with your other questions.
December 22nd, 2013, 12:18 AM   #3
Senior Member

Joined: Jun 2013
From: London, England

Posts: 1,316
Thanks: 116

Re: Probability Distribution and Standard Deviation

Quote:
 Originally Posted by EvanJ I read something somebody else posted and it made me wonder something. If you guess on every multiple choice question without eliminating any choices first, your expected score will be 100/x where x is the number of choices for each question. Assume that all questions have exactly x choices and that there is no penalty for guessing. If you guessed like this on many tests: 1. Are your scores going to be normally distributed?
This is a Binomial Distribution. The probability of success in each trial is 1/x.

It approximates to a Normal Distribution for a large number of questions.

Quote:
 2. What is the standard deviation of this distribution in terms of x?
$\sigma= \sqrt{\frac{n}{x} (1-\frac{1}{x})}$

Where n is the number of questions.

Quote:
 3. Can Questions 1 and 2 be answered in general or is it necessary to know the number of choices and/or number of questions? It's possible to calculate the probability of getting at least a certain value given a mean and standard deviation for normally distributed data, but even if this data is normally distributed the number of questions matters. For example, the probability of scoring at least a 20 (the mean) is only 0.2 if there are five choices and there is only one question. With two questions the probability rises to 0.36, with three questions it's 0.488, with four questions it's 0.5904, and with five questions it's 0.67232. With six questions the probability drops to 0.39328 (I think) because it is now necessary to get more than 1 question right to get at least a 20.
The mean is n/x and the and std deviation is given above.

Quote:
 4. The number of choices is x and the number of questions is y. Is it a general rule that increasing the number of questions from y to y+1 will increase the probability of getting at least a score of 100/x if y is not a multiple of x and decrease the probability of getting at least a score of 100/x if y is a multiple x?
No. As y increases, regardless of whether it's a mutiple of x, the probability of getting at least 100/x will increase. Fairly quickly it will become almost a certainty.

Quote:
 5. The number of choices is x and the number of questions is y. Let's say instead of wanting to get as high a score as possible you want to get a score of exactly 100/x. This is only possible y is a multiple of x. How many questions would you want there to be to maximize your chance of getting a score of exactly 100/x? I would guess that you would want x and y to be equal because if you flip a coin and want exactly half heads and half tails you would want to flip the coin 2 times.
Again, there is no reason that y must be a multiple of x. You need 100 to be a mutiple of x.

The most likely outcome is y/x (as it is a bell-shaped curve). Also, as y increases, P(y/x) reduces, because there are more possibilities, so the distribution gets more spread out. So, your best chance of getting 100/x is to have 100 questions.

 December 23rd, 2013, 05:17 AM #4 Senior Member   Joined: Oct 2013 From: New York, USA Posts: 608 Thanks: 82 Re: Probability Distribution and Standard Deviation Thank you. I'm surprised by 4 and 5. If there are 5 choices, the probability of getting at least 1/5th of the questions correct increases as the number of questions goes up from 1 to 5 because in all cases 1 correct answer is necessary to do that. As the number of choices goes up from 5 to 6, the number of correct answers necessary goes up from 1 to 2 (obviously you can't get 6/5 = 1.2 correct answers) and the minimum score necessary to get at least 1/5th of the questions right goes from 20 to 33 1/3. So how can the probability of getting at least 1/5th of the questions correct increase when the increase in number of questions cause the lowest possible score that is > or = to 1/5th of the questions to increase?
 December 23rd, 2013, 08:35 AM #5 Senior Member   Joined: Oct 2013 From: New York, USA Posts: 608 Thanks: 82 Re: Probability Distribution and Standard Deviation I decided to compare the probabilities to what you get from the normal distribution table given the standard deviation Pero posted for 100 questions with 5 choices each. Here are my results: p(16 to 24 successes from the normal distribution) = 0.6826 p(16 to 24 successes from the binomial formula) = 0.7381 That isn't extremely close. I'll do it for 1,000 questions and a smaller range of probabilities: p(190 to 210 successes from the normal distribution) = 0.5704 p(190 to 210 successes from the binomial formula) = 0.5935 I used a smaller range of probabilities because if I did p(160 to 240 success) it would have been almost 1 in both methods.

 Thread Tools Display Modes Linear Mode

 Similar Threads Thread Thread Starter Forum Replies Last Post ragas88 Advanced Statistics 1 July 27th, 2013 08:55 AM Jared944 Advanced Statistics 1 November 5th, 2011 02:58 PM Axel Algebra 2 April 28th, 2011 03:25 AM jd254 Algebra 0 May 7th, 2009 12:46 AM agcliff09 Advanced Statistics 3 November 11th, 2007 10:37 AM

 Contact - Home - Forums - Cryptocurrency Forum - Top


# Which threshold maximizes the expected size of the final sample?

For $$c>0$$, sample repeatedly and independently from $$(0, 1)$$ until the sum of the samples exceeds $$c$$. Let $$\mu_c$$ be the expected size of the final sample.

For which $$c$$ is $$\mu_c$$ maximised?

It is clear that as $$c$$ tends to $$0$$, $$\mu_c$$ tends to $$\frac{1}{2}$$ and this is its minimum value.

• The final sample is the last number you draw, right? Interesting question! – Vincent Dec 27 '19 at 22:02
• @Vincent Yes, it's the sample that pushes the sum of the samples over $c$. – felipa Dec 27 '19 at 22:03
• Very neat question! where did it come from? Is this homework / quiz / etc? What kind of HINT vs actual solution is allowed? Also, I assume you're sampling uniformly in $(0,1)$? – antkam Dec 27 '19 at 22:16
• @antkam It's just for mathematical interest. I was playing around with simulating the setup. A full solution would be very welcome. Yes it's uniform from $(0, 1)$. – felipa Dec 27 '19 at 22:18
• @antkam: Consider a steady-state process with i.i.d. steps uniformly drawn from $(0,1)$, and at some point choose an arbitrary threshold. The probability for a given segment to contain the threshold is proportional to the length of the segment, so the expected length of the segment containing the threshold is $\int_0^12l\cdot l\mathrm dl=\frac23$. – joriki Dec 27 '19 at 23:32

I will write $$f(c) = \mu_c$$ to make it more clearly a function of $$c$$. For now I will only investigate $$c \in [0,1]$$. It turns out (if my math is correct) there is a unique max within $$c \in [0,1]$$, at:

$$c = \ln 2, ~~~~~~~f(c) = \mu_c = \ln 2$$

But frankly I would only trust my own math below with about 80% confidence... :)

First of all, $$c$$ can be considered as the amount "still to go". I.e., starting with $$c$$, if the next sample is $$x < c$$, then you effectively have a new problem with a new threshold of $$c-x$$, and the expected value becomes $$f(c-x)$$. We can build a recurrence from this observation.

Let $$X \sim Unif(0,1)$$. We have:

• Law of total expectation: $$f(c) = P(X > c) E[X \mid X > c] + P( X < c) E[f(c-X) \mid X < c]$$

• $$P(X>c) = 1-c$$

• $$E[X \mid X > c] = {1+ c \over 2}$$ because conditioned on $$X > c$$ then $$X\sim Unif(c,1)$$

• $$P(X < c) = c$$

• Conditioned on $$X < c$$, we have $$c-X \sim Unif(0, c)$$.

So the most trouble term becomes:

$$E[f(c - X) \mid X < c] = \int_0^c \frac1c f(u) ~du$$

And the overall equation is:

$$f(c) = {1 - c^2 \over 2} + c \int_0^c \frac1c f(u) ~du$$

Differentiate w.r.t. $$c$$:

$$f'(c) = -c + f(c)$$

which is an ODE with this solution (credit: wolfram alpha!): for some integration constant $$K$$,

$$f(c) = K e^c + c + 1$$

Substitute in $$f(0) = 1/2$$ (as observed by OP) and solving, we have $$K = -1/2$$ and so:

$$f(c) = -\frac12 e^c + c + 1$$

Now we just need to find the max:

$$f'(c) = -\frac12 e^c + 1 = 0 \iff e^c = 2 \iff c = \ln 2$$

at which point we have $$f(c) = c = \ln 2$$ which is just slightly $$> 2/3$$.

Further thoughts:

(1) I am pretty rusty (and that's a charitable description!) with "continuous" math, so if someone can critique / verify the above, that'd be much appreciated.

(2) This answer does not cover the case of $$c > 1$$ so far. For $$c> 1$$, there is no chance the next sample is enough, and the recurrence becomes:

$$f(c) = \int_{c-1}^c f(u) ~du$$

where $$f(u) = -\frac12 e^u + u + 1$$ whenever $$u < 1$$. I don't know how to do this integration. However, intuitively, since $$f(c)$$ is based on averaging of values of $$f(u)$$ (or average of averages, etc), the max of $$f(c)$$ cannot $$>$$ the max of $$f(u)$$, and in fact, since the max $$f(u)$$ is unique within $$u \in (0,1)$$, the max of $$f(c)$$ cannot even $$=$$ the max of $$f(u)$$ within $$u \in (0,1)$$. This is not a rigorous proof, but rather an intuitive argument why the max I found within $$(0,1)$$ is also the global max.

• My numeric simulations are consistent with your calculations. I would say that for "large" $c$, the distribution of the last uniform random variable (i.e. conditioned on the sum of the previous ones being less than $c$) is triangular with density $$f(x) = 2x \mathbb 1(0 < x < 1).$$ I think using some kind of large-sample approximation would get you the conditional density in this case. – heropup Dec 27 '19 at 23:26
• @heropup - clearly you had some kind of triangle in mind, to get to $2/3$. for large $c$ some kind of "ergodicity" must apply and all points become equally likely, in a sense, but i cant quite translate that into a triangle. anyway, very good intuitive guess! but the "averaging" argument in (2) above (if you buy the argument) means the global max must occur within $(0,1)$ and the limit behavior must fluctuate and cannot be monotonic. this is all very hand-wavy, but that's my gut feel – antkam Dec 27 '19 at 23:30
• Your solution seems correct to me (for $c\le1$). For $1\le c\le2$, we have $$f(c)=\int_{c-1}^1\left(-\frac12\mathrm e^x+x+1\right)\mathrm dx+\int_1^cf(x)\mathrm dx\;;$$ differentiating yields $f'(c)=\frac12\mathrm e^{c-1}-c+f(c)$, and the solution for the initial condition $f(1)=-\frac12\mathrm e+2$ is $f(c)=\frac12\mathrm e^{x-1}(x-1)-\frac12\mathrm e^x+x+1$. Here's a plot. This section also has a local maximum, at $\hat c\approx1.4770$ with $f(\hat c)\approx0.67139$, already quite a bit closer to $\frac23\approx0.66667$ than $\ln2\approx0.69315$. – joriki Dec 28 '19 at 0:07
• @joriki - thanks a LOT for both comments. the $2/3$ limit via steady state is what i had a hazy vision of, but i couldn't find the right argument. and doing the new integral, and in particular showing that it is "piecewise" chopped into intervals delimited by the integers, makes a ton of sense. one can probably recurse this and find the formula for every integer interval, but it might be boring work now. – antkam Dec 28 '19 at 1:23
• @felipa - now that joriki has shown the way, you do the boring work! ;) actually it might not be so boring... if we may extrapolate from two data points (ha!), the next $f(c), c \in [2,3]$ might have a $e^{x-2}$ thingy in it, and then the next has $e^{x-3}$ thingy in it, etc. it might all turn out rather neat! so i definitely won't deprive you of the pleasure of discovery. :) (plus: i'm very very bad at integration... notice that in my original answer, i only had to differentiate!) – antkam Dec 28 '19 at 15:55

antkam's approach is correct and elegant. We can also derive the same result with a bit less calculus by approximating the continuous uniform distribution by a discrete uniform distribution.

So we have an $$n$$-sided die that we roll repeatedly, summing the results, and we want to know the threshold $$k$$ that maximizes the final result (where reaching $$k$$ itself is enough to stop).

We can prove by induction that the expected final result for threshold $$k$$ is $$n+k-\frac n2\left(1+\frac1n\right)^k$$. For $$k=1$$ this is $$n+1-\frac n2\left(1+\frac1n\right)=\frac{n+1}2$$, which is correct. Assuming the result for $$k-1$$, we obtain the expected final result for $$k$$ as

$$\begin{eqnarray*} &&\frac1n\left((n-k+1)\frac{n+k}2+\sum_{j=1}^{k-1}\left(n+j-\frac n2\left(1+\frac1n\right)^j\right)\right) \\ &=& \frac1n\left((n-k+1)\frac{n+k}2+(k-1)n+\frac{k(k-1)}2-\frac n2\left(\frac{1-\left(1+\frac1n\right)^k}{1-\left(1+\frac1n\right)}-1\right)\right) \\ &=& n+k-\frac n2\left(1+\frac 1n\right)^k\;. \end{eqnarray*}$$

Setting the derivative with respect to $$k$$ to zero yields

$$1-\frac n2\ln\left(1+\frac 1n\right)\left(1+\frac 1n\right)^k=0\;,$$

so the optimal threshold in the discrete case is an integer near

$$-\frac{\ln\frac n2+\ln\ln\left(1+\frac 1n\right)}{\ln\left(1+\frac 1n\right)}\;.$$

For instance, for $$n=6$$, this is

$$\frac{\ln3+\ln\ln\frac76}{\ln\frac76}\approx5.003\;,$$

so the optimal threshold is $$k=5$$ with an expected final result of

$$6+5-\frac62\left(1+\frac16\right)^5=\frac{11705}{2592}\approx4.516\;.$$

For $$n\to\infty$$, we have $$\ln\left(1+\frac1n\right)\sim\frac1n$$ and thus

$$-\frac{\ln\frac n2+\ln\ln\left(1+\frac 1n\right)}{\ln\frac 1n}\sim-\frac{\ln\frac n2+\ln\frac 1n}{\frac 1n}=n\cdot\ln2\;,$$

in agreement with antkam's result.

• I really like the discrete version of the problem you have introduced. – felipa Dec 29 '19 at 12:17


# Math Help - Integers

1. ## Integers

Dear all

I have these questions i am having difficulties solving on my on own,your help is been sorted as to how to approach these questions and soultion.I pick these questions from schuam series.

Thank you

Question 1

Of all integer pairs(x,y) that satisfy the equation 42x+55y=1,0nly one such pair has 100<x< 200.what is the value of x in this integer?

Question 2
Let X1 and X2 be two be two smallest positive integer for which the following statement is true 85x-12 is a multiple of 19 then X1+X2= (NB: The 1 and 2 in front of X1 and X2 are all subscripts X1 and X2)

2. Originally Posted by barhin
Question 1

Of all integer pairs(x,y) that satisfy the equation 42x+55y=1, only one such pair has 100<x< 200.what is the value of x in this integer?
This is an exercise in using Euclid's algorithm. (If you haven't come across this, Google it to see why the following calculations are being done.)

\begin{aligned}55&=42+13\\ 42&= 3(13) + 3\\ 13&= 4(3) + 1.\end{aligned}

Now work through those equations in the reverse order to get

\begin{aligned}1&= 13-4(3)\\ &= 13 - 4(42-3(13)) = -4(42) + 13(13)\\ &= -4(42) + 13(55-42) = -17(42) + 13(55).\end{aligned}

So one solution to the equation 42x+55y=1 is x=–17, y= 13. You get the other solutions by adding a multiple of 55 to x, and subtracting the same multiple of 42 from y. Thus $(-17+55k)(42) + (13-42k)(55) = 1$ (you can see that the multiples of k cancel, to leave you with the result from the previous displayed equation).

Now all you have to do is to choose k so that –17+55k lies between 100 and 200.

Originally Posted by barhin
Question 2
Let X1 and X2 be two be two smallest positive integer for which the following statement is true 85x-12 is a multiple of 194 then X1+X2= (NB: The 1 and 2 in front of X1 and X2 are all subscripts X1 and X2)
For this one, start by finding x and y such that 85x+194y=1 (using Euclid's algorithm, as for Q1). Multiply the result by 12 on both sides, to give you a solution to 85X – 12 = (multiple of 194). Then add suitable multiples of 194 to find the two smallest positive values for X.

3. Hello, barhin!

$\text{(1) Of all integer pairs }(x,y)\text{ that satisfy the equation: }\: 42x+55y\:=\:1$
. . $\text{only one such pair has }100

. . $\text{What is this value of }x\,?$

The problem can be solved without Euclid's algorithm.
. . But, of course, this solution takes much longer.

We have: . $42x + 55y \:=\:1$

$\text{Then: }\:x \:=\:\frac{1-55y}{42} \:=\:\frac{-42y + 1 - 13y}{42} \quad\Rightarrow\quad x \:=\:-y + \frac{1-13y}{42}$ .[1]

Since $x$ is an integer, $1-13y$ must be a multiple of 42.

. . $1-13y \:=\:42a \quad\Rightarrow\quad y \:=\:\frac{1-42a}{13} \quad\Rightarrow\quad y \:=\:-3a + \frac{1-3a}{13}$ .[2]

Since $y$ in an integer, $1-3a$ must be a multiple of 13.

. . $1 - 3a \:=\:13b \quad\Rightarrow\quad a \:=\:\frac{1-13b}{3} \quad\Rightarrow\quad a \:=\:-4b + \frac{1-b}{3}$ .[3]

Since $a$ is an integer, $1-b$ must be a multiple of 3.

. . $1-b \:=\:3k \quad\Rightarrow\quad b \:=\:1-3k$

Substitute into [3]:
. . $a \:=\:\text{-}4(1-3b) + \frac{1-(1-3k)}{3} \quad\Rightarrow\quad a \:=\:13k-4$

Substitute into [2]:
. . $y \:=\:\text{-}3(13k-4) + \frac{1-3(13k-4)}{13} \quad\Rightarrow\quad y \:=\:\text{-}42k + 13$

Substitute into [1]:
. . $x \:=\:\text{-}(\text{-}42k+13) + \frac{1-13(\text{-}42k+13)}{42} \quad\Rightarrow\quad x \:=\:55k - 17$ .[4]

Since $100 < x < 200$

. . we have:. . $100 \;<\;55k - 17 \;<\; 200$

. . . Add 17: . . . $117 \;<\;55k \;<\; 217$

Divide by 55: . . $\frac{117}{55} \;<\;k \;<\;\frac{217}{55}$

. . . . . . . . . . . $2.127 \;<\; k \;<\;3.945$

. . . . . . . . . . . . . . $2 \;<\;k \;<\;4$

Hence: . $k\;=\;3$

Substitute into [4]: . $x \:=\:55(3) - 17 \quad\Rightarrow\quad \boxed{x \:=\:148}$

The integer pair is: . $(x,y) \:=\:(148,\:\text{-}113)$

4. Originally Posted by Opalg
This is an exercise in using Euclid's algorithm. (If you haven't come across this, Google it to see why the following calculations are being done.)

\begin{aligned}55&=42+13\\ 42&= 3(13) + 3\\ 13&= 4(3) + 1.\end{aligned}

Now work through those equations in the reverse order to get

\begin{aligned}1&= 13-4(3)\\ &= 13 - 4(42-3(13)) = -4(42) + 13(13)\\ &= -4(42) + 13(55-42) = -17(42) + 13(55).\end{aligned}

So one solution to the equation 42x+55y=1 is x=–17, y= 13. You get the other solutions by adding a multiple of 55 to x, and subtracting the same multiple of 42 from y. Thus $(-17+55k)(42) + (13-42k)(55) = 1$ (you can see that the multiples of k cancel, to leave you with the result from the previous displayed equation).

Now all you have to do is to choose k so that –17+55k lies between 100 and 200.

For this one, start by finding x and y such that 85x+194y=1 (using Euclid's algorithm, as for Q1). Multiply the result by 12 on both sides, to give you a solution to 85X – 12 = (multiple of 19). Then add suitable multiples of 19 to find the two smallest positive values for X.

Dear Soroban,
Thank very much for useful taught on question 1 and 2 , I am how ever getting different results for the second question,will be grateful if you could throw more light or solution to the question 2 for me.It's my prayer that I will become a great mathematician like you

5. Hello, barhin!

$\text{(2) Let }x_1\text{ and }x_2\text{ be the two smallest positive integers}$
$\text{for which the following statement is true: }\:85x-12\text{ is a multiple of 19.}$
$\text{Find }x_1+x_2.$

$85x - 12 \text{ is a multiple of 19}$

$\text{Hence: }\:85x-12 \:=\:19a\;\text{ for some integer }a.$

. . $\text{Then: }\: a \:=\:\frac{85x-12}{19} \quad\Rightarrow\quad a \:=\:4x + \frac{9x-12}{19}$

$\text{Since }a\text{ is an integer, then }9x-12\text{ must be multiple of 19.}$

$\text{Hence: }\:9x-12 \:=\:19b \quad\Rightarrow\quad x \:=\:\frac{19b + 12}{9} \quad\Rightarrow\quad x \:=\:2b + 1 +\frac{b+3}{9}$ .[1]

$\text{Since }b\text{ is an integer, then }b+3\text{ must be a multiple of 9.}$

$\text{Hence: }\:b +3 \:=\:9k \quad\Rightarrow\quad b \:=\:9k-3$

Substitute into [1]:

. . $x \;=\;2(9k-3) + 1 + \frac{(9k-3) + 3}{9} \quad\Rightarrow\quad x \:=\:19k-5$

$\text{The first two positive values of }x\text{ are: }\:\begin{Bmatrix} k = 0 & \Rightarrow & x_1 \:=\:14 \\ k = 1 & \Rightarrow & x_2 \:=\:33 \end{Bmatrix}$

$\text{Therefore: }\:x_1 + x_2 \:=\:14 + 33 \:=\:47$


# Finding smallest possible integer to satisfy a perfect cube

The sum of four consecutive, positive, odd integers is a perfect cube. What is the smallest possible integer that could be the least of the four?

I tried approaching this as follows:

Let $$n$$ be an odd integer, then we can represent the four odd integers as $$n, n+2, n+4, n+6$$.

We want the sum of these integers equal to $$k^3$$, where $$k\in \mathbb{Z^+}$$. So we can write this as

$$n+n+2+n+4+n+6=k^3$$ $$\Leftrightarrow$$ $$4n+12=k^3$$, but from here I don't see how I could continue. I could probably divide the expression by $$4$$ and get $$n+3= \frac{k^3}{4}$$ and then deduce that $$k$$ has to be something of the form $$4n$$? I'm not sure. Any tips would be helpful.

• Trial and error works very quickly. Failing that, you might notice that all those sums are even so the first possible cube is $8$ (which does not work) and the second is $64$ (which does). – lulu May 2 '20 at 11:37

You have that $$n=2m+1$$ because $$n$$ is odd and that $$2m+1+2m+3+2m+5+2m+7 = k^3$$ so $$8m+16 = k^3$$ and so $$8m = k^3-16$$ so $$m = \frac{k^3}{8}-2$$ let $$k = 2 u$$ and we have that $$m = u^3 -2$$ so we have that $$n=2(u^3-2)+1 = 2 u^3-3$$ for $$u \in \mathbb{N}$$ and so the first few $$n$$'s are $$n= -1,13,51,125,\cdots$$

It is an obscure (but provably true) fact that the odd numbers can be separated into consecutive strings whose length increases by $$1$$, and the sum of each string will be the cube of the number of members in the string: $$1=1^3,\ 3+5=2^3,\ 7+9+11=3^3,\ 13+15+17+19=4^3$$ etc. A string of consecutive odd numbers with $$n$$ members will sum to a cube when the first member of that string is $$2k+1$$ where $$k=\sum_{i=1}^{n-1}i$$

The example with four members begins with $$2(\sum_{i=1}^3i)+1=2\cdot 6+1=13$$

Let the four numbers be:

$$((2p^3-3),(2p^3 -1),(2p^3+1),(2p^3+3))$$

Adding them we get $$sum=(2p)^3$$

which is a cube.

Since we need the smallest odd number we have,

$$(2p^3-3)>0$$

which implies $$p=2$$ is the smallest.

Hence the number's are:

$$(13,15,17,19)$$ , & they sum up to $$(4)^3$$


Author Topic: 2.3 question 3  (Read 916 times)

Yan Zhou

• Full Member
• Posts: 15
• Karma: 1
2.3 question 3
« on: February 10, 2020, 07:22:49 PM »
$$\int_{|z+1| = 2} \frac{zdz}{4-z^{2}} = \int_{|z+1| = 2} \frac{\frac{zdz}{2-z}}{2+z}$$
Since -2 lies in $|z+1| = 2$, Cauchy theorem gives that
$$\frac{1}{2\pi i} \int_{|z+1| = 2} \frac{\frac{zdz}{2-z}}{z-(-2)} = \frac{-2}{2-(-2)} = -\frac{1}{2}$$
then $$\int_{|z+1| = 2} \frac{zdz}{4-z^{2}} = -\pi i$$
However, I checked the answer of textbook and it says the answer is $2\pi i$, I am confused about where i did wrong.

Yan Zhou

• Full Member
• Posts: 15
• Karma: 1
Re: 2.3 question 3
« Reply #1 on: February 10, 2020, 07:46:22 PM »
I see. The question on the home assignment is a little bit different from the textbook.

Yan Zhou

• Full Member
• Posts: 15
• Karma: 1
Re: 2.3 question 3
« Reply #2 on: February 10, 2020, 08:11:40 PM »
I found some differences between textbook and home assignment, some of them are typos, and some do not affect the questions but the answers. Should we always follow the questions on the textbook?

Victor Ivrii

Your answer is correct ($-\pi i$).


# Number of rolls with m many n-sided dice

1. Feb 29, 2008

### mathboy

[SOLVED] Number of rolls with m many n-sided dice

How many different rolls are there with m many n-sided dice, if order is not important?

If order was important, the answer would simply be n^m. But if order is not important?

If two 6-sided dice are rolled, there are C(6,2)+C(6,1) = 21 different rolls.
If three 6-sided dice are rolled, there are C(6,3)+C(6,1)C(5,1)+C(6,1) = 56 different rolls.

Is there a general method for rolling m many n-sided dice? Or do you have to continue adding up all the cases? Perhaps a general method involving a matrix with m indices (e.g. a tensor) and simply excluding all permutations of the indices?

Last edited: Feb 29, 2008
2. Feb 29, 2008

### e(ho0n3

Wouldn't it be n^m/m!? For example, say you have a black die and a red die, both 6-sided. The number of possible rolls is 6^2. If you ignore the color of the dice, then you have to divide by 2.

3. Feb 29, 2008

### mathboy

No. The number of rolls with 2 six-sided dice (if order is unimportant) is 21, not 18. Rolls with doubles are not being counted twice if order is considered important.

4. Feb 29, 2008

### e(ho0n3

Oh that's right. Sorry about that. I don't know of a general method. I'm thinking that you would first have to count the number of rolls where all dice show the same side, then for m-1 dice showing the same side, then for m-2 dice, etc.

5. Feb 29, 2008

### mathboy

That's exactly what I did in my opening post. But it gets awkward after a while (e.g. for 7 dice, you can have 2 doubles and 1 triple). I'm looking for a better method that gives a single formula for arbitrarily values of m and n,

e.g. m^n minus something.

Last edited: Feb 29, 2008
6. Feb 29, 2008

### stewartcs

Yes.

$$\frac{(n + m - 1)!}{m!(n - 1)!}$$

CS

7. Feb 29, 2008

### mathboy

Wow! That gives the right answer for all the cases I worked out.

So the answer is C(m+n-1,m), i.e. the number of ways to choose m numbers from m+n-1 numbers. Half of this makes some sense to me because we are rolling m dice. But what's the reason for the m+n-1?

8. Feb 29, 2008

### stewartcs

9. Feb 29, 2008

### mathboy

Thank you so much. Sometimes extra knowledge is the key to solving a problem.

Last edited: Feb 29, 2008
10. Jan 22, 2011

### lcscipiop

Re: [SOLVED] Number of rolls with m many n-sided dice


Finding the Area bounded by the curve

shamieh

Active member
Find the area bounded by the curve $$\displaystyle x = 16 - y^4$$ and the y axis.

I need someone to check my work.

so I know this is a upside down parabola so I find the two x coordinates which are

$$\displaystyle 16 - y^4 = 0$$
$$\displaystyle y^4 = 16$$
$$\displaystyle y^2 = +- \sqrt{4}$$
$$\displaystyle y = +- 2$$

so I know

$$\displaystyle \int^2_{-2} 16 - y^4 dy$$

Take antiderivative

$$\displaystyle 16y - \frac{1}{5}y^5$$ | -2 to 2

so $$\displaystyle (2) = 32 - \frac{32}{5} = \frac{160}{5}$$

then $$\displaystyle (-2) = -32 - (\frac{-32}{5}) = -32 + \frac{32}{5} = \frac{-160}{5} + \frac{32}{5} = \frac{-128}{5}$$

SO finally
$$\displaystyle [\frac{160}{5}] - [\frac{-128}{5}] = \frac{288}{5}$$

ZaidAlyafey

Well-known member
MHB Math Helper
This is not a parabola. It is like a parabola that intersects the y-axis at $$\displaystyle y=\pm 2$$ so it is open to the left. I suggest you revise your calculations.

MarkFL

Staff member
I would use the even-function rule to state:

$$\displaystyle A=2\int_0^2 16-y^4\,dy=\frac{2}{5}\left[80y-y^5 \right]_0^2=?$$

shamieh

Active member
Recalculated answer below if someone has a chance to check.

Last edited:

shamieh

Active member
recalculated and got $$\displaystyle \frac{256}{5}$$ . Is that correct?

- - - Updated - - -

I would use the even-function rule to state:

$$\displaystyle A=2\int_0^2 16-y^4\,dy=\frac{2}{5}\left[80y-y^5 \right]_0^2=?$$
Yea this rule is so much easier!

- - - Updated - - -

Mark, know anywhere where I can find a good definition of the even function rule, so I can see how and when I can apply it etc. I googled it but couldn't find this one.

shamieh

Active member
Like how would I use this rule if i had $$\displaystyle 5 - x^2$$?

MarkFL

Staff member
recalculated and got $$\displaystyle \frac{256}{5}$$ . Is that correct?

- - - Updated - - -

Yea this rule is so much easier!

- - - Updated - - -

Mark, know anywhere where I can find a good definition of the even function rule, so I can see how and when I can apply it etc. I googled it but couldn't find this one.
Yes, your result of $$\displaystyle A=\frac{256}{5}$$ is correct.

An even function is symmetric about the $y$-axis, i.e., $$\displaystyle f(-x)=f(x)$$. If your limits of integration are also symmetric about the $y$-axis, then you may apply the even function rule.

Observe that:

$$\displaystyle \int_{-a}^a f(x)\,dx=\int_{-a}^0 f(x)\,dx+\int_0^a f(x)\,dx$$

Now, in the first integral, if we replace $x$ with $-x$, we have:

$$\displaystyle \int_{-a}^a f(x)\,dx=\int_{a}^0 f(-x)\,-dx+\int_0^a f(x)\,dx$$

Bringing the negative in front of the differential out front and using $$\displaystyle f(-x)=f(x)$$, we have:

$$\displaystyle \int_{-a}^a f(x)\,dx=-\int_{a}^0 f(x)\,-dx+\int_0^a f(x)\,dx$$

Applying the FTOC, we obtain:

$$\displaystyle \int_{-a}^a f(x)\,dx=-\left(F(0)-F(a) \right)+F(a)-F(0)=2F(a)=2\int_0^a f(x)\,dx$$

ZaidAlyafey

Well-known member
MHB Math Helper
Yes, your result of $$\displaystyle A=\frac{256}{5}$$ is correct.

An even function is symmetric about the $y$-axis, i.e., $$\displaystyle f(-x)=f(x)$$. If your limits of integration are also symmetric about the $y$-axis, then you may apply the even function rule.

Observe that:

$$\displaystyle \int_{-a}^a f(x)\,dx=\int_{-a}^0 f(x)\,dx+\int_0^a f(x)\,dx$$

Now, in the first integral, if we replace $x$ with $-x$, we have:

$$\displaystyle \int_{-a}^a f(x)\,dx=\int_{a}^0 f(-x)\,-dx+\int_0^a f(x)\,dx$$

Bringing the negative in front of the differential out front and using $$\displaystyle f(-x)=f(x)$$, we have:
$$\displaystyle \int_{-a}^a f(x)\,dx=-\int_{a}^0 f(x)\,dx+\int_0^a f(x)\,dx=\int_{0}^a f(x)\,dx+\int_0^a f(x)\,dx=2\int^a_0 f(x)\, dx$$


# Thread: Taylor series question confusion

1. ## Taylor series question confusion

There is this problem that has been appearing a lot lately but I cannot find any examples that help me solve this.

It states:

"Find (at least) the first 3 nonzero terms in the Taylor (power) series for

$f(x) = \frac{x^3}{3+5x}$ centered at $a = 0.$

(This is the same as the Maclaurin series for the function $f$)"

Now I know how to use the Taylor series and get an expansion, but my method involves continuously taking the derivative of the function which can get pretty messy after even the second derivation. And even at that point, I'm still getting zero for my expansion terms.

What is this question asking exactly?

2. Originally Posted by freyrkessenin
There is this problem that has been appearing a lot lately but I cannot find any examples that help me solve this.

It states:

"Find (at least) the first 3 nonzero terms in the Taylor (power) series for

$f(x) = \frac{x^3}{3+5x}$ centered at $a = 0.$

(This is the same as the Maclaurin series for the function $f$)"

Now I know how to use the Taylor series and get an expansion, but my method involves continuously taking the derivative of the function which can get pretty messy after even the second derivation. And even at that point, I'm still getting zero for my expansion terms.

What is this question asking exactly?
I agree that Taylor series can be fairly nasty at time, but sometimes (as in your case you can make life alot easier on yourself)

here you are given x^3/( 3 + 5x) = x^3 * ( 1/(3 + 5x) )

Here we observe that the only component that truely requires a taylor expansion is (1/(3+ 5x)), whose derivatives are far easier to compute than that of the original function.

Once this is obtained you simply multiple the series through by x^3 and viola you have answered the problem with only a 10th of the pain!!

Hope this points you in the right direction,

Let me know if you require any further assistance,

David

ps - make life even easier on yourself by simplifying the function even further, i.e.
1/(3 + 5x) = 1/( 3 (1 + ((5/3)x)) = (1/3)(1/(1 + (5/3)x)) i.e bring the 1/3 out the front
furthermore let t = 5/3x and thus you you need only solve for 1/(1+t) = a0 + a1*t + ....

To then get in back in terms of x, sub t = 5/3x into the the taylor expansion and your done!

3. ## Hi

I tried performing some hand calculations, and got the following result.
$f(x) = \frac{x^3}{3+5x} = x^3 \cdot \frac{1}{3+5x}$

Now I only performing a maclaurin series on the $\frac{1}{3+5x}$
term.
Let $h(x) \, \mbox{be the maclaurin series of }\frac{1}{3+5x}$

Then $f(x) \approx x^3 \cdot h(x)$

If I dont bother with the restterm, then we get something like (see picture).

And the two functions seem to be pretty close around $x=0$

You can see the maclaurin series in the picture...

4. Originally Posted by Twig
I tried performing some hand calculations, and got the following result.
$f(x) = \frac{x^3}{3+5x} = x^3 \cdot \frac{1}{3+5x}$

Now I only performing a maclaurin series on the $\frac{1}{3+5x}$
term.
Let $h(x) \, \mbox{be the maclaurin series of }\frac{1}{3+5x}$

Then $f(x) \approx x^3 \cdot h(x)$

If I dont bother with the restterm, then we get something like (see picture).

And the two functions seem to be pretty close around $x=0$

You can see the maclaurin series in the picture...
Yes, I prefer Twiggy's method.

$\forall{x}\backepsilon|x|<1~\frac{1}{1-x}=\sum_{n=0}^{\infty}x^n$

And

\begin{aligned}\forall{x}\backepsilon|5x|<1~\frac{ 1}{1+5x}&=\frac{1}{1-(-5x)}\\
&=\sum_{n=0}^{\infty}\left(-5x\right)^n\\
&=\sum_{n=0}^{\infty}(-1)^n5^nx^n
\end{aligned}

\begin{aligned}\therefore~\forall{x}\backepsilon|5 x|<1~\frac{x^3}{1+5x}&=x^3\cdot\frac{1}{1+5x}\\
&=x^3\cdot\sum_{n=0}^{\infty}(-1)^n5^nx^n\\
&=\sum_{n=0}^{\infty}(-1)^n5^nx^{n+3}
\end{aligned}

So now truncate to the number of terms you need for your series.


# Solve the following equation.

Question: $3^{x^2-5} - 9^{x-1} = 0$

$3^{x^2 -5} - 9^{x-1} = 0$

$3^{x^2 -5} = 9^{x-1}$

if $x = 3$

$3^{9-5} = 9^2$

$3^4 = 9^2$

$81 = 81$

and $x = 3$

Is this the right way to solve it?

• Do you know that's the only solution? – David Mitra Feb 6 '14 at 18:32
• I didn't get you, sorry! :( Can you explain? @DavidMitra – Kiara Feb 6 '14 at 18:35
• You found one solution. There may be others. There might not be others. You need to determine which of the two cases holds and prove it. – David Mitra Feb 6 '14 at 18:36
• Yeah, you're right...I have two answers in my book and I got only one. :( – Kiara Feb 6 '14 at 18:37

HINT:

Using Exponent law, $\displaystyle(a^x)^y=a^{xy}$

We have, $$3^{x^2-5}=9^{x-1}=(3^2)^{x-1}$$

$$\implies 3^{x^2-5}=3^{2(x-1)}$$

Now if $\displaystyle a^x=a^y\implies a^{x-y}=1$ (assuming $a$ to be non-zero finite number)

either $a=1$

or $a=-1,x-y$ is even

or $x=y$ for real $a$

That approach certainly works, but you missed a root $x=-1$. A more general approach to the problem is noting that $9 = 3^2$ and that $(x^a)^b = x^{ab}$. Then we have $$3^{x^2-5} - 9^{x-1} = 3^{x^2-5} - (3^2)^{x-1} = 3^{x^2-5} - 3^{2x-2} = 0 \implies 2x-2 =x^2 -5$$

We can just solve for $x$ now: $$2x-2 = x^2 - 5 \implies x^2-2x-3 = (x-3)(x+1) = 0 \implies x=-1 \text{ or } x=3$$


# Area of a regular hexagon via area of triangles

Problem: Find the area of a regular hexagon whose sides measures 5 cm

Sol'n 1: I can cut the hexagon into 6 small triangles, so the area of triangle times 6 will be equal to the area of the polygon. Since the triangles are equilateral I can use the formula for it.

Area of triangle = $\frac{\sqrt{3}}{4}(5)^2= 10.83$

Area of hexagon = (6)(10.83) = 64.95

Sol'n 2: Using the formula $\frac{1}{2}(base)(height)$ for the area of triangle. The angle of triangle (angle at the radius) is equal to 60 degrees (From 360 / 6). Cutting the triangle into half (to get the base and height) will result to an angle of 30 degrees and base of 2.5.

To get the height: $tan(30) = \frac{2.5}{height} = 4.33$, so the area of the triangle: $\frac{1}{2}(2.5)(4.33) = 5.41$

Area of hexagon = (6)(5.41) = 32.475 which does not equal to the area in solution 1.

Question: I noticed that the area calculated on solution 2 is half the area calculated in solution 1. I don't know why. I don't think plugging in the original length of the base is right or logical? I have answered a related problem like this and I have gotten the polygon's area with 1/2(base)(height) and not plugging the original base length back to the formula of area after getting the height. Topic is easy but I don't get why I get so confused. :( Any help will be appreciated.

You've created your diagram like this, calculated the area of the triangle I've labelled, and then multiplied that area by $6$. Notice however, by your divisions, we've split the hexagon into $12$ triangles, so we would need to multiply the area by $12$, not $6$, which explains why your area for Sol $2$ is half the area for Sol $1$ (which is correct)

The area of one triangle is given by $\frac 12\cdot2.5\cdot2.5\tan(60)=\frac{25\sqrt3}{8}$. Multiplying this area by $12$ (the amount of triangles) gives us $\frac{75\sqrt3}{2}\approx64.9519$

• Please excuse the awful quality of the diagram but I hope that it is clear enough – Rhys Hughes May 19 '18 at 14:29
• I answered a similar problem. Find the area of a regular octagon inscribed in a circle whose radius is 12. I also dissected the octagon into 8 triangles and like in the problem above, I formed a right triangle with hypotenuse = 12, angle = 22.5 and base = x/2. The calculated area of the octagon using this method equals the calculated area using the other triangle formula: $absin\theta$ and I did not need to multiply the area by 16 but just by 8 which confuses me. – Jayce May 19 '18 at 14:36
• Typo on my comment above. Should be $\frac{1}{2}absin\theta$. – Jayce May 19 '18 at 14:52
• Octagons have a regular angle of $135^0$. When you divide the octagon into eight triangles, you get an angle of $45^0$ at the centre. Thus for the whole octagon you should use $8\cdot\frac{1}{2}\cdot12^2\cdot\sin45=288\sqrt2 \approx407.2935$ – Rhys Hughes May 19 '18 at 14:58
• You are right. Try solving it via $\frac{1}{2}(base)(height)$. It will result to 407.29 even though the area is only multiplied by 8 which should be by 16 as per your explanation. I used 22.5 as the angle for the right triangle, "x/2" for the base and the hypotenuse, 12. Then Via "soh-cah-toa", base is 9.184 and height is 11.087. Plugging it in: $\frac{1}{2}(9.184)(11.087) = 50.911$ then multiplied by 8 which equals to 407.29, the same with $absin\theta$ but I only multiplied it by 8 and not by 16. I need an answer for this, so I can move on. :( – Jayce May 19 '18 at 15:14

Solution 1 gives the correct answer. In solution 2, the triangle that you're calculating is actually a right-angled triangle with interior angles $30°$, $60°$ and $90°$, and it is in fact half of the triangle calculated in solution 1. This explains why the numerical result obtained in solution 2 is half of that in solution 1.

• I answered a similar problem. Find the area of a regular octagon inscribed in a circle whose radius is 12. I used 2 formulas of triangle: $\frac{1}{2}absin\theta$ and $\frac{1}{2}(base)(height)$. For $\frac{1}{2}(base)(height)$, I did the same thing, I formed a right triangle to get the height then calculated the area then multiplied it by 8 to get the octagon area. This equals the area calculated using $\frac{1}{2}absin\theta$. It equals even though I multiplied it just by 8 which is supposed to be by 16 just like you explained. :( – Jayce May 19 '18 at 14:50
• The solution for the above, @The right triangle: angle = 22.5 (From 360/8 = 45/2 = 22.5), side = 12 (From the given radius) and base = x/2. Via "soh-cah-toa", base = 9.184 and height = 11.087. Plugging it into $8*[\frac{1}{2}(base)(height)] = 407.89$ which is the area of octagon. Via $\frac{1}{2}absin\theta$ where a = b = 12 and angle = 45 (from 360/8). Plugging it in the formula and multiplying it by 8 to get the octagon area, we get 407.29. The areas are equal even though in solution 1, I just multiplied it by 8. – Jayce May 19 '18 at 15:05


# How to find the limit of series? (What should I know?)

There is a couple of limits that I failed to find:

$$\lim_{n\to\infty}\frac 1 2 + \frac 1 4 + \frac 1 {8} + \cdots + \frac {1}{2^{n}}$$

and

$$\lim_{n\to\infty}1 - \frac 1 3 + \frac 1 9 - \frac 1 {27} + \cdots + \frac {(-1)^{n-1}}{3^{n-1}}$$

There is no problem to calculate a limit using Wolfram Alfa or something like that. But what I am interested in is the method, not just a concrete result.

So my questions are:

• What should I do when I need a limit of infinite sum? (are there any rules of thumb?)
• What theorems or topics from calculus should I know to solve these problems better?

I am new to math and will appreciate any help. Thank you!

• Hint: Geometric Series! – Qi Zhu Oct 29 '17 at 19:24
• I am also new to Mathematics on Stack Exchange, so if you see that I can improve my question, I would appreciate if you left a comment – Nikita Hismatov Oct 29 '17 at 19:24
• Demidovich!!! I've used it in 1977 to prepare Calculus I and after I continued to use it to give private classes to a lot of people, including the girl who became my wife... – Raffaele Oct 29 '17 at 20:58
• Writing the first in binary will result in something interesting. – chx Oct 29 '17 at 21:00
• @NikitaHismatov Once I asked a professor of mine about this. He replied: "Do you think we have a panacea to calculate limits?!" - As it often happens in mathematics, we have methods for some cases but you can always find harder limits for which the previously developed methods do not work. I once thought about the existence of the following limit and asked here, people were able to compute the limit but I'm not sure I really understand what they did. – Billy Rubina Oct 30 '17 at 6:34

$$\color{red}{1+}\frac 1 2 + \frac 1 4 + \frac 1 {8} + \ldots + \frac {1}{2^{n}}$$ Is an example of $$1+x+x^2+x^3+\ldots+x^n$$ Where the ratio between a number $a_n$ and the previous $a_{n-1}$ is constant and is $x$. This is the sum of a geometric progression and it's quite easy to see that its value is $$\frac{1-x^{n+1}}{1-x}$$ When $n\to\infty$ the sum converges only if $|x|<1$ because if so $x^{n+1}\to 0$ and the sum is $$\sum_{n=0}^{\infty}x^n=\frac{1}{1-x}$$ In your first example $x=\frac12$ and index $n$ starts from $n=1$ so the sum is $$\sum_{n=1}^{\infty}\left(\frac12\right)^n=\frac{1}{1-\frac12}-1=\color{red}{1}$$ The second one is $$\lim_{n\to\infty}1 - \frac 1 3 + \frac 1 9 - \frac 1 {27} + \cdots + \frac {(-1)^{n}}{3^{n}}=\sum_{n=0}^{\infty}\left(-\frac13\right)^n=\frac{1}{1-\left(-\frac13\right)}=\color{red}{\frac34}$$

Hope this is useful

Hint:

All you have to know is the sum of the $n$ first terms of a geometric series, which is a formula from high school: $$1+q+q^2+\dots +q^n=\frac{1-q^{n+1}}{1-q}\qquad (q\ne 1),$$from which we can deduce: $$q^r+q^{r+1}+\dots +q^n=q^r(1+q+\dots+q^{n-r})=q^r\frac{1-q^{n-r+1}}{1-q}=\frac{q^r-q^{n+1}}{1-q}.$$ If $\lvert q\rvert<1$, these sums have limits $\;\dfrac1{1-q}\;$ and $\;\dfrac{q^r}{1-q}\;$ respectively.

What should I do when I need a limit of infinite sum? (are there any rules of thumb?)

In general - no there aren't such rules. There are specific types of series for which it is known how to compute the limit (like the geometric series). There are way more recepies for figuring out whether a series converges or not (finding the limit is much harder). But also here the cookbook is limited. As others pointed out already, your two series are geometric series, who's limit can be computed easily.

Well, that first one should be an instance of a theorem you should definitely put in your list of useful theorems:

If $|a| < 1$:

$$\sum_{i=1}^{\infty} \ a^i = \frac{a}{1-a}$$

And the second one is an instance of the closely related:

If $|a| < 1$:

$$\sum_{i=0}^{\infty} \ a^i = \frac{1}{1-a}$$

If you don't want to remember both, it's ok to remember just one, because the other one can easily be derived from it, e.g:

$$\sum_{i=0}^{\infty} \ a^i = a^0 + \sum_{i=1}^{\infty} \ a^i = 1 + \frac{a}{1-a} = \frac{1-a}{1-a} + \frac{a}{1-a} = \frac{1-a+a}{1-a}= \frac{1}{1-a}$$

• Or, perhaps more simply, $$\sum_{i=1}^{\infty}a^i = a\sum_{i=0}^{\infty}a^i =a\left( \frac{1}{1-a}\right)$$ – Bungo Oct 29 '17 at 19:52
• @Bungo Yes, nice! I always forget about that trick :( – Bram28 Oct 29 '17 at 19:55

the other answers are correct but if you want to see a more "visualize" way(it is actually the same way but you can see it more clearly) $$S=\lim_{n\to\infty}\sum_{i=1}^n\frac {1}{2^{i}}=\frac 1 2 + \frac 1 4 + \frac 1 {8} + \cdots\\2S=\lim_{n\to\infty}\sum_{i=0}^n\frac {1}{2^{i}}=\frac 1 1 + \frac 1 2 + \frac 1 {4} + \cdots=1+\lim_{n\to\infty}\sum_{i=1}^n\frac {1}{2^{i}}=1+S\\2S-S=\left(1+S\right)-S=1$$ and $$A=\lim_{n\to\infty}\sum_{i=1}^n\frac {(-1)^{i-1}}{3^{i-1}}=1 - \frac 1 3 + \frac 1 9 - \frac 1 {27} + \cdots \\ 3A=\lim_{n\to\infty}\sum_{i=1}^n\frac {(-1)^{i-1}}{3^{i-2}}=3 - \frac 3 3 + \frac 3 9 - \frac 3 {27} + \cdots\\=3-\left(1 - \frac 1 3 + \frac 1 9 - \frac 1 {27} + \cdots\right)=3-A\\3-A=3A\implies3=4A\implies\frac34=A$$

Note that you have the sums $\sum_{k = 1}^{\infty} \frac{1}{2^k}$ and $\sum_{k=0}^{\infty} \left(-\frac{1}{3} \right)^k$. Now look up geometric series and try to finish these on your own :)

In case of infinite Geometric Progression,

$$sum = \frac{a}{1-r}$$

you can also derive this from the normal formula using, $n\to \infty$

The thing to know here is that $$|r| <1$$

To explain this, if |r|<1 , ar < a similarly $ar^2 < ar$ and each next term will keep getting smaller and smaller and as $n\to \infty$, $$a_n = ar^{n-1} \to 0$$ therefore, we can successfully find a finite number to which this sequence will converge to as the later on terms are so smaller than the initial ones that they won't even contribute to the sum.

Although if |r|>1 each term will be greater than the previous one, so we will never be able to sum this sequence.

The sums you mention are both examples of geometric series. There are no general ways to sum arbitrary sequences - they typically require some inspiration. Geometric series are often proven geometrically, but the algebraic proof is illustrative.

$$\sum_{n=0}^{m} a^n = S_{m}, a S_{m} = \sum_{n=1}^m a^n = S_{m+1} - 1$$

$$S_m - a S_m = 1 - a^{m+1}$$

$$S_{m} = \frac{1 - a^{m+1}}{1 - a}$$

The other series is relatively straightforward if you know what your goal is:

$$\sum_{n=0}^\infty \frac{(-1)^n}{3^n} = \sum_{n=0}^\infty \frac{1}{9^n} - \frac{1}{3}\sum_{n=0}^\infty \frac{1}{9^n} = \frac{2}{3} \sum_{n=0}^\infty \frac{1}{9^n}$$

They are sums of geometric progressions.

The first it's $$\frac{\frac{1}{2}}{1-\frac{1}{2}}=1.$$

The second it's $$\frac{1}{1+\frac{1}{3}}=\frac{3}{4}.$$

• I downvoted this answer because it does not address the OP's note that "what I am interested in is the method, not just a concrete result." Naming the series is helpful, but something more—like explaining a closed form for the partial sums, or showing that the limit exists and then showing what it must be—is in order. – wchargin Oct 29 '17 at 22:14


# How do I denote arbitrary element of these vectors?

I know that when we have something like $$\bf u$$, then the arbitrary element $$i$$ will be denoted as $$u_{i}$$.

Now suppose we have vectors $$\{\mathbf {v_{1}, v_{2}, \cdots, v_{n}} \}$$

I want to consider, say, third element of the fifth vector.

How do I denote it?

Is it $$(\mathbf{v_{5}})_{3}$$ or $$\mathbf{v_{}}_{5_{3}}$$? Or are there better options available?

• Depending on the context, you may want $v_{5,3}, v_5(3), v_5[3], v_5^3$ (though you may make some people irritated, no matter which you choose). Just make sure you are clear and consistent with your notation, and if you find you later have clashes of notation, be very careful to specify which is which. – Brian Moehring Sep 20 at 5:39
• Yes, ${V^_5)_3$ is correct. – Dr Zafar Ahmed DSc Sep 20 at 5:54

You can technically do whatever you want as long as it’s comprehensible (actually, it doesn’t even need to be comprehensible, but if it isn’t, nobody will care—just look at some of Galois’s manuscripts!) but what you might find useful is $$v_{i,j}$$ which may denote the $$i$$-th component of the $$j$$-th vector, or vice-versa.
When I have to manipulate indices of many vectors, I like calling them $$\{v^{(1)},...,v^{(m)}\}$$ and labeling elements of those vectors $$v^{(i)}_j$$ because I prefer to keep vector indices downstairs when I can. You can also drop the parantheses. Whatever makes most sense to you is good, as long as other people can understand it as well.