Difference between revisions of "1983 AIME Problems/Problem 13"

m (fixed typo)
m (Formatting fixes)
 
(12 intermediate revisions by 9 users not shown)
Line 1: Line 1:
 
== Problem ==
 
== Problem ==
<!-- don't remove the following tag, for PoTW on the Wiki front page--><onlyinclude>For <math>\{1, 2, 3, \ldots, n\}</math> and each of its non-empty subsets, an alternating sum is defined as follows. Arrange the number in the subset in decreasing order and then, beginning with the largest, alternately add and subtract successive numbers. For example, the alternating sum for <math>\{1, 2, 4, 6,9\}</math> is <math>9-6+4-2+1=6</math> and for <math>\{5\}</math> it is simply <math>5</math>. Find the sum of all such alternating sums for <math>n=7</math>.<!-- don't remove the following tag, for PoTW on the Wiki front page--></onlyinclude>
+
<!-- don't remove the following tag, for PoTW on the Wiki front page--><onlyinclude>For <math>\{1, 2, 3, \ldots, n\}</math> and each of its non-empty subsets a unique '''alternating sum''' is defined as follows. Arrange the numbers in the subset in decreasing order and then, beginning with the largest, alternately add and subtract successive numbers. For example, the alternating sum for <math>\{1, 2, 3, 6,9\}</math> is <math>9-6+3-2+1=5</math> and for <math>\{5\}</math> it is simply <math>5</math>. Find the sum of all such alternating sums for <math>n=7</math>.<!-- don't remove the following tag, for PoTW on the Wiki front page--></onlyinclude>
  
== Solution 1==
+
== Solution ==
 +
 
 +
=== Solution 1 ===
 
Let <math>S</math> be a non-[[empty set | empty]] [[subset]] of <math>\{1,2,3,4,5,6\}</math>.  
 
Let <math>S</math> be a non-[[empty set | empty]] [[subset]] of <math>\{1,2,3,4,5,6\}</math>.  
  
Then the alternating sum of <math>S</math> plus the alternating sum of <math>S</math> with 7 included is 7. In mathematical terms, <math>S+ (S\cup 7)=7</math>. This is true because when we take an alternating sum, each term of <math>S</math> has the opposite sign of each corresponding term of <math>S\cup 7</math>.
+
Then the alternating sum of <math>S</math>, plus the alternating sum of <math>S \cup \{7\}</math>, is <math>7</math>. This is because, since <math>7</math> is the largest element, when we take an alternating sum, each number in <math>S</math> ends up with the opposite sign of each corresponding element of <math>S\cup \{7\}</math>.
 +
 
 +
Because there are <math>2^{6}=64</math> of these pairs of sets, the sum of all possible subsets of our given set is <math>64 \cdot 7</math>, giving an answer of <math>\boxed{448}</math>.
 +
 
 +
=== Solution 2 (almost the same as Solution 1) ===
 +
 
 +
Consider a given subset <math>T</math> of <math>S</math> that contains <math>7</math>; then there is a subset <math>T'</math> which contains all the elements of <math>T</math> except for <math>7</math>, and only those elements . Since each element of <math>T'</math> has one fewer element preceding it than it does in <math>T</math>, their signs are opposite. Thus the sum of the alternating sums of <math>T</math> and <math>T'</math> is equal to 7. There are <math>2^6</math> subsets containing 7, so our answer is <math>7 \cdot 2^6 = \boxed{448}</math>.
 +
 
 +
=== Solution 3 ===
 +
 
 +
Denote the desired total of all alternating sums of an <math>n</math>-element set as <math>S_n</math>. We are looking for <math>S_7</math>. Notice that all alternating sums of an <math>n</math>-element set are also alternating sums of an <math>n+1</math>-element set. However, when we go from an <math>n</math> to <math>n+1</math> element set, for each subset with the new element, we are adding the new element and subtracting one of the alternating sums of the <math>n</math>-element set. There are <math>2^n</math> subsets of an <math>n+1</math>-element set that includes the new element, giving us the relationship <math>S_{n+1} = S_n + 2^n(n+1) - S_n = 2^n(n+1)</math>. When <math>n = 6</math>, we therefore get <math>S_ 7 = 2^6(7) = \boxed{448}</math>.
 +
 
 +
=== Solution 4 ===
 +
 
 +
We analyze all the numbers from 1 to 7 separately to see where the number contributes its positive or negative to the sum of the alternating sums. Whenever 7 appears, which it does 64 times, it contributes a positive because it is always first. This gives a net gain of <math>7 \cdot 64=448</math>.
 +
 
 +
If we look at when 6 appears, which it also does 64 times, whether it comes as positive or negative depends on the presence of 7. Half of the subsets with 6 have 7 resulting in subtracting 6 each time, while the other half does not have 7 adding 6 each time, so these contributions of sixes cancel each other out giving a net gain of 0.
  
Because there are <math>63</math> of these pairs, the sum of all possible subsets of our given set is <math>63*7</math>. However, we forgot to include the subset that only contains <math>7</math>, so our answer is <math>64\cdot 7=\boxed{448}</math>.
+
The same thing happens to any positive integer less than 7. This is because the determination of a positive or negative contribution is dependent on the number of larger numbers in front of it(For example, the sign of 3 is dependent on the presence of 4, 5, 6, and 7 in the subset). If the number of larger numbers is even, it gives in a positive copy while odd produces its negative. We know that the frequencies of these two cases occurring are the same because <math>0=(1-1)^{n}=\binom{n}{0}-\binom{n}{1}+\binom{n}{2}-...\binom{n}{n}</math> via the Binomial Theorem. Therefore, all positive integers less than 7 will not have any effect and our sum will be <math>\boxed{448}</math>.
  
== Solution 2==
+
=== Solution 5 ===
  
Consider a given subset <math>T</math> of <math>S</math> that contains 7; then there is a subset <math>T'</math> which contains all the elements of <math>T</math> except for 7, and only those. Since each element of <math>T'</math> has one element fewer preceding it than it does in <math>T</math>, their signs are opposite; so the sum of the alternating sums of <math>T</math> and <math>T'</math> is equal to 7. There are <math>2^6</math> subsets containing 7, so our answer is <math>7 * 2^6 = \boxed{448}</math>.
+
Let <math>\mathbb{N}_n := \{1, 2, 3, \dots n\}</math>. Let the alternating sum of a certain subset of <math>S</math> of <math>\mathbb{N}_n</math> be <math>\xi(S),</math> and let <cmath>\mathcal{A}(\mathbb{N}_n) := \sum_{S \subseteq \mathbb{N}_n} \xi(S).</cmath> We see that <cmath>\mathcal{A}(\mathbb{N}_n) = \sum_{S \subseteq \mathbb{N}_n} \xi(S) = \sum_{n \in S, S \subseteq \mathbb{N}_n} \xi(S) + \sum_{S \subseteq \mathbb{N}_{n-1}} \xi(S) = \mathcal{A}(\mathbb{N}_{n-1}) + \sum_{n \in S, S \subseteq \mathbb{N}_n} \left( n - \xi(S - \{n\}) \right),</cmath> as if <math>n \in S,</math> <math>n</math> is the largest element in <math>S.</math> Now, we know that <cmath>\sum_{n \in S, S \subseteq \mathbb{N}_n} n - \xi(S - \{n\}) = \sum_{S \subseteq \mathbb{N}_{n-1}} n - \xi(S) = n \cdot 2^{n-1} - \sum_{S \subseteq \mathbb{N}_{n-1}} \xi(S) = n \cdot 2^{n-1} - \mathcal{A}(\mathbb{N}_{n-1}),</cmath> so <cmath>\mathcal{A}(\mathbb{N}_{n}) = n \cdot 2^{n-1}.</cmath> Thus, our answer (which is the <math>n = 7</math> case) is <math>\mathcal{A}(\mathbb{N}_{7}) = 7 \cdot 2^6 = \boxed{448}.</math>
  
 
== See Also ==
 
== See Also ==

Latest revision as of 14:29, 22 August 2020

Problem

For $\{1, 2, 3, \ldots, n\}$ and each of its non-empty subsets a unique alternating sum is defined as follows. Arrange the numbers in the subset in decreasing order and then, beginning with the largest, alternately add and subtract successive numbers. For example, the alternating sum for $\{1, 2, 3, 6,9\}$ is $9-6+3-2+1=5$ and for $\{5\}$ it is simply $5$. Find the sum of all such alternating sums for $n=7$.

Solution

Solution 1

Let $S$ be a non- empty subset of $\{1,2,3,4,5,6\}$.

Then the alternating sum of $S$, plus the alternating sum of $S \cup \{7\}$, is $7$. This is because, since $7$ is the largest element, when we take an alternating sum, each number in $S$ ends up with the opposite sign of each corresponding element of $S\cup \{7\}$.

Because there are $2^{6}=64$ of these pairs of sets, the sum of all possible subsets of our given set is $64 \cdot 7$, giving an answer of $\boxed{448}$.

Solution 2 (almost the same as Solution 1)

Consider a given subset $T$ of $S$ that contains $7$; then there is a subset $T'$ which contains all the elements of $T$ except for $7$, and only those elements . Since each element of $T'$ has one fewer element preceding it than it does in $T$, their signs are opposite. Thus the sum of the alternating sums of $T$ and $T'$ is equal to 7. There are $2^6$ subsets containing 7, so our answer is $7 \cdot 2^6 = \boxed{448}$.

Solution 3

Denote the desired total of all alternating sums of an $n$-element set as $S_n$. We are looking for $S_7$. Notice that all alternating sums of an $n$-element set are also alternating sums of an $n+1$-element set. However, when we go from an $n$ to $n+1$ element set, for each subset with the new element, we are adding the new element and subtracting one of the alternating sums of the $n$-element set. There are $2^n$ subsets of an $n+1$-element set that includes the new element, giving us the relationship $S_{n+1} = S_n + 2^n(n+1) - S_n = 2^n(n+1)$. When $n = 6$, we therefore get $S_ 7 = 2^6(7) = \boxed{448}$.

Solution 4

We analyze all the numbers from 1 to 7 separately to see where the number contributes its positive or negative to the sum of the alternating sums. Whenever 7 appears, which it does 64 times, it contributes a positive because it is always first. This gives a net gain of $7 \cdot 64=448$.

If we look at when 6 appears, which it also does 64 times, whether it comes as positive or negative depends on the presence of 7. Half of the subsets with 6 have 7 resulting in subtracting 6 each time, while the other half does not have 7 adding 6 each time, so these contributions of sixes cancel each other out giving a net gain of 0.

The same thing happens to any positive integer less than 7. This is because the determination of a positive or negative contribution is dependent on the number of larger numbers in front of it(For example, the sign of 3 is dependent on the presence of 4, 5, 6, and 7 in the subset). If the number of larger numbers is even, it gives in a positive copy while odd produces its negative. We know that the frequencies of these two cases occurring are the same because $0=(1-1)^{n}=\binom{n}{0}-\binom{n}{1}+\binom{n}{2}-...\binom{n}{n}$ via the Binomial Theorem. Therefore, all positive integers less than 7 will not have any effect and our sum will be $\boxed{448}$.

Solution 5

Let $\mathbb{N}_n := \{1, 2, 3, \dots n\}$. Let the alternating sum of a certain subset of $S$ of $\mathbb{N}_n$ be $\xi(S),$ and let \[\mathcal{A}(\mathbb{N}_n) := \sum_{S \subseteq \mathbb{N}_n} \xi(S).\] We see that \[\mathcal{A}(\mathbb{N}_n) = \sum_{S \subseteq \mathbb{N}_n} \xi(S) = \sum_{n \in S, S \subseteq \mathbb{N}_n} \xi(S) + \sum_{S \subseteq \mathbb{N}_{n-1}} \xi(S) = \mathcal{A}(\mathbb{N}_{n-1}) + \sum_{n \in S, S \subseteq \mathbb{N}_n} \left( n - \xi(S - \{n\}) \right),\] as if $n \in S,$ $n$ is the largest element in $S.$ Now, we know that \[\sum_{n \in S, S \subseteq \mathbb{N}_n} n - \xi(S - \{n\}) = \sum_{S \subseteq \mathbb{N}_{n-1}} n - \xi(S) = n \cdot 2^{n-1} - \sum_{S \subseteq \mathbb{N}_{n-1}} \xi(S) = n \cdot 2^{n-1} - \mathcal{A}(\mathbb{N}_{n-1}),\] so \[\mathcal{A}(\mathbb{N}_{n}) = n \cdot 2^{n-1}.\] Thus, our answer (which is the $n = 7$ case) is $\mathcal{A}(\mathbb{N}_{7}) = 7 \cdot 2^6 = \boxed{448}.$

See Also

1983 AIME (ProblemsAnswer KeyResources)
Preceded by
Problem 12
Followed by
Problem 14
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
All AIME Problems and Solutions
Invalid username
Login to AoPS