Maths Question

Page may contain affiliate links. Please see terms for details.

Tim Hall

Guest
Location
Crawley
[QUOTE 2272120, member: 9609"]have you tried putting =(9+1)/2*9 into excel[/quote]
So Excel is wrong differently correct too.

Windows calculator used to give different answers depending on whether Standard or Scientific view was chosen.

It's no big deal.

Anyway, I'm still trying to get to grips with why Albelian Grape's answer is right. Luckily The Boy, who is studying Hard Sums at University is home this weekend. I shall ask him.
 

vernon

Harder than Ronnie Pickering
Location
Meanwood, Leeds
[QUOTE 2272144, member: 9609"]There we go, I have removed your surplus and redundant symbol[/quote]

Sigh.

Can't even get plurality right....
 
The proof by induction, which you didn't get at 8am because I hadn't yet had any coffee (doing maths without coffee is like cycling without cake):

The formula is correct for 1 row by calculation.

Assume the formula is correct for n rows. Then, by Reiver's formula, the total for n+1 rows is the total for n rows plus the sum of the (n+1)th row, which is (n+1)(n+2)/2. But

n(n+1)(n+2)/6 + (n+1)(n+2)/2 = (n+1)(n+2)(n+3)/6

So the formula is correct for n+1 rows, completing the proof by induction.

It ought to be possible to "see" why this is the same as the number of ways of choosing 3 elements from a set of n elements, but it isn't obvious to me right now.

How did we get here? What was the context for the original question?
 

srw

It's a bit more complicated than that...
It ought to be possible to "see" why this is the same as the number of ways of choosing 3 elements from a set of n elements, but it isn't obvious to me right now.
Something to do with Pascal's triangle? I can't see the link immediately.
 

thom

____
Location
The Borough
No. To a mathematician, (n+1) / 2 x n is the same as (n+1)/2n. You need to multiply by n, not divide.


It feels combinatorial. I suspect the general answer is
(n+1)! / (n-m)! . m!

It's been a very very long while since I did combinatorics, but it's something like the number of ways of selecting m things from n. You're asking for the number of ways of selecting 3 from n. The proof will be by induction - prove true for n=1 and that if true for n, also true for n+1.

If you are trying to generalise based upon dimensionality, Reiver's problem being for m= 2, I think you mean to conjecture :
(n+m ) ! / { ( m +1 )! ( n - 1 )! } or (n+m) choose m+1

And if you do the induction arguments on m, you just need to show....:
(n+m) choose (m+1) = ( n+m-1) choose (m+1) + (n+m-1) choose ( m )
Which is almost "trivial" ;-) - it is Pascal's rule in fact.

This offers no insight but there is a curious relationship to the iterated integral of the infinite sum of delta function that care about integers
 

srw

It's a bit more complicated than that...
@thom - you're right. I had half an ear on a very dull conference call at the time. Though as a pure mathematician by inclination I can't accept your assertion that triviality is enough.

And we still haven't established a conceptual link between combinatorics, hyper-tetrahedral numbers and expansions of (x+1)^n.
 

thom

____
Location
The Borough
@thom - you're right. I had half an ear on a very dull conference call at the time. Though as a pure mathematician by inclination I can't accept your assertion that triviality is enough.

And we still haven't established a conceptual link between combinatorics, hyper-tetrahedral numbers and expansions of (x+1)^n.
If you want, I'll write it down, just ask - it's just that this editor is not particularly designed for writing math formulae but it's either this or my tax return...
But the "trivial" combinatorial identity needed is just Pascal's rule
 

Psycolist

NINJA BYKALIST
Location
North Essex
I'm afraid that you did type (n+1)/2n

if you wanted (n+1)/2 all multiplied by n you should have typed

n(n+1)/2

Just because Excel parses your expression to give you a 'correct' answer does not mean that your expression is correct. It could be a case of two wrong making a right.
You lost me at 'im afraid' :wacko:
 

Psycolist

NINJA BYKALIST
Location
North Essex
[QUOTE 2271461, member: 9609"]I was struggling with the following problem and cheated and worked it out in excel. But I am still really curious how I would work it out on a bit of paper. (it is vaguely cycling related so probably allwed on the forum :-))

If you could imagine the number 6 and all the numbers that lead to it add up to add upto 21
1+2+3+4+5+6=21
the equation for this is quite easy (n+1) / 2 x n

but what I need to know is how to work it out for all the numbers that lead up to 6
1+2+3+4+5+6
1+2+3+4+5
1+2+3+4
1+2+3
1+2
1
=56

now I needed to do this when 'n' was in excess of 400,000 - clearly not practical on a bit of paper, the answer was something like 10^16

So how would I create a equation for this problem?[/quote]
My compliments to you in knowing how to do it in excel, let alone anything else in this thread:bicycle: I'm going for a ride..................and how is it even loosley related to cycling ?
 

thom

____
Location
The Borough
I have a truly marvellous proof of this proposition, but I can't get TeX working on my iPad.
OK, you asked for it !

We need to start by defining a function f(m,n) of 2 integers, m and n where n is used as before and m is the degree:

f(0,n) = n { = sum_{i=1}^{i=n} 1 } : for n > 0
f(m,n) = f(m-1,1) + f(m-1,2) + ... + f(m-1,n) : for n > 0, m > 0 I shall refer to this statement as (X)

We see that : f(1,n) = 1 + 2 + 3 + ... + n = n(n+1)/2 (we know the formula)
and Reivers query : f(2,n ) = f(1,1) + f(1,2) + ... + f(1,n )
= 1 + 2 + 6 + ... + n(n+1)/2 = n(n+1)(n+2)/6 (AbelianGrape's formula)

So f(m,n) generalises Reiver's query for m > 2. Note also that f(m,1) = f(m-1,1) = ... = f(0,1) = 1.

For some simplicity, let us use C(n,k) to be what is commonly known as the Binomial coefficient of n indexed by k where n & k are integers. We have the identity:

C(n,k) = n! / ( k! (n-k)! )

We need Pascal's rule that states C(n,k) = C(n-1,k) + C(n-1,k-1) for n>0, k>0. This formula is "trivial" in so far as you can show it from the formula I gave for C(n,k) in 2 lines but also relate it directly to Pascal's triangle.

I want to demonstrate a formula for f(m,n) in terms of the function C(.,.), using a 2 step induction argument.

Proposition :

f(m,n) = C(m+n,m+1) for m >= 0, n > 0 I shall refer to this statement as (Y)

OK, so we make the outer inductive statement H(M) which states that formula (Y) is true for all m <= M.
First note 2 things :
1) for m = 0, C(n,1) = n = f(0,n) so (Y) is true for m = 0 for all n > 0
2) for n = 1, C(m+1,m+1) = 1 = f(m,1) so (Y) is true for m = 1 and all m >= 0

1) implies that H(0) is true. So let us assume H is true up to M >= 0 and show that this implies H(M+1) is also true.

Well, for n > 1, (X) can be written alternatively:

f(m,n) = f(m-1,1) + f(m-1,2) + ... + f(m-1,n)
= f(m,n-1) + f(m-1,n) I shall refer to this statement as (Z)

We make an inner inductive statement to induct on n this time. J(M+1,N) states that for m = M+1 fixed, formula (Y) is true for n <= N.
We know from 2) that J(M+1,1) is true for all M, so we want to show that J(M+1,N) implies J(M+1,N+1) for all N >= 1, meaning we want to show f(M+1,N+1) is true under the inner inductive statement that J(M+1,N) is true and also under the outer inductive statement that H(M) is true.
Equation (Z) is in this case :

f(M+1,N+1) = f(M+1,N) + f(M,N+1)
= C(M+1+N,M+2) + C(M+N+1,M+1) by J(M+1,N) and H(M)
= C(M+N+1,M+1) by Pascal's rule

Which is what we want. This shows in the first instance that J(M+1,N+1) is true, so that the inner induction implies formula (X) is true for all n >=1 with m = M+1. And that therefore the outer induction is true for all m >=0.


So, look I know this is laid out in excessive detail, more-so than is needed by most to believe the truth of the formula that srw & I spotted but I'm trying to show that to try to explain the double induction carefully is tedious when the key equality is essentially Pascal's rule that I think is fair enough to say is a trivial identity.
 

Psycolist

NINJA BYKALIST
Location
North Essex
Sledgehammers I can cope with, this, I will leave you to it, I aint got a clue what
[QUOTE 2276073, member: 9609"]Excel is just a big sledgehammer with no finnesse

n = 400000
Do Until n = 0
tot = tot + ((n + 1) / 2 * n)
n = n - 1
Loop

excel can whizz round a little loop like that at a blistering 3million times a second. But if n was 1 trillion then that would take it 4 days, wher as the equation would only take a big bit of paper - that's the beauty of maths.

So how is it related to cycling. Some time ago I started mapping out all the roads I had cycled link, when my brother found out he started to do the same. He would just drop his route data into google earth taking no care if one road was done twice.

So I have been trying (nearly finnished) developing some macros to sort through all his routes, deleting out all the duplicated roads, and hence coming up with a true distance of all his new roads. On some test stuff it's working and I'm getting an accuracy > 99.5% so it's sort of working, still needs tweaked a bit.

The big problem is the scale of his routes, 18,000 miles ! this equates to something like 800,000 georaphical points, that works out at about 8.5*10^16 comparrisons. My first effort was going to ake the computer 16 days. I may have now got it down to about 3 hours.[/quote]

Sledgehammers I can cope with, this is complete mumbojumbo to me. Use a felt tip, it works for me !Different colours help, and little arrowheads to denote the direction you went in. IMHO another incidence of computers making a simple job difficult. :cycle:
 
Top Bottom