Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Macroeconomics Expert

You are the mayor of a beautiful city by the ocean, and your city is connected to the mainland by a set of k bridges. Your city manager tells you that it is necessary to come up with an evacuation plan in the event of a hurricane. Your idea is to add a sign at each intersection pointing the direction of the route to the closest of the k bridges. You realize that this can be modeled as a graph problem, where the street intersections are nodes, the roads are edges, and the edge weights give the driving time between two adjacent intersections. Note that some of the roads in your city are one-way roads.

(a) Explain how to solve the evacuation-route problem in O(mlog n) time, where n is the number of intersections and m is the number of streets connecting two adjacent intersections. Note that the number of bridges k is not a constant, that is, it may depend on n and m. Therefore, a running time of O(k · mlog n) is not an acceptable solution. (Although I will give half credit for such a solution.) The output of your algorithm will be a labeling of the intersections, with an arrow pointing to the road to take to the closest bridge.

(b) Some of the bridges can hold more capacity than others. For 1 ≤ i ≤ k, we associate a positive numeric weight ci with each bridge. To encourage people to use bridges with higher capacity, we treat distances to different bridges differently. In particular, if δ is the actual distance from some intersection to bridge i, we assign it a capacity-weighted distance of δ/ci. Therefore, the higher the bridge capacity is, the lower the weighted distance. Present an O(mlog n) time algorithm to solve the evacuation-route problem using capacity-weighted distances. (Again, I will give half credit for a solution running in O(k · mlog n) time.

Problem 4 additional info: 2b - some of the bridges will be higher capacity. Their weights will be function of (distance/number of lanes) → this will give us shorter weight and we can treat it as a better route to take even though the distance is farther away.

 

Macroeconomics, Economics

  • Category:- Macroeconomics
  • Reference No.:- M9532808

Have any Question?


Related Questions in Macroeconomics

Question suppose us college students studying in france

Question: Suppose US college students, studying in France during the summer term, wish to remain in the country an extra two weeks and purchase train on the Indian Pacific rail line tickets in order to travel from Sydney ...

Question a monopolist faces the following informationthe

Question: A monopolist faces the following information: The market demand: Q=300-2P The cost Structure: TC=100+50Q a) what is the profit-maximizing price-output combination and what are the levels of profits and consumer ...

Question suppose the utility function for a consumer is

Question: Suppose the utility function for a consumer is given by U = min{X, 3Y}. A) Sketch 3 indifference curves for this consumer B) Given the utility function and the associated ICs, what type of goods are X and Y? Th ...

Question - suppose that the demand and supply schedules for

Question - Suppose that the demand and supply schedules for bonds that have a face value of $100 and a maturity date one year hence are as follows: Price ($) Quantity Demanded Quantity Supplied 100 0 600 95 100 500 90 20 ...

Economics assignment -part a microeconomicsconsider the

Economics Assignment - Part A: Microeconomics Consider the following three sources. Source 1. Macquarie Analysis: Woolworths Trails Coles on Grocery Prices (by Catie Low) Source 2: Supermarkets Price War Source 3: Suppor ...

Introductory economics assignment -three problem-solving

Introductory Economics Assignment - Three Problem-Solving Questions. Question 1 - Australia and Canada have a free trade agreement in which, Australia exports beef to Canada. a. Draw a graph and use it to explain and ill ...

Question - a relatively new aspect to the marketplaces of a

Question - A relatively new aspect to the marketplaces of a number of cities worldwide is something called the sharing economy, in which people rent assets such as cars and rooms directly from each other. Also called a p ...

Question pepsico produces both a cola and a major brand of

Question: PepsiCo produces both a cola and a major brand of potato chips. Coca-Cola produces only drinks. When might it make sense for PepsiCo to divest its potato chip operations? For Coca-Cola to begin manufacturing sn ...

Question - consider a community consisting of three voters

Question - Consider a community consisting of three voters, Al, Bob and Cathy. The Marginal Benefit function for each person is, for lighthouse service G is; MBa = 40 - 4G for Al, MBb = 20 - 2G for Bob, and MBc = 10 - G ...

Question assume an economy is described by the following

Question: Assume an economy is described by the following economic parameters: C = 0.8YD YD = Y + TR - tY TR = 100 t = 0.3 I = 1000 - 65i G = 600 L = 0.25Y - 75i M/P = 600 What is the equation that describes the IS curve ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As