Question

Suppose you begin with a pile of n stones and split this pile into n piles...

Suppose you begin with a pile of n stones and split this pile into n piles of one stone each by successively split- ting a pile of stones into two smaller piles. Each time you split a pile you multiply the number of stones in each of the two smaller piles you form, so that if these piles have r and s stones in them, respectively, you compute rs. Show that no matter how you split the piles, the sum of the products computed at each step equals n(n - 1)/2.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Proof by induction:

If you have one stone, you do no splitting, and 1*0/2 = 0, which is correct.
If you have two stones, you have to split into two piles of size 1.
1 * 1 = 1. n(n-1)/2 = 2(2-1)/2 = 2*1/2 = 2/2 = 1. Correct.
Assume for n = k.
Show for n = k + 1.
When you split the pile of size k+1, you split this into 2 piles of size x and k+1-x, where 1 <= x <= k
Thus, your first product is x(k+1 -x)
By assumption, the pile of size x, when broken up, will yield a product of
x(x-1)/2 and the pile of size k+1-x will yield a pile of size (k+1-x)(k+1-x-1)/2
x(k+1 -x) + x(x-1)/2 + (k+1-x)(k+1-x-1)/2 = (noting that k+1-x-1 = k - x)
xk + x - x2 + x2/ 2 - x/2 + k2 /2 -kx/2 + k/2 - x/2 -kx/2 + x2/ 2 =
k2 /2 + k/2 + xk -kx/2 -kx/2 + x - x/2 - x/2 - x2 + x2/ 2 + x2/ 2 =
k2 /2 + k/2 =
(k+1)(k)/2 =
(k+1)(k+1-1)/2 which is what we were trying to prove.

Add a comment
Know the answer?
Add Answer to:
Suppose you begin with a pile of n stones and split this pile into n piles...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Answer the following Nim game style questions. (Robert's Game) In this game, two players take turns removing stones from a pile that begins with n stones. The player who takes the last stone w...

    Answer the following Nim game style questions. (Robert's Game) In this game, two players take turns removing stones from a pile that begins with n stones. The player who takes the last stone wins. A player removes either one stone or p stones, where p is a prime dividing the number of stones in the pile at the start of the turn For which n does the First Player have a winning strategy? A winning strategy for the First Player...

  • a) Suppose you collect a SRS of size n from a population and from the data...

    a) Suppose you collect a SRS of size n from a population and from the data collected you computed a 95% confidence interval for the mean of the population. Which of the following would produce a new confidence interval with larger width (larger margin of error) based on these same data? A. Use a larger confidence level. B. Use a smaller confidence level. C. Nothing can guarantee absolutely that you will get a larger interval. One can only say the...

  • Problem 2. Ripple Carry and Carry Look-ahead Adders For the binary adding circuit that adds n-bit...

    Problem 2. Ripple Carry and Carry Look-ahead Adders For the binary adding circuit that adds n-bit inputs x and y, the following equation gives ci+1 (the carry out bit from the i" position) in terms of the inputs for the ih bit sum x, yi, and ci (the carry-in bit): Letting gi xiyi and pi = xi+yi, this can be expressed as: ci+1 = gi+piCi a) In a ripple carry adder structure, the carry bits are computed sequentially. That is,...

  • Suppose you have a sorted array of positive and negative integers and would like to determine...

    Suppose you have a sorted array of positive and negative integers and would like to determine if there exist some value of x such that both x and -x are in the array. Consider the following three algorithms: Algorithm #1: For each element in the array, do a sequential search to see if its negative is also in the array. Algorithm #2:For each element in the array, do a binary search to see if its negative is also in the...

  • Suppose you have a sorted array of positive and negative integers and would like to determine...

    Suppose you have a sorted array of positive and negative integers and would like to determine if there exist some value of x such that both x and -x are in the array. Consider the following three algorithms: Algorithm #1: For each element in the array, do a sequential search to see if its negative is also in the array. Algorithm #2:For each element in the array, do a binary search to see if its negative is also in the...

  • 1.Given an int variable n that has been initialized to a positive value and, in addition,...

    1.Given an int variable n that has been initialized to a positive value and, in addition, int variables k and total that have already been declared, use a for loop to compute the sum of the cubes of the first n whole numbers, and store this value in total. Thus if n equals 4, your code should put 1*1*1 + 2*2*2 + 3*3*3 + 4*4*4 into total. Use no variables other than n, k, and total.(c++) 2.Given an int variable...

  • Problem 3: Design Problem On Figure P3a, you have a Common Source (CS) n-channel MOSFET amplifier....

    Problem 3: Design Problem On Figure P3a, you have a Common Source (CS) n-channel MOSFET amplifier. Notice the absence of a source resistor Rsig and load resistor R. If we know how the present amplifier (the one on Figure P3a) behaves without Rsig and RL, we can infer its behaviors if Rsig and R were to be added. design the amplifier circuit on Figure P3a, i.e., you have to find appropriate values for RGj You are to RG,, RD, and...

  • I need help writing python code with following instructions. You will write a program that reads...

    I need help writing python code with following instructions. You will write a program that reads a data file. The data file contains ticket IDs and ticket prices. Your job is to read these tickets (and prices). find minimum, maximum and average ticket prices and output a report file. The report file should look exactly (or better than) the one attached (output.txt). Input: A31 149.99 B31 49.99 A41 179.99 F31 169.99 A35 179.99 A44 169.99 open "input.txt" file using open()...

  • Let's say you are given a sequence of distinct positive numbers. We want to find a...

    Let's say you are given a sequence of distinct positive numbers. We want to find a subsequence with the maximum possible sum, with the restriction that we are not allowed to take three consecutive elements from the original sequence. For example, for input 1, 6, 5, 2, 7, 9, 3, 4, the subsequence with the maximum possible sum is 6, 5, 7, 9, 4 (we have two pairs of consecutive elements 6, 5 and 7, 9 but not three consecutive...

  • QUESTION 3 (10 Marks) Suppose you are given an array A[0..n 1 of integers, each of...

    QUESTION 3 (10 Marks) Suppose you are given an array A[0..n 1 of integers, each of which may be positive, negative, or zero. A contiguous subarray A|i..j] which includes all the items starting at array index i and ending at array index j is called a positive interval if the sum of its entries is at least zero. For example let A-{-1, 3,-5, 2, 0,-4, 3,-6,-2). Ten A[3, 6) is a positive interval since its sum is 2+0+(-4)+3-1, but Al4,7isnot...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT