Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please explain each part of the pseudo code Input: W , Wi , vi , N W r = W , v T T =

Please explain each part of the pseudo code
Input: W, Wi, vi, N
Wr=W,vTT=0,xi=0
' is the remaing volume
VTT is the total value
xi is the item selection decision
calculate ri=viwi values for all items
sort ris vulues in non-iwcreasing order.
let I be the sorted item indices
for ;inI
if wrwi
xi=1
wr=wr-wi
vT=vT+vi
else if wr>0
xi=wrwi
wr=0
vTT=vTT+xi*vi
utput: xiin[0,1],vT
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database And Expert Systems Applications 24th International Conference Dexa 2013 Prague Czech Republic August 2013 Proceedings Part 1 Lncs 8055

Authors: Hendrik Decker ,Lenka Lhotska ,Sebastian Link ,Josef Basl ,A Min Tjoa

2013 Edition

3642402844, 978-3642402845

More Books

Students also viewed these Databases questions

Question

What is Centrifugation?

Answered: 1 week ago

Question

To find integral of ?a 2 - x 2

Answered: 1 week ago

Question

To find integral of e 3x sin4x

Answered: 1 week ago

Question

To find the integral of 3x/(x - 1)(x - 2)(x - 3)

Answered: 1 week ago

Question

What are Fatty acids?

Answered: 1 week ago