English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

For example, say I have a pile of X checks, which can have one of a known set of costs. The average value of the checks in the pile is Y. How can I find the possible arrangements (number of checks with each known cost where a total of X checks would average Y)?

This is similar to the problem of "You have $1.34 in change and 8 coins, what coins do you have". What's the best way to solve this? (I have large X and Y.)

2006-10-23 11:57:28 · 2 answers · asked by romulusnr 5 in Science & Mathematics Mathematics

2 answers

To me this sounds like a diophantine equation.

Let the set of "costs" be {x1,x2,...xn}

Let the quantity of the "checks" with that "cost" take on a variable value, say y's

then we have (y1x1+y2x2+...+ynxn)/n = average

to be precise,

y1*1+y2*5+y3*10+y4*25=134

y1+y2+y3+y4=8

things like this are tough to solve because you only have integers to deal with and not all numbers, also you only have two equations with 4 variables. Go to wikipedia or mathworld and check out diophantine equations

2006-10-23 12:34:17 · answer #1 · answered by guy232323232 2 · 0 0

http://www.youtube.com/watch?v=yJEe3hlRSE4

Sheep?

2006-10-25 09:15:42 · answer #2 · answered by Anonymous · 0 1

fedest.com, questions and answers