Math Induction HW

This is a discussion on Math Induction HW within the A Brief History of Cprogramming.com forums, part of the Community Boards category; hey all, I'm on my last problem and I'm stuck. I think it is just too late, but i desperately ...

  1. #1
    Registered User axon's Avatar
    Join Date
    Feb 2003
    Posts
    2,572

    Math Induction HW

    hey all,

    I'm on my last problem and I'm stuck. I think it is just too late, but i desperately want to finish this today. Anyhow here is what it reads:

    In any group of k people, k>=1, each person is to shake hands with every other person. Find a formula for the number of handshakes, and prove the formula using induction.

    Once i get the formula the proof is cake, but the formula is driving me crazy, and it is probably very simple.

    so here is what I have
    Code:
    1 person = 0 shakes
    2 people = 1 shake
    3 people = 3 shakes
    P(4) = 6
    P(5) = 10
    P(6) = 15
    ...and so on
    can anyone put me on the right track?

    thanks,

    axon

    some entropy with that sink? entropysink.com

    there are two cardinal sins from which all others spring: Impatience and Laziness. - franz kafka

  2. #2
    Registered User axon's Avatar
    Join Date
    Feb 2003
    Posts
    2,572
    I finally found the formula so please disregard this post!

    for all interested here it is: k( k -1 ) / 2 for k >=1

    so simple!!! and it took an hour of my life

    some entropy with that sink? entropysink.com

    there are two cardinal sins from which all others spring: Impatience and Laziness. - franz kafka

  3. #3
    Wen Resu
    Join Date
    May 2003
    Posts
    219
    Damn i was alogn those lines workign on it, ah well shoulda given me another 5 minutes

  4. #4
    Registered User axon's Avatar
    Join Date
    Feb 2003
    Posts
    2,572
    thanks anyways: if you want I have one for extra credit, here goes:

    A simple closed polygon consists of n points in the plane joined in pairs by n line segments: each point is the endpoint of exactly two line segments. Use the first and second principal of induction to prove that the sum of the interior angles of an n-sided closed polygon is ( n - 2 ) 180degrees for all n >= 3.

    I'll work on this one now, until I'm too sleepy to do anymore.

    some entropy with that sink? entropysink.com

    there are two cardinal sins from which all others spring: Impatience and Laziness. - franz kafka

  5. #5
    Registered User axon's Avatar
    Join Date
    Feb 2003
    Posts
    2,572
    well, this one was fairly simple...the proof below is using the second principal of induction:

    Code:
    when k = 3, we have a triangle. Sum of all angles = 180 so
    for each n > 3, if P(k) is true for all k with  3 <= k < n, then P(n) is true.
    
    180(k-2) + 180[(n-k+2)-2] = 180(k-2) +180(n-k)
                                                  = 180[(k-2) + (n-k)]
                                                  = 180(n-2)   => DONE
    basically you can divide each k-sided polygan with k-3 lines to form
    triangles. Multiply the number of triangles by 180....simple

    some entropy with that sink? entropysink.com

    there are two cardinal sins from which all others spring: Impatience and Laziness. - franz kafka

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Math
    By knightjp in forum A Brief History of Cprogramming.com
    Replies: 16
    Last Post: 04-01-2009, 06:36 PM
  2. how to use operator+() in this code?
    By barlas in forum C++ Programming
    Replies: 10
    Last Post: 07-09-2005, 08:22 PM
  3. Help with C++ Math
    By aonic in forum C++ Programming
    Replies: 4
    Last Post: 01-29-2005, 04:40 AM
  4. Math Header?
    By Rune Hunter in forum C++ Programming
    Replies: 26
    Last Post: 09-17-2004, 07:39 AM
  5. toughest math course
    By axon in forum A Brief History of Cprogramming.com
    Replies: 12
    Last Post: 10-28-2003, 10:06 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21