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
Sedbober [7]
3 years ago
15

Assuming that a query has a buffer holding up to 3 blocks, and each block can hold two records. Use merge-sort to sort the follo

wing records in ascending order: 10, 11, 1, 5, 90, 1, 2, 101
How many runs will be produced in the whole algorithm and what are the contents of the runs?
Engineering
1 answer:
kipiarov [429]3 years ago
5 0

Answer:

a) 5 runs will be generated.

b) Since the buffer can hold 3 records, the first 3 runs are (1, 10, 11), (1, 5, 90) and (2, 10). Then we need to reserve one block as output buffer, the algorithm can merge two runs at most at the same time. As a result, we can choose to merge the first two runs into a larger one: (1,1,5,10,11,90), which is merged with the run (2, 10) to generate the final output.

Explanation:

5 runs will be generated.

Since the buffer can hold 3 records, the first 3 runs are (1, 10, 11), (1, 5, 90) and (2, 10). Then we need to reserve one block as output buffer, the algorithm can merge two runs at most at the same time. As a result, we can choose to merge the first two runs into a larger one: (1,1,5,10,11,90), which is merged with the run (2, 10) to generate the final output.

You might be interested in
Differentiate between isohyetal method and arithmetical average method of rainfall​
prohojiy [21]

Answer:

Explained below

Explanation:

The isohyetal method is one used in estimating Rainfall whereby the mean precipitation across an area is gotten by drawing lines that have equal precipitation. This is done by the use of topographic and other data to yield reliable estimates.

Whereas, the arithmetic method is used to calculate true precipitation by the way of getting the arithmetic mean of all the points or arial measurements that will be considered in the analysis.

7 0
3 years ago
What is an advantage of a nuclear-fission reactor?.
Kobotan [32]

Answer:

Nuclear fission is almost 8,000 times more efficient than traditional fossil fuels at producing energy. That's a lot of energy packed into a small space. Nuclear energy is more efficient, which means it uses less fuel to power the plant and produces less waste.


advantages:
-produces no polluting gases
-does not contribute to global warming
-very low fuel costs
-Low fuel quantity reduces mining and transportation effects on environment
-High technology research required benefits other industries
-Power station has very long lifetime

Disadvantages:
-Waste is radioactive and safe disposal is very difficult and expensive
-Local thermal pollution from wastewater affects marine life
-Large-scale accidents can be catastrophic
-Public perception of nuclear power is negative
-Costs of building and safely decommissioning are very high
-Cannot react quickly to changes in electricity demand

4 0
2 years ago
Select the right answer<br>​
Kruka [31]

Answer:

for 1st question the answer is 5th option.

for 2nd question the answer is 2nd option

hope it helps you mate

please mark me as brainliast

5 0
3 years ago
Air enters a compressor steadily at the ambient conditions of 100 kPa and 22°C and leaves at 800 kPa. Heat is lost from the comp
telo118 [61]

Answer:

a) 358.8K

b) 181.1 kJ/kg.K

c) 0.0068 kJ/kg.K

Explanation:

Given:

P1 = 100kPa

P2= 800kPa

T1 = 22°C = 22+273 = 295K

q_out = 120 kJ/kg

∆S_air = 0.40 kJ/kg.k

T2 =??

a) Using the formula for change in entropy of air, we have:

∆S_air = c_p In \frac{T_2}{T_1} - Rln \frac{P_2}{P_1}

Let's take gas constant, Cp= 1.005 kJ/kg.K and R = 0.287 kJ/kg.K

Solving, we have:

[/tex] -0.40= (1.005)ln\frac{T_2}{295} ln\frac{800}{100}[/tex]

-0.40= 1.005(ln T_2 - 5.68697)- 0.5968

Solving for T2 we have:

T_2 = 5.8828

Taking the exponential on the equation (both sides), we have:

[/tex] T_2 = e^5^.^8^8^2^8 = 358.8K[/tex]

b) Work input to compressor:

w_in = c_p(T_2 - T_1)+q_out

w_in = 1.005(358.8 - 295)+120

= 184.1 kJ/kg

c) Entropy genered during this process, we use the expression;

Egen = ∆Eair + ∆Es

Where; Egen = generated entropy

∆Eair = Entropy change of air in compressor

∆Es = Entropy change in surrounding.

We need to first find ∆Es, since it is unknown.

Therefore ∆Es = \frac{q_out}{T_1}

\frac{120kJ/kg.k}{295K}

∆Es = 0.4068kJ/kg.k

Hence, entropy generated, Egen will be calculated as:

= -0.40 kJ/kg.K + 0.40608kJ/kg.K

= 0.0068kJ/kg.k

3 0
3 years ago
Two different fuels are being considered for a 2.5 MW (net output) heat engine which can operate between the highest temperature
sveta [45]

Answer:

If the heat engine operates for one hour:

a) the fuel cost at Carnot efficiency for fuel 1 is $409.09 while fuel 2 is $421.88.

b) the fuel cost at 40% of Carnot efficiency for fuel 1 is $1022.73 while fuel 2 is $1054.68.

In both cases the total cost of using fuel 1 is minor, therefore it is recommended to use this fuel over fuel 2. The final observation is that fuel 1 is cheaper.

Explanation:

The Carnot efficiency is obtained as:

\epsilon_{car}=1-\frac{T_c}{T_H}

Where T_c is the atmospheric temperature and T_H is the maximum burn temperature.

For the case (B), the efficiency we will use is:

\epsilon_{b}=0.4\epsilon_{car}

The work done by the engine can be calculated as:

W=\epsilon Q=\epsilon H_v\cdot m_{fuel} where Hv is the heat value.

If the average net power of the engine is work over time, considering a net power of 2.5MW for 1 hour (3600s), we can calculate the mass of fuel used in each case.

m=\frac{P\cdot t}{\epsilon H_v}

If we want to calculate the total fuel cost, we only have to multiply the fuel mass with the cost per kilogram.

TC=m\cdot c

8 0
3 years ago
Other questions:
  • What are the challenges posed by strategic information systems, and how should they be addressed?
    10·1 answer
  • You are comparing distillation column designs at 1 atm and 3 atm total pressure for a particular separation. You have the same f
    5·1 answer
  • . A roadway is being designed capable of allowing 70 mph vehicle speed. The superelevation around one curve is 0.05 inches per i
    15·1 answer
  • What is the magnitude of the maximum stress that exists at the tip of an internal crack having a radius of curvature of 2.5×10-4
    13·1 answer
  • What differentiates the master builder approach prior to the Renaissance from later approaches? Projects do not depend on indivi
    14·1 answer
  • View the picture below and then correctly answer the questions using the following words: Temperate Zone, Tropical Zone, Polar Z
    6·2 answers
  • Which option identifies the type of engineering technician most likely to be involved in the following scenario?
    9·1 answer
  • Three-dimensional measuring references all of these EXCEPT:
    10·1 answer
  • What are the potential hazards relating to materials handling injuries?
    6·1 answer
  • During welding in the vertical position, the torch angle can be varied to control sagging.
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!