Results 1 to 4 of 4

Math Help - Solving for a, b and c

  1. #1
    Newbie milkntea's Avatar
    Joined
    Mar 2010
    Posts
    3

    Solving for a, b and c

    Do you know of any algorithm that can solve (look for possible values) for a, b and c in the equation:

    a + b + c = n

    where a, b, c and n are integers and are greater than 0?
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Super Member

    Joined
    May 2006
    From
    Lexington, MA (USA)
    Posts
    11,719
    Thanks
    635
    Hello, milkntea!

    Do you know of any algorithm that can solve for a, b, c in the equation:

    . . a + b + c \:=\: n . for a,b,c,n \,\in\, I^+
    Here's a primitive approach . . .


    Suppse n = 7 . . . We have 7 objects.

    Place them in a row with a space between then: . o\;\_\;o\;\_\;o\;\_\;o\;\_\;o\;\_\;o\;\_\;o


    Select two of the spaces and insert "dividers".

    So that: . o\;|\;o\;o\;o\;o\;|\;o\;o .represents 1+4+2

    . . .And: . o\;o\;o\;|\;o\;o\;|\;o\;o .represents 3+2+2


    Hence, there are: . {6\choose2} \,=\,15 possible solutions.


    I'll leave it to you to list them . . .
    .
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Newbie milkntea's Avatar
    Joined
    Mar 2010
    Posts
    3
    Quote Originally Posted by Soroban View Post
    Hello, milkntea!

    Here's a primitive approach . . .


    Suppse n = 7 . . . We have 7 objects.

    Place them in a row with a space between then: . o\;\_\;o\;\_\;o\;\_\;o\;\_\;o\;\_\;o\;\_\;o


    Select two of the spaces and insert "dividers".

    So that: . o\;|\;o\;o\;o\;o\;|\;o\;o .represents 1+4+2

    . . .And: . o\;o\;o\;|\;o\;o\;|\;o\;o .represents 3+2+2


    Hence, there are: . {6\choose2} \,=\,15 possible solutions.


    I'll leave it to you to list them . . .
    .
    Thanks Soroban!

    I am using this for a computer program that looks for

    a+b+c = 1000

    where:

    a^2 + b^2 = c^2

    I'll try it myself for now, I'll ask more questions later

    Thanks again!
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Newbie milkntea's Avatar
    Joined
    Mar 2010
    Posts
    3
    Quote Originally Posted by milkntea View Post
    Thanks Soroban!

    I am using this for a computer program that looks for

    a+b+c = 1000

    where:

    a^2 + b^2 = c^2

    I'll try it myself for now, I'll ask more questions later

    Thanks again!
    One thought:

    What if I add another condition?

    (a>b>c)
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Solving for x
    Posted in the Algebra Forum
    Replies: 1
    Last Post: January 21st 2011, 07:16 AM
  2. help solving for y
    Posted in the Algebra Forum
    Replies: 2
    Last Post: November 1st 2009, 10:25 AM
  3. Solving z^n = C
    Posted in the Algebra Forum
    Replies: 2
    Last Post: April 23rd 2009, 05:50 AM
  4. Please help with solving for zero
    Posted in the Algebra Forum
    Replies: 1
    Last Post: February 12th 2009, 04:46 PM
  5. Replies: 3
    Last Post: October 11th 2006, 09:15 PM

Search Tags


/mathhelpforum @mathhelpforum