[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y ] [Home]
4chanarchives logo
lets see you solve linear programming
Images are sometimes not shown due to bandwidth/network limitations. Refreshing the page usually helps.

You are currently reading a thread in /wsr/ - Worksafe Requests

Thread replies: 12
Thread images: 2
File: IMG_20160330_195257.jpg (3 MB, 4128x3096) Image search: [Google]
IMG_20160330_195257.jpg
3 MB, 4128x3096
lets see you solve linear programming
>>
File: IMG_20160330_195315.jpg (4 MB, 4128x3096) Image search: [Google]
IMG_20160330_195315.jpg
4 MB, 4128x3096
>>
Literally knapsack. Do your own shitty comp sci homework faggot
>>
>>91188
idk what that means
>>
>>91201
Google Knapsack problem, my fellow Comp Sci comrade
>>
>>91250
ive found special calculators for it but the struggle
>>
>>91281
find a new major
>>
>>91163
OP confirmed to be Australian
>>
No idea what you are even asking but this is what i see so far:

Limit:
300 ft
5600 lbs
Oranges > Grapefruit
Max profit?

Oranges
4 ft
80 lbs
2.5 $$

Grapefruit
6 ft
100 lbs
4 $$

Now that we know all the values, it wouldn't be hard to do it the old fashion way and just count.
>>
>>91399
The simplest way to do that, assuming that what we must achieve is a higher volume of orange crates than grapefruit, is to let the grapefruit take up half of the weight right off the start. and then fill up the rest of the weight with oranges.

This is what we get:
28 Grapefruit
168 feet cubed
2800

35 Orange crates
140 feet cubed
2800 lbs

Seems like a good place to start but we have a problem!
168 + 140 = 308 feet! We're 8 feet over capacity.

ok fine, lets just take off a few oranges and add some grapefruit, that should solve it right?

-4 oranges (20 feet, 400 lbs)
+2 grapefruit (12 feet, 200 lbs)

New values:

30 Grapefruit
180 feet cubed
3000

31 Orange crates
120 feet cubed
2400 lbs

Now we're at 300 feet, 5400 lbs. More oranges than grapefruit. We've hit our space capacity but not our weight capacity.

$120 + 77.5 = $197.50 profit.

Is there a better answer?
>>
>>91407
another way to do it is to break the two item into a value based on their weight and size

Oranges are
$0.03125 per lb
$0.625 per foot

Grapefruit are
$0.4 per lb
$0.66... per foot

Showing that in both cases it's more profitable to bring grapefruits than oranges.
However that missing 200 lbs troubles me.
>>
>>91412
I think the best way to do it is with a regular knapsack solutions with two limits with the objects orange and grapefruit+orange. This makes the number of oranges always greater or equal to the number of grapefruits. Not sure if this will come up with a different answer than your solution for the numbers given but it will probably give better solutions for other inputs.
Thread replies: 12
Thread images: 2

banner
banner
[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y] [Home]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
If a post contains personal/copyrighted/illegal content you can contact me at [email protected] with that post and thread number and it will be removed as soon as possible.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com, send takedown notices to them.
This is a 4chan archive - all of the content originated from them. If you need IP information for a Poster - you need to contact them. This website shows only archived content.