answer.
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
lions [1.4K]
2 years ago
4

Convert the following pseudocode to C++ code. Be sure to define the appropriate variables.

Engineering
1 answer:
vredina [299]2 years ago
6 0

Answer:

// The following program is written in C++ programming language

// Comments are used for explanatory purpose

// Program starts here

#include<iostream>

using namespace std;

int main ()

{

// Declare all Variables

int speed, time, distance;

//a. Store 20 in the speed variable

speed = 20;

// b. Store 10 in the time variable

time = 10;

// c. Multiply speed by time and store the result in the distance variable.

distance = speed * time;

// d. Display the contents of the distance variable.

cout<<distance;

return 0;

}

You might be interested in
A 50-kg iron block and 20-kg copper block, both initially at 80 oC, are dropped into a large lake at 15 oC. Thermal equilibrium
bija089 [108]
I need this answer to please
5 0
2 years ago
Explain why the fundamental software engineering principles of process, dependability, requirements management, and reuse are re
Svet_ta [14]

Answer:

1. Costs and frequency of change.

2. The most important ‘non-functional’ requirements. Different systems have different priorities for non-functional requirements.

3. The software lifetime and delivery schedule.

Explanation:

The process of requirement gathering is required in both generic and customized software.

• A document to define the development process is required in all type of software application.

• Updating is required in each type of software. For doing so, new version of each type of software is released.

• Maintenance is an important part of software development. It is required in each type of application development.

• Software has some minimum requirements to execute. So, platform dependability is considered in all software development.

5 0
2 years ago
Read 2 more answers
A thermal energy storage unit consists of a large rectangular channel, which is well insulated on its outer surface and encloses
yaroslaw [1]

Answer:

the temperature of the aluminum at this time is 456.25° C

Explanation:

Given that:

width w of the aluminium slab = 0.05 m

the initial temperature T_1 = 25° C

T{\infty} =600^0C

h = 100 W/m²

The properties of Aluminium at temperature of 600° C by considering the conditions for which the storage unit is charged; we have ;

density ρ = 2702 kg/m³

thermal conductivity k = 231 W/m.K

Specific heat c = 1033 J/Kg.K

Let's first find the Biot Number Bi which can be expressed by the equation:

Bi = \dfrac{hL_c}{k} \\ \\ Bi = \dfrac{h \dfrac{w}{2}}{k}

Bi = \dfrac{hL_c}{k} \\ \\ Bi = \dfrac{100 \times \dfrac{0.05}{2}}{231}

Bi = \dfrac{2.5}{231}

Bi = 0.0108

The time constant value \tau_t is :

\tau_t = \dfrac{pL_cc}{h} \\ \\ \tau_t = \dfrac{p \dfrac{w}{2}c}{h}

\tau_t = \dfrac{2702* \dfrac{0.05}{2}*1033}{100}

\tau_t = \dfrac{2702* 0.025*1033}{100}

\tau_t = 697.79

Considering Lumped capacitance analysis since value for Bi is less than 1

Then;

Q= (pVc)\theta_1 [1-e^{\dfrac {-t}{ \tau_1}}]

where;

Q = -\Delta E _{st} which correlates with the change in the internal energy of the solid.

So;

Q= (pVc)\theta_1 [1-e^{\dfrac {-t}{ \tau_1}}]= -\Delta E _{st}

The maximum value for the change in the internal energy of the solid  is :

(pVc)\theta_1 = -\Delta E _{st}max

By equating the two previous equation together ; we have:

\dfrac{-\Delta E _{st}}{\Delta E _{st}{max}}= \dfrac{  (pVc)\theta_1 [1-e^{\dfrac {-t}{ \tau_1}}]} { (pVc)\theta_1}

Similarly; we need to understand that the ratio of the energy storage to the maximum possible energy storage = 0.75

Thus;

0.75=  [1-e^{\dfrac {-t}{ \tau_1}}]}

So;

0.75=  [1-e^{\dfrac {-t}{ 697.79}}]}

1-0.75=  [e^{\dfrac {-t}{ 697.79}}]}

0.25 =  e^{\dfrac {-t}{ 697.79}}

In(0.25) =  {\dfrac {-t}{ 697.79}}

-1.386294361= \dfrac{-t}{697.79}

t = 1.386294361 × 697.79

t = 967.34 s

Finally; the temperature of Aluminium is determined as follows;

\dfrac{T - T _{\infty}}{T_1-T_{\infty}}= e ^ {\dfrac{-t}{\tau_t}}

\dfrac{T - 600}{25-600}= e ^ {\dfrac{-967.34}{697.79}

\dfrac{T - 600}{25-600}= 0.25

\dfrac{T - 600}{-575}= 0.25

T - 600 = -575 × 0.25

T - 600 = -143.75

T = -143.75 + 600

T = 456.25° C

Hence; the temperature of the aluminum at this time is 456.25° C

3 0
2 years ago
A 150-in.3, four-cylinder, four-stroke cycle, high-swirl CI engine is running at 3600 RPM. Bore and stroke are related by S = 0.
Free_Kalibri [48]

Answer:

Explanation:

(a) Swirl tangential speed = 3 x MPS ( mean piston speed)

= 3 x 420.76 inch/sec = 280.51  [ft/sec]

The other detailed steps is as shown in the attached file

6 0
2 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
2 years ago
Other questions:
  • A gas metal arc welder is also known as a _____ welder.
    5·1 answer
  • Oil in an engine is being cooled by air in a cross-flow heat exchanger, where both fluids are unmixed. Oil (cp = 2000 J/kg. K) f
    12·1 answer
  • Choose the correct sequence of the following events leading to the sensory processing of a stimulus. 1. transmission 2. transduc
    13·1 answer
  • 4.9 Given that I 4 amps when Vs 40 volts and Is 4 amps and I 1 amp when Vs 20 volts and Is 0, use superposition and linearity to
    5·1 answer
  • The procedure for determining the presence of Non-Condensable Gasses in refrigerant contained in an external recovery tank utili
    5·2 answers
  • A dc shunt generator rated at 85 kW produces a voltage of 280 V. The brush voltage drop is 2.5 V, and the armature and field res
    6·1 answer
  • Water enters a circular tube whose walls are maintained at constant temperature at specified flow rate and temperature. For full
    8·1 answer
  • The mechanical properties of some metals may be improved by incorporating fine particles of their oxides. If the moduli of elast
    12·1 answer
  • Technician A says that weld-through primer can be removed from the immediate weld area to improve weld quality. Technician B say
    7·1 answer
  • An airplane in level flight at an altitude h and a uniform speed v passes directly over a radar tracking station A. Calculate th
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!