1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
larisa [96]
3 years ago
5

Given an integer k, a set C of n cities c1, . . . , cn, and the distances between these cities dij = d(ci , cj ), for 1 ⤠i &lt

; j ⤠n, where d is the standard Euclidean distance. We want to select a set H of k cities for building mobile hospitals in light of the coronavirus outbreak. The distance between a given city c and the set H is given by d(c, H) = minhâH d(c, h). The goal is to select a set H of k cities that minimizes r = maxcâC d(c, H). Namely, the maximum distance from a city to the nearest mobile hospital is minimized. Give a 2-approximation algorithm for this problem.
Engineering
1 answer:
Snezhnost [94]3 years ago
6 0

Answer:

See explaination

Explanation:

2-Approximation Algorithm

Step 1: Choose any one city from the given set of cities C arbitrarily and put it in to a set H which is initially empty.

Step 2: For every city c in set C that is currently not present in set H compute min_distc = Minimum[ d(c, c1), d(c, c2), d(c, c3), ..... . . . . d(c, ci) ]

where c1, c2, ... ci are the cities in set H

and d(x, y) is the euclidean distance between city x and city y

Step 3: H = H ∪ {cx} where cx is the city have maximum value of min_dist over all possible cities c, computed in Step-2.

Step 4: Step-2 and Step-3 are iterated for k-1 times so that k cities are included int set H.

The set H is the required set of cities.

Example

Assume:-

C = {0, 1, 2, 3}

d(0,1) = 10, d(0,2) = 7, d(0,3) = 6, d(1,2) = 8, d(1,3) = 5, d(2,3) = 12

k = 3

Solution:-

Initially H = { }

Step-1: H = {0}

Step-2: Cities c \not\in H are {1, 2, 3}

min_dist1 = min{dist(0,1)} = min{10} = 10

min_dist2 = min{dist(0,2)} = min{7} = 7

min_dist3 = min{dist(0,3)} = min{6} = 6

Step-3: Max{10, 7, 6} = 10

Step-4: cx = 1

Step-5: H = H ∪ cx = {0} \cup {1} = {0, 1}

Step-6: Cities c \not\in H are {2, 3}

min_dist2 = min{dist(0,2), dist(1,2)} = min{7, 8} = 7

min_dist3 = min{dist(0,3), dist(1,3)} = min{6, 5} = 5

Step-7: Max{7, 5} = 7

Step-8: cx = 2

Step-9: H = H \cup cx = {0, 1} \cup {2} = {0, 1, 2}

Result: The set H is {0, 1, 2}.

You might be interested in
Which of the following have had a significant impact on the automotive industry?
WARRIOR [948]
All of the above (hope that helps!)
6 0
3 years ago
People tend to self-disclose to others that are in age, social status, religion, and personality.
pickupchik [31]

Answer:

??????yeh

Explanation:

8 0
3 years ago
Read 2 more answers
Write a linear equation expressing the number of t-shirts sold each month as a function of price per t-shirt. Please be explicit
IgorC [24]

Answer:

slope of the equation = -0.006778 and the intercept = 27.11

Explanation:

The following details were also given ; They predict the monthly T shirts to be 1750 shirts, if you price them at $15.25 per shirt or 791 shirts if you price them at $21.75 per shirt.

The detailed steps and calculation is as shown in the attached file.

6 0
3 years ago
Que os vizinhos diziam sempre aq lenhador? Responda com elementos do texto.​
Alecsey [184]

Answer:

shsisdnd ajwdhdjeo sisksdne suspended wowodndjd

4 0
3 years ago
How a single force is resolved along the perpendicular axis acting an angle theta with horizontal?​
Nataly [62]

Answer:

A single force, which is acting at angle θ from a horizontal axis, can be resolved into components which act along the perpendicular axis.

Consider the perpendicular axis x and y, where x represents the horizontal axis and y represents vertical axis.

The Force is resolved into 2 parts, one acts along x-axis and is represent by X. The other acts along y-axis and is represented by Y.

From the diagram we can see that the Force and its components X and Y makes up a right angles triangle, where θ is the angle from the x-axis

<h3 /><h3>Find X:</h3>

We know that:

cosθ = Base/Hypotenuse

cosθ = X/F

X = Fcosθ

<h3>Find Y:</h3>

We know that:

sinθ = Perpendicular/Hypotenuse

sinθ = Y/F

Y = Fsinθ

<h3>Relation of Force and its Components:</h3>

Force F can be represent by:

F = Fcosθ (along x-axis) + Fsinθ (along y-axis)

As they form a right angled triangle, we can use Pythagoras Theorem to show the relation between Force and its components.

Hypotenuse² = Base² + Perpendicular²

F² = X² + Y²

F² = (Fcosθ)² + (Fsinθ)²

F = \sqrt{(F\cos\theta)^2+(Fsin\theta)^2}

Where θ can be found by using any of the trignometric functions.

6 0
3 years ago
Other questions:
  • Hot air at an average temperature of 100 degC flows through a 3 m long tube with an inside diameter of 60 mm. The temperature of
    12·2 answers
  • where x is the coordinate spanning the slot opening, L = 114 mm is the slot width, and U = 0.8 m/s is the peak velocity. The hei
    6·1 answer
  • A power hacksaw used to cut metal, Link 5 pivots at O5 and its weight forces the saw-blade against the workpiece while the linka
    11·1 answer
  • A battery is an electromechanical device. a)- True b)- False
    6·1 answer
  • Consider a vortex filament of strength in the shape of a closed circular loop of radius R. Obtain an expression for the velocity
    10·1 answer
  • Base course aggregate has a target dry density of 119.7 Ib/cu ft in place. It will be laid down and compacted in a rectangular s
    5·1 answer
  • What is the weight of a glider with a mass of 4.9 grams?
    12·1 answer
  • Reserve Problem 4.006 Tutorial SI
    14·1 answer
  • The use of alcohol can cause
    6·2 answers
  • Describe two fundamental reasons why flexural strength should depend on porosity
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!