Senin, 14 Maret 2016

Re: [MS_AccessPros] INSPECTION

 

Dave-


I didn't think of looking at it that way, but you're right!  Nice analysis.

John Viescas, Author
Microsoft Access 2010 Inside Out
Microsoft Access 2007 Inside Out
Microsoft Access 2003 Inside Out
Building Microsoft Access Applications 
SQL Queries for Mere Mortals 
(Paris, France)



On Mar 14, 2016, at 10:19 AM, 'Dave Williams' davewillgmale@gmail.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:


John,
 
Yes indeed, that is the number of ways of selecting 6 items in any order out of 14. If all 14 items were defective, it would also be the number of ways of selecting 6 defective items.
 
However, if only 13 items were defective, to pick 6 defective would have to avoid the non-defective one, leaving one less to choose from. I think the number of ways would be 13!/(6! x (13-6)!) i.e. 1716. If only 12 items were defective, the number of ways would be 12!/(6! x (12-6)!) i.e. 924, and so on down to the case where only 6 of the 14 are defective, i.e. 1 way.
 
The original request was for 5 out of the 6 to be defective. If all 14 items were defective, no selection could give only 5. If 13 items were defective, the non-defective item would have to be selected, and I think the number of ways of selecting the other 5 would be 13!/(5! x (13-5)!) i.e. 1287. If 12 items were defective, one of the non-defectives would have to be selected, and the other one not selected, so the number of ways of selecting the other 5 would be 12!/(5! x (12-5)!) i.e. 792. and so on down to the case where only 5 of the 14 are defective, i.e. 1 way.
 
My table below has four columns: the first column is the number of defectives in the 14, the second is the number of different 6-defective selections, the third is the number of 5-defective selections, and the fourth is the number of selections having at least 5 defective, got by adding columns two and three.
 
14, 3003, 0, 3003
13, 1716, 1287, 3003
12, 924, 792, 1716
11, 462, 462, 924
10, 210, 252, 462
9, 84, 126, 210
8, 28, 56, 84
7, 7, 21, 28
6, 1, 6, 7
5, 0, 1, 1
4, 0, 0, 0
3, 0, 0, 0
2, 0, 0, 0
0, 0, 0, 0
 
All this is irrelevant to the problem of flagging which selection has 5 or more defectives, which is easy using the method posted by Andrew.
 
Dave W
----- Original Message -----
Sent: Sunday, March 13, 2016 9:57 PM
Subject: Re: [MS_AccessPros] INSPECTION

 
Dave-

That was me.  14 items taken 6 at a time is:

   14!
—————
6!(14-6)!

Or

    14!
—————
  6! 8!

Or

14*13*12*11*10*9
———————————
    6*5*4*3*2

Work it out from there.


John Viescas, Author
Microsoft Access 2010 Inside Out
Microsoft Access 2007 Inside Out
Microsoft Access 2003 Inside Out
Building Microsoft Access Applications 
SQL Queries for Mere Mortals 
(Paris, France)



On Mar 13, 2016, at 7:34 PM, 'Dave Williams' davewillgmale@gmail.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:


Ade,
 
That's 7 x 53, another prime number. How did you work that out? If we knew your method it would help to understand what you want. Also how did you get 3,003 in your other email?
 
Dave
 
----- Original Message -----
Sent: Sunday, March 13, 2016 4:45 PM
Subject: Re: [MS_AccessPros] INSPECTION

 

Hi Dave, i made a mistake. It should be 371 combinations.

Ade.





From: "'Dave Williams' davewillgmale@gmail.com [MS_Access_Professionals]" <MS_Access_Professionals@yahoogroups.com>
To: MS_Access_Professionals@yahoogroups.com
Sent: Sunday, 13 March 2016, 10:35
Subject: Re: [MS_AccessPros] INSPECTION

 

Ade,
 
How do you work out 579? It's 3 x 193 (a prime number), so does not come from ratios of factorials normally involved in numbers of combinations.
 
Dave W
 
----- Original Message -----
Sent: Saturday, March 12, 2016 1:15 PM
Subject: [MS_AccessPros] INSPECTION

Hi all,

i am looking for help with a code for combinations for an inspection problem which can be generalized to similar problems.

Suppose there are 14 items to checked for defects in lots of 6 each. The idea is to be able to  catch a lot with 5 defectives if that lot contains 5 defectives. I know combination wise, this should give 579 combinations.

Is there any way this can be handled in MSAccess ?

Thanks.

Ade.










__._,_.___

Posted by: John Viescas <johnv@msn.com>
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (17)

Save time and get your email on the go with the Yahoo Mail App
Get the beautifully designed, lighting fast, and easy-to-use, Yahoo Mail app today. Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.


.

__,_._,___

Tidak ada komentar:

Posting Komentar