sum 100 from given values and limits
古いコメントを表示
Hi all, I'd like to find values that sum 100 between these 4 values and their limits:
low high
31.5 33.4
15.3 16.8
47.2 49.1
3.0 3.7
For example a solution could be:
32.0
15.3
49.0
3.7
-------
100
Please help me ;)
Cristiano.
1 件のコメント
Matt Kindig
2013 年 10 月 10 日
編集済み: Matt Kindig
2013 年 10 月 10 日
There are an infinite number of solutions to this problem. Do you just need one that works (i.e., a feasible solution)?
採用された回答
その他の回答 (1 件)
Image Analyst
2013 年 10 月 10 日
0 投票
Do you have an array that you're checking to see if its elements are in any one of those 4 ranges? Probably none of them will sum exactly to 100. See the FAQ: http://matlab.wikia.com/wiki/FAQ#Why_is_0.3_-_0.2_-_0.1_.28or_similar.29_not_equal_to_zero.3F YOu can either go greater than 100 or within some tolerance of 100 like the FAQ shows.
カテゴリ
ヘルプ センター および File Exchange で General Applications についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!