subject

You have mined a large slab of marble from a quarry. For simplicity, suppose the marble slab is a rectangle measuring n inches in height and m inches in width. You want to cut the slab into smaller rectangles of various sizes - some for kitchen countertops, some for large sculpture projects, others for memorial headstones. You have a marble saw that can make either horizontal or vertical cuts across any rectangular slab.
At any time, you can query the spot price P(x, y) of an x-inch by y-inch marble rectangle, for any positive integers x and y. These prices depend on customer demand, and people who buy marble countertops are weird, so don't make any assumptions about them; in particular, larger rectangles may have significantly smaller spot prices. Given the array of spot prices and the integers m and n as input, design a dynamic programming algorithm to compute how to subdivide an n x m marble slab to maximize your profit.
Your solution must output both the maximum profit as well as the sequence of cuts necessary to obtain that profit. A sequence of cuts can be described as a sequence of tuples (V, x, y_min, y_max) for vertical cuts, (H, y, x_min, x_max) of horizontal cuts.
Make your solution as asymptotically efficient as you can; we are not providing any particular target.

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 00:00
What engine component is shown in the above figure?
Answers: 1
question
Computers and Technology, 23.06.2019 00:20
The open systems interconnection (osi) reference model: defines standards for many aspects of computing and communications within a network. is a generic description for how computers use multiple layers of protocol rules to communicate across a network. defines standards for wireless local area network (wlan) communication protocols. details the advantages and disadvantages of various basic network cabling options.
Answers: 1
question
Computers and Technology, 23.06.2019 09:30
Write an essay on online collaboration, how to do it, the challenges, resolving the challenges, and consider whether the risks are greater than rewards. ( need )
Answers: 1
question
Computers and Technology, 24.06.2019 23:50
What is your fav video game currently: a) roblox b) fortnite c) apex legends d) pubg
Answers: 2
You know the right answer?
You have mined a large slab of marble from a quarry. For simplicity, suppose the marble slab is a re...
Questions
question
Mathematics, 18.08.2019 12:30
question
Mathematics, 18.08.2019 12:30
Questions on the website: 13722362