Math Is Fun Forum

  Discussion about math, puzzles, games and fun.   Useful symbols: ÷ × ½ √ ∞ ≠ ≤ ≥ ≈ ⇒ ± ∈ Δ θ ∴ ∑ ∫ • π ƒ -¹ ² ³ °

You are not logged in.

#1 Help Me ! » What kind of math/programming code is this...and can you solve it? » 2015-10-06 09:32:25

NickMeyers
Replies: 1

Someone posted this on another forum, what does it mean?

tNrFAOe.jpg

I see this is Martin Cooper, but still doesn't help...

https://en.wikipedia.org/wiki/Martin_Cooper_(inventor)

#2 Re: Help Me ! » Another Combination Problem 2 » 2015-03-20 05:04:39

Anytime, thanks.  Let me know if they can figure it out.  You figured it out quick!  I am going to try to fork a problem on my own here soon.  I'll post the details and see if I get the right answer.

#3 Re: Help Me ! » Another Combination Problem 2 » 2015-03-15 17:37:41

That website was amazing! I was able to input the numbers from the previous data set and got the matching 555! 

Great thinking! This is really helpful, I really appreciate this Agnishom!

And as far as not getting 85+ on the Chemistry exam, just know you did a good job.  it's always best to avoid comparing yourself to others, and know if you work hard you can get to where ever you want to be.  There are lots of great quotes out there, but when it comes to comparing your performance to others, this is my favorite.

"The only person you should try to be better than is the person you were yesterday."

Keep up the good work!

#4 Re: Help Me ! » Another Combination Problem 2 » 2015-03-14 08:21:34

Wow!! Congratulations! You should be very proud of that!!!! Great work!!

Thanks for your help again! I will try out that website and let you know how it goes.

Keep up the great work in Chemistry!!

#5 Re: Help Me ! » Another Combination Problem 2 » 2015-03-13 08:45:23

Thanks again Agnishom!  Glad your Chemistry test went well!!  I have been studying for a big exam myself, and haven't been back on here in a bit.  If you catch this soon I have another data set I was hoping that you could run the numbers on.  But if you can't get to it  within the next 24 hours (after I posted this), then I won't be able to use it.  So thank you if you can post it quickly!  Thank you for your past help and time with these, I need to learn how to set these up myself.  How did you get started learning programming code?

{76,122,90,105,117,78,84,111,124,71,77,118,117,78,106,89,114,81}

Contraints:
Only one player from each match can be used.
There are 10 matches (A vs B, C vs D, E vs F, etc.).
5 players must be picked.
The total combined cost of the 5 picked, must be > or = to 495 and < or = to 500 (495-500)
All combinations 494 and under, or over 500 are not important.
I need to be able to generate a list of combinations, that fit this criteria, along with associated costs.


Data Set:
Match    Cost
1    A    76 
      B    122
   
2    C    90   
      D    105
   
3    E    117
      F    78
   
4    G    84
      H    111

5    I    124
      J    71
   
6    K    77   
      L    118
   
7    M    117
      N    78
   
8    O    106
      P    89
   
9    Q    114
      R    81

#6 Re: Help Me ! » Another Combination Problem 2 » 2015-02-23 17:16:40

Thats a tough one, like I said its been awhile...I don't think I would be much help with out digging out my old books...

To solve this I think you set up the equations by how they dissociate...then I am pretty sure you can use the Ksp to solve for the individual values...

Get the molar mass to convert to g/l...and I am lost...lol sorry

#7 Re: Help Me ! » Another Combination Problem 2 » 2015-02-22 05:06:27

Good luck on your exam!  That's some math I can do! lol

If you can do my problems you will do great in chemistry. I have taken general chem, organic and biochem... been a few years, but let me know if you need any help!

#8 Re: Help Me ! » Another Combination Problem 2 » 2015-02-22 03:36:45

Usually Agnishom knocks these out for me, but haven't seen him on here....

#9 Help Me ! » Another Combination Problem 2 » 2015-02-18 05:59:12

NickMeyers
Replies: 15

Hi there, I could use help with another one of these.  Thank you for all the help!!


Contraints:
Only one player from each match can be used.
There are 10 matches (A vs B, C vs D, E vs F, etc.).
5 players must be picked.
The total combined cost of the 5 picked, must be > or = to 495 and < or = to 500 (495-500)
All combinations 494 and under, or over 500 are not important.
I need to be able to generate a list of combinations, that fit this criteria, along with associated costs.



Data Set:
Match    Cost
1    A    84   
      B    119
   
2    C    91   
      D    108
   
3    E    118
      F    82
   
4    G    121
      H    78

5    I    86
      J    113
   
6    K    84   
      L    115
   
7    M    83 
      N    116
   
8    O    111
      P    88
   
9    Q    103
      R    96
   
10   S   117   
      T    82

List:
{84, 119, 91, 108, 118, 82, 121, 78, 86, 113, 84, 115, 83, 116, 111, 88, 103, 96, 117, 82}

#10 Re: Help Me ! » Another Combination Problem » 2015-02-11 07:59:36

Awesome!!! Thank you all so much!!!

#11 Re: Help Me ! » Another Combination Problem » 2015-02-10 02:46:40

I go through them by hand, one by one, to see which combinations I like, and marking off the combinations I don't like.  Having all of the possible combinations helps me not miss any, and keep track of which ones I have looked at.  It takes a long time smile

Thank you for your help!!!

#12 Help Me ! » Another Combination Problem » 2015-02-09 05:43:25

NickMeyers
Replies: 5

Hi there, I could use help with another one of these.  Thanks all!!

Contraints:
Only one player from each match can be used.
There are 10 matches (A vs B, C vs D, E vs F, etc.).
5 players must be picked.
The total combined cost of the 5 picked, must be > or = to 495 and < or = to 500 (495-500)
All combinations 494 and under, or over 500 are not important.
I need to be able to generate a list of combinations, that fit this criteria, along with associated costs.


Data Set:
Match    Cost
1    A    98   
      B    101
   
2    C    116   
      D    85
   
3    E    80
      F    118
   
4    G    106
      H    93

5    I    108
      J    92
   
6    K    120   
      L     79
   
7    M    82   
      N    107
   
8    O    100
      P    99
   
9    Q    91
      R    109
   
10   S   93   
      T    107

List:

{98, 101, 116, 85, 80, 118, 106, 93, 108, 92, 120, 79, 82, 117, 100, 99, 91, 109, 93, 107}

#13 Re: Help Me ! » Combination Problem » 2015-02-04 18:45:38

Hi Agnishom!  I have another problem if you have time, I could use your help once more!!!
Let me know if I need to clarify anything.  Same problem as before, with 10 matches.

Thank you again for your help!


Contraints:
Only one player from each match can be used.
There are 10 matches (A vs B, C vs D, E vs F, etc.).
5 players must be picked.
The total combined cost of the 5 picked, must be > or = to 495 and < or = to 500 (495-500)
All combinations 494 and under, or over 500 are not important.
I need to be able to generate a list of combinations, that fit this criteria, along with associated costs.

Data Set:

{98, 101, 116, 85, 80, 118, 106, 93, 108, 92, 120, 79, 82, 117, 100, 99, 91, 109, 93, 107}

#14 Re: Help Me ! » Combination Problem » 2015-02-01 04:50:09

Thank you Agnishom!! I really appreciate your help!!  Over the next couple weeks I will keep trying to figure out how to do this!!  The list is perfect, no errors, I went through it all, thank you!

#15 Re: Help Me ! » Combination Problem » 2015-01-28 08:50:22

Yeah no problem! You are helping me out so, just let me know anything I can do to make it easier!

Thanks!!

{119, 83, 103, 97, 108, 92, 118, 80, 102, 98, 105, 94, 117, 80, 109, 89, 107, 93}

#16 Re: Help Me ! » Combination Problem » 2015-01-26 13:24:21

I still am trying to get Haskell figured out, I have one more problem and then won't have any for a few weeks.  Hopefully in that time I can figure this out.  This one only has 9 matchups, but all of the other rules apply.

There is something I am not doing right I will continue to mess with it, but I can't figure out how to make a .hs file or anything. I will keep trying, I think I just need to read more about it.

I still have not been able to figure out how to run a script. What do I need to google to find info for this specific problem/running a script on windows? I feel like I should be smart enough to figure this out...I'll keep searching

Thanks!

Contraints:
Only one player from each match can be used.
There are 9 matches (A vs B, C vs D, E vs F, etc.).
5 players must be picked.
The total combined cost of the 5 picked, must be > or = to 495 and < or = to 500 (495-500)
All combinations 494 and under, or over 500 are not important.
I need to be able to generate a list of combinations, that fit this criteria, along with associated costs.


Data Set:
Match    Cost
1    A    119   
      B    83
   
2    C    103 
      D    97
   
3    E    108
      F    92
   
4    G    118
      H    80

5    I    102
      J    98
   
6    K    105   
      L     94
   
7    M    117   
      N    80
   
8    O    109
      P    89
   
9    Q    107
      R    93

#17 Re: Help Me ! » Combination Problem » 2015-01-24 04:59:34

Have you been up all night?!? Thanks for the help!! I really appreciate it.

The online guide is the one here http://learnyouahaskell.com/chapters its a ebook I found while looking at youtube tutorials.

I use this to try to see all the combinations available for a game, it helps me see all the different combinations, I go through each one and see what combinations I like. It's kinda weird, but fun for me.  I would like to learn how to set problems up like this on my own eventually, but this programming lingo is very complicated.

Thanks again for the help!

#18 Re: Help Me ! » Combination Problem » 2015-01-24 04:05:11

NickMeyers wrote:

If the numbers are the same, such as the two sets with 104 and 96 in the last problem, and I want to designate them as separate, what would I have to do so they show up in the results as separate numbers (such as 104a, 104b and 96a, 96b)?

You know what I just realized, if you post the results in the letter format like you did for the first combination problem, I can just copy and paste that in to Microsoft Word and use the replace function.  Where I can assign the numbers in place of the letters, and for the numbers that are the same I can just replace with the number keep the letter attached.  Which would generate the perfect list!

Any chance you could post the results in the letter format again (like here http://pastebin.com/jh4bqPUj)  for the latest problem?

#19 Re: Help Me ! » Combination Problem » 2015-01-24 03:29:35

Agnishom wrote:

We'll look into that but I want to ask you if you did figure out how to run a haskell script in Windows

Not yet, but looking through this online guide to try to figure it out. Does that involve creating a .hs file and running it?

#20 Re: Help Me ! » Combination Problem » 2015-01-23 18:13:23

I don't really know which file I need, because I am so new to this.  But this is awesome and I will give it a try! Do I insert different numbers for my new problem in this area [12,7,10,9,7,13,11,9,8,13,10,10,8,11,11,9,7,11,9,12] ?

If the numbers are the same, such as the two sets with 104 and 96 in the last problem, and I want to designate them as separate, what would I have to do so they show up in the results as separate numbers (such as 104a, 104b and 96a, 96b)?

#21 Re: Help Me ! » Combination Problem #2 » 2015-01-23 18:06:05

Thank you so much! I won't have time to do more tutorials the next few days, but I will be back with another problem with the same scenario, with different numbers on Wednesday. 

I would love to learn how to use your Haskell script, I tried a few programming tutorials, and it's rough to get into with no background!!(http://learnyouahaskell.com/chapters).

In this problem, is it possible to designate the separate 104 and 96's as 104a, 104b, 96a, 96b? Will the program allow that? It would be helpful even though I said it was unnecessary in a previous post.  I am just exploring something, and the more I find out the more important the specific results become.

Thank you for the post Agnishom!  If its easy and you have time can you post the results with the 104 and 96 designated as separate? If it's a pain and can't be done before 1500 EST 1/24/2015 I won't be able to use it, but if you can it would be incredible!

#22 Re: Help Me ! » Combination Problem » 2015-01-23 08:03:17

Like I said, I have no idea what I am doing.... I tried copying and pasting that into the Haskell WinGHCi window, but I get this message:

GHCi, version 7.8.3: http://www.haskell.org/ghc/  :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Prelude> In[7]:= Select[
  Subsets[{12, 7, 10, 9, 7, 13, 11, 9, 8, 13, 10, 10, 8, 11, 11, 9, 7,
     11, 9, 12}, {5}], Total[#] <= 50 &] // Length

<interactive>:8:27: parse error on input ‘{’

I am sure there is more to it than copying and pasting, but if this can be set up with a copy and paste, please lat me know...

Is is possible to attach/send the file?

Thanks!!!

#23 Re: Help Me ! » Combination Problem » 2015-01-23 07:37:04

Agnishom wrote:
ElainaVW wrote:

Hello,

This is a restricted partition problem from a multiset. I have run it off by computer and the answer s 206.

For an analytical answer I have sent it off to bobbym.

Hi Elaina;

I'm getting an answer of 9763. Can you check?

In[7]:= Select[
  Subsets[{12, 7, 10, 9, 7, 13, 11, 9, 8, 13, 10, 10, 8, 11, 11, 9, 7,
     11, 9, 12}, {5}], Total[#] <= 50 &] // Length

Out[7]= 9763

Also,

data Player = Player Char Int

instance Show Player where
        show (Player name _) = show [name]

players = zipWith Player ['A'..'T'] [12,7,10,9,7,13,11,9,8,13,10,10,8,11,11,9,7,11,9,12]

choose :: [b] -> Int -> [[b]]
_      `choose` 0       = [[]]
[]     `choose` _       =  []
(x:xs) `choose` k       =  (x:) `fmap` (xs `choose` (k-1)) ++ xs `choose` k

value (Player _ x) = x

check n = filter (\p -> sum(map value p) <= 50) (choose players 5)

main = print $ check 5

gives this.

Agnishom, I know nothing about programming, but if I retype this into Haskell with my new numbers will it generate the answer? I downloaded Haskell, but I don't think I am doing it right...

Any chance you could let me know how to set a problem like this up?  Is it really complicated?  Would I just be able to copy and paste the framework for it and then just add new numbers?

#24 Re: Help Me ! » Combination Problem #2 » 2015-01-22 14:38:14

Thank you Agnishom! Which program do you use to figure this out, and how hard would it be to use?

Any chance you could post the results again, with the numbers?

#25 Help Me ! » Combination Problem #2 » 2015-01-21 09:47:43

NickMeyers
Replies: 4

Thanks for the help with the last one!  I originally posted this in my old thread, but I think it got buried in there, and nobody saw it.

Here is the new problem with a narrowed range (>or = to 495 and < or = to 500 instead of 480-500) this time.
There are 4 players with the same value (in matches 5 and 7), they need to count as individuals even though they are the same cost.



Problem:

Contraints:
Only one player from each match can be used.
There are 10 matches (A vs B, C vs D, E vs F, etc.).
5 players must be picked.
The total combined cost of the 5 picked, must be > or = to 495 and < or = to 500 (495-500)
All combinations 494 and under, or over 500 are not important.
I need to be able to generate a list of combinations, that fit this criteria, along with associated costs.


Data Set:
Match    Cost
1    A    114   
      B    88
   
2    C    116   
      D    84
   
3    E    112
      F    87
   
4    G    102 
      H    98
5    I    104   
      J    96
   
6    K    103   
      L     97
   
7    M    104   
      N    96
   
8    O    106
      P    94
   
9    Q    120
      R    80
   
10   S   117   
      T    83

Results from the last one:

After using both forms of the results, Elaina's list was the easiest format to use.  I found it easier to search through when the numbers were used with the totals instead of the letters. This format:
{75, 80, 94, 118, 120, 487}
{75, 80, 94, 118, 127, 494}
{75, 80, 94, 120, 127, 496}

Even if there are players with the same cost, this still works for me, as long as there are counted and listed as individuals. The one like this last week were usable, there are 2 sets with the same costs this week.
{75, 94, 94, 109, 127, 499}
{75, 94, 94, 114, 118, 495}
{75, 94, 94, 114, 120, 497}

Let me know if I can clarify any questions.  Thank you for the help!!

Board footer

Powered by FluxBB