yes, something like that. My approach would have been
priority = high, weight = 4 (assume) priority = medium, weight = 2 priority = low, weight = 1 now from you example, lets say number of consumers: Priority | No of Consumers --------------------------------------- High | 8 Medium | 5 Low | 2 Calculate total weight = 8*4+5*2+2*1 = 44 Now assign resource based on priority: Priority = high, Resource = 4 * 100 / 44 Priority = medium, Resource = 2 * 100 / 44 Priority= low, Resource = 1 * 100 / 44 Hope it makes more clear. -Dinesh Bansal On Thu, May 5, 2011 at 12:28 PM, LiveShell <livesh...@gmail.com> wrote: > Dinesh, > > something like .... > > Weight of > Low = 0.2 (High) > Medium = 0.3 (High) > > and calculate the W of High and assign resource to all H, M , L > accordingly.... am i on ryt way ??? > > or is there any other proven method to address this problem ??? > > > > > > > > On May 5, 11:39 am, dinesh bansal <bansal...@gmail.com> wrote: > > You can assign weight to all the consumers based on priority and then > divide > > all the resource based on weight. > > > > > > > > > > > > > > > > > > > > On Wed, May 4, 2011 at 6:13 PM, LiveShell <livesh...@gmail.com> wrote: > > > Hi all, > > > > > I am working on dynamic resource allocation problem. I have set of > > > Consumer and resource. Consumers are with priority (High, Medium, > > > Low). Now I want to assign resource slice to each consumer based on > > > priority and no of consumers. > > > > > ie > > > > > Priority | No of Consumers > > > --------------------------------------- > > > High | 8 > > > Medium | 5 > > > Low | 2 > > > > > OR > > > > > Priority | No of Consumers > > > --------------------------------------- > > > High | 1 > > > Medium | 2 > > > Low | 10 > > > > > My assumption is resource is 100 % and how can I assign slice of > > > resource to each Consumer based on priority. > > > > > Can any body give me idea which algorithm I should use..... > > > > > -- > > > You received this message because you are subscribed to the Google > Groups > > > "Algorithm Geeks" group. > > > To post to this group, send email to algogeeks@googlegroups.com. > > > To unsubscribe from this group, send email to > > > algogeeks+unsubscr...@googlegroups.com. > > > For more options, visit this group at > > >http://groups.google.com/group/algogeeks?hl=en. > > > > -- > > Dinesh Bansal > > The Law of Win says, "Let's not do it your way or my way; let's do it the > > best way." > > -- > You received this message because you are subscribed to the Google Groups > "Algorithm Geeks" group. > To post to this group, send email to algogeeks@googlegroups.com. > To unsubscribe from this group, send email to > algogeeks+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/algogeeks?hl=en. > > -- Dinesh Bansal The Law of Win says, "Let's not do it your way or my way; let's do it the best way." -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.