You are not logged in.
I'm not sure if I've got your meaning right. Is it this?...
From a group of 50 people, what is the maximum number who only have a single handshake, so that the total number of handshakes by the group exceeds 500 by no more than 50?
If so, then my answer is this:
Hi thickhead;
That is a trickily worded question!
Still wrestling with the wording, though...
Hi denis_gylaev;
1) Big hint: Extend UT to meet RS...
Hi;
Here's a graphic solution:
Hi thickhead;
Yes, your method works fine!
Oh...I overlooked that.
I think your answer is right, but I haven't checked your method yet. Gotta go out now for a couple of hours at least, and I'll look at it again later.
Hi samuel.bradley.99;
A bit wordy...someone else may be able to put it more concisely.
Thanks for clearing that up for me, thickhead...I hadn't been able to find out any information about that anywhere.
Btw, I think that in your previous post you meant PQT for the altitude, not PQR (as per the question)...but the answer would be the same.
Hi math9maniac;
"(b) the height of triangle PQT;"
Do you know which of the three heights the question is asking for?
There are three options, and we're not told which side is the base or which point is the height vertex...and I haven't been able to confirm if what I wrote in post #9 about notation applies.
Hi Bob,
Sorry, I didn't mean to correct you where there was no need, but you did throw me earlier by saying that you'd improved your diagram by making it accurately to scale, and I hadn't understood what you meant by that.
I had uploaded it, but was in the middle of changing it. Fixed now.
Hi Bob & math9maniac;
I get a different shape from Bob's, which seems to have PQ=approx 25 instead of 20.
Also, I think I recall from school that the apex of a triangle in relation to its height is denoted by the middle letter (same as for an angle). If that's right, then "the height of triangle PQT" would be QB in my drawing.
Hi Bobby,
You may not have been able to keep up with all the edits to my previous post, where I said I've now worked out how to print the 2291229 solutions, but anyway, here are the positions of the two examples of maximum solutions I gave there, this time from the list of solutions instead of from the full tuples list.
Men: {mmkmmwmmwmmkmmk}...position 91303.
Women: {wmwmwkwkwmwkwmw}...position 893225.
Hi Bobby,
My code covers the range of 1 to 15 seats, but I'll concentrate just on the 15 seats option, for which the code would be:
Count[StringFreeQ[Map[StringJoin,Tuples[{"m", "w", "k"},{15}]],{"ww","mmm"}],True]
There are 14348907 tuples, ranging from "mmmmmmmmmmmmmmm" through "wwwwwwwwwwwwwww" to "kkkkkkkkkkkkkkk".
StringJoin maps over Tuples to concatenate the comma-delimited tuples format to make it easier for me to work with.
StringFreeQ yields "False" for any items that contain either "ww" or "mmm", and "True" for any that don't.
Count yields the total number of "True" results...which is 2291229 (Anna's answer, and my Excel's).
So we can have 10 men at maximum and 8 women at maximum, if this is of any help
A search through the 14348907 tuples for the valid maximum arrangements you mentioned found 640 (ie, 5(2^7)) for 10 men and 128 (ie, 2^7) for 8 women.
Here's one example of each:
Men: {mmkmmwmmwmmkmmk}...position 1083351.
Women: {wmwmwkwkwmwkwmw}...position 5424635.
------------------------------------------------------------------------------------------------------------------
I haven't been able to work out how to create a list of the 2291229 valid arrangements. StringFreeQ only yields "True" or "False", and I can't get any more info from it than that. I've tried other functions (eg, Cases, DeleteCases, Select), but I must be doing it wrong. Not knowing much about patterns probably doesn't help.
So, the "search through the 14348907 tuples" I mentioned above was through Excel, which I trust as being as correct as M's results because they're identical for all 1 to 15 levels...and my M code is based on my Excel method. Also, I found the 1083351 and 5424635 positions with Notepad++ from a csv file I created with M of the 14348907 tuples.
Could you help me with creating the list in M of the 2291229 valid arrangements, please? I've tried and tried, but am totally stuck. Thanks!
So far I've got this to work:
EDIT: Found something on SE that works, and prints all 2291229 solutions:
Got it!
I hadn't been able to work out how to use the Tuples output with its multiple comma-separated elements for each item in the list, but then succeeded by applying StringJoin to it (which I'd tried before but wasn't doing it properly). That then made it easier (for me) to test list items for "ww" or "mmm" content.
Btw, when I changed my Excel code (I mentioned that in post #31), that sped up the calcs enormously, and also reduced the file size from 1.4GB to 375MB. But M puts that to shame with its 13KB file size (including output)!
I would have saved hours if I'd spent just a few more minutes finding this instead of persevering with Excel (which I didn't mind doing, though).
The code calculates and prints all 15 levels in just under 30 seconds.
Not yet. I've tried again, but still can't get past a major obstacle that's holding up progress. I may need your help with that, but I'll give it another go first.
Hi all;
So 13 & 14 can wait...but looking at the progression I'd say they'd be around 331337 and 871303 respectively.
Yes, those figures are correct, based on the method I've used for the other levels.
Hi all;
(if your other values are correct).
I hope my logic's ok.
Here's an example copy of my 3-column spreadsheet layout that shows what I did. I used the 5-seat option to keep the list to a manageable size.
Column B is M's copy/paste output of all 243 permutations for 5 seats.
Column A tests column B entries for either a "ww" or "mmm" content, and identifies, via incremental numbering, all valid seating arrangements.
Column C's first cell displays column A's last number.
The other seating numbers options use this same method.
EDIT: I've since changed column A's code, as evaluation for >10 seats was unacceptably slooooow. This means that the incremental numbering is no longer reported there - only "TRUE" or "FALSE". That also meant changing C1's code, but the totals remain unchanged.
Hi all;
Sorry I joined this so late, but it all looked too difficult. Anyway, I had some spare time the last couple of days (which I sure needed for this!) and have some answers.
I got the same end result as Anna: 2291229.
And here are my answers for the other 'levels':
I didn't do 13 & 14, because I went the slow way by using Excel (with some help from M and Notepad++), and the way I did it produced a huuuuge 1.4GB file that wasn't exactly motoring along for the 15 seats level! So 13 & 14 can wait...but looking at the progression I'd say they'd be around 331337 and 871303 respectively.
I tried coding the problem in M and nearly got there, so I might keep going with it...
Hi Enshrouded_;
1. Does this help...?
Hi Calligar;
That link doesn't work for me either; Hulu says their movies "can only be streamed within the United States". Anyway, I have seen both the English dubbed and captioned versions elsewhere (but I don't recall where), and the YouTube version will do for me if I need to refer to the movie again, even though the top and bottom are cut off.
I guess we'll never really know the correct answer to Kaito's puzzle (and hence yours), but I favour my reasoning in post #7 for both puzzles.
Hi Calligar;
I can't access the movie from your link, because I get this error: "Sorry, this video is not available in your region due to licensing restrictions." My region is Australia.
There's an English dubbed version on YouTube here, and the puzzle appears at 5:38.
Btw, re the hide box (etc), you can always see how other posters have done it by clicking the 'Quote' button in the bottom right-hand corner of a post...but only if you're logged in.
Hi Calligar;
Oo...didn't know that one!
Hi;
I also got 13°, in Geogebra.