Results 1 to 8 of 8

Math Help - divisibility/combinations problem

  1. #1
    Member
    Joined
    Nov 2009
    Posts
    80

    divisibility/combinations problem

    how many different positive integers less than 1000 are divisible by 3 or 5 or 7?

    i've got an answer, but i'd like to see another person's approach.
    Last edited by jmedsy; December 14th 2009 at 06:14 AM.
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Junior Member SirOJ's Avatar
    Joined
    Dec 2009
    Posts
    45
    I just wrote up a quick java algorithim to solve this and got 544 numbers divisible by 3,5, or 7 if that's any use to you...
    Follow Math Help Forum on Facebook and Google+

  3. #3
    MHF Contributor

    Joined
    Aug 2006
    Posts
    18,922
    Thanks
    1762
    Awards
    1
    Quote Originally Posted by jmedsy View Post
    how many different positive integers less than 1000 are divisible by 3 or 5 or 7? i've got an answer, but i'd like to see another person's approach.
    Use the floor function.
    \left\lfloor {\frac{{999}}<br />
{3}} \right\rfloor  + \left\lfloor {\frac{{999}}<br />
{5}} \right\rfloor  + \left\lfloor {\frac{{999}}<br />
{7}} \right\rfloor  - \left\lfloor {\frac{{999}}<br />
{{15}}} \right\rfloor  - \left\lfloor {\frac{{999}}<br />
{{21}}} \right\rfloor  - \left\lfloor {\frac{{999}}<br />
{{35}}} \right\rfloor  + \left\lfloor {\frac{{999}}<br />
{{105}}} \right\rfloor
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Member
    Joined
    Nov 2009
    Posts
    80
    Quote Originally Posted by Plato View Post
    Use the floor function.
    \left\lfloor {\frac{{999}}<br />
{3}} \right\rfloor  + \left\lfloor {\frac{{999}}<br />
{5}} \right\rfloor  + \left\lfloor {\frac{{999}}<br />
{7}} \right\rfloor  - \left\lfloor {\frac{{999}}<br />
{{15}}} \right\rfloor  - \left\lfloor {\frac{{999}}<br />
{{21}}} \right\rfloor  - \left\lfloor {\frac{{999}}<br />
{{35}}} \right\rfloor  + \left\lfloor {\frac{{999}}<br />
{{105}}} \right\rfloor
    why add that final term?
    Follow Math Help Forum on Facebook and Google+

  5. #5
    MHF Contributor

    Joined
    Aug 2006
    Posts
    18,922
    Thanks
    1762
    Awards
    1
    Quote Originally Posted by jmedsy View Post
    why add that final term?
    Do you fully understand the inclusion/exclusion principle?
    Follow Math Help Forum on Facebook and Google+

  6. #6
    Member
    Joined
    Nov 2009
    Posts
    80
    Quote Originally Posted by Plato View Post
    Do you fully understand the inclusion/exclusion principle?
    my professor skipped a few lessons in order to make time for the final. in doing that I think he may have avoided teaching this. what's the inclusion-exclusion principle?

    my answer was that sum, but without the final term
    Follow Math Help Forum on Facebook and Google+

  7. #7
    MHF Contributor

    Joined
    Aug 2006
    Posts
    18,922
    Thanks
    1762
    Awards
    1
    You must understand the inclusion/exclusion princple to understand the solution.
    \left| {3 \vee 5 \vee 7} \right| = \left| 3 \right| + \left| 5 \right| + \left| 7 \right| - \left| {3 \wedge 5} \right| - \left| {3 \wedge 7} \right| - \left| {7 \wedge 5} \right| + \left| {3 \wedge 5 \wedge 7} \right|
    Follow Math Help Forum on Facebook and Google+

  8. #8
    Member
    Joined
    Nov 2009
    Posts
    80
    Quote Originally Posted by Plato View Post
    You must understand the inclusion/exclusion princple to understand the solution.
    \left| {3 \vee 5 \vee 7} \right| = \left| 3 \right| + \left| 5 \right| + \left| 7 \right| - \left| {3 \wedge 5} \right| - \left| {3 \wedge 7} \right| - \left| {7 \wedge 5} \right| + \left| {3 \wedge 5 \wedge 7} \right|
    found it several chapters ahead, thanks. i'll be moving on to my isbn problem which has a thread in the discrete math section. please have a look at it.
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Divisibility Problem(2)
    Posted in the Number Theory Forum
    Replies: 3
    Last Post: September 18th 2010, 02:02 PM
  2. Divisibility Problem
    Posted in the Number Theory Forum
    Replies: 13
    Last Post: September 17th 2010, 06:40 AM
  3. A divisibility problem
    Posted in the Number Theory Forum
    Replies: 6
    Last Post: August 19th 2010, 09:21 PM
  4. A divisibility problem 3
    Posted in the Number Theory Forum
    Replies: 1
    Last Post: February 27th 2010, 05:15 PM
  5. GCD divisibility problem
    Posted in the Number Theory Forum
    Replies: 1
    Last Post: May 4th 2009, 02:14 AM

Search Tags


/mathhelpforum @mathhelpforum