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
Anvisha [2.4K]
3 years ago
5

You recall an algorithm from elementary school for factoring a number N: Divide out all factors of 2, then of 3, then of 4, then

of 5, then of 6, then of 7, etc. Finally, divide out all factors of N (of which there can be at most one). (a) Write pseudo-code for this algorithm (and print the prime factors)
Engineering
1 answer:
Contact [7]3 years ago
4 0

Answer:

let number = 0

while number < 1

  begin

     print "Enter a positive integer: "

     read number

  end

end_while

find and print number's factors:

let prime = TRUE

let currentFactor = 2

let lastFactor = the square root of number truncated

  to an integer value

while currentFactor <= lastFactor

  begin

     if number is evenly divisible by currentFactor

        begin

           print currentFactor

           let number = number / currentFactor

        end

     else

        let currentFactor = currentFactor + 1

     end_if

  end

end_while

print a message if number is prime:

if prime == TRUE

  print "Your number is prime"

end_if

Explanation:

You might be interested in
Consider a steam turbine, with inflow at 500oC and 7.9 MPa. The machine has a total-to-static efficiency ofηts=0.91, and the pre
sergiy2304 [10]

Answer: \dot m_{in} = 23.942 \frac{kg}{s}, \dot H_{out} = 39632.62 kW

Explanation:

Since there is no information related to volume flow to and from turbine, let is assume that volume flow at inlet equals to \dot V = 1 \frac{m^{3}}{s}. Turbine is a steady-flow system modelled by using Principle of Mass Conservation and First Law of Thermodynamics:

Principle of Mass Conservation

\dot m_{in} - \dot m_{out} = 0

First Law of Thermodynamics

- \dot W_{out} + \eta\cdot (\dot m_{in} \dot h_{in} - \dot m_{out} \dot h_{out}) = 0

This 2 x 2 System can be reduced into one equation as follows:

-\dot W_{out} + \eta \cdot \dot m \cdot ( h_{in}- h_{out})=0

The water goes to the turbine as Superheated steam and goes out as saturated vapor or a liquid-vapor mix. Specific volume and specific enthalpy at inflow are required to determine specific enthalpy at outflow and mass flow rate, respectively. Property tables are a practical form to get information:

Inflow (Superheated Steam)

\nu_{in} = 0.041767 \frac{m^{3}}{kg} \\h_{in} = 3399.5 \frac{kJ}{kg}

The mass flow rate can be calculated by using this expression:

\dot m_{in} =\frac{\dot V_{in}}{\nu_{in}}

\dot m_{in} = 23.942 \frac{kg}{s}

Afterwards, the specific enthalpy at outflow is determined by isolating it from energy balance:

h_{out} =h_{in}-\frac{\dot W_{out}}{\eta \cdot \dot m}

h_{out} = 1655.36 \frac{kJ}{kg}

The enthalpy rate at outflow is:

\dot H_{out} = \dot m \cdot h_{out}

\dot H_{out} = 39632.62 kW

3 0
3 years ago
What should I do I if a patient I’s bleeding th our his penis
Brilliant_brown [7]

Answer:

YOU SHOULD HELP HIM

Explanation:

6 0
3 years ago
Read 2 more answers
What is the function of the rotor and the stator in an AC motor
sweet-ann [11.9K]
The rotor is situated inside the stator and is mounted on the AC motor's shaft. It is the rotating part of the AC motor. And while we know this, the major function of the rotor and the stator is helping the motor shaft rotate.
7 0
4 years ago
Supercharging is the process of (a) Supplying the intake of an engine with air at a density greater than the density of the surr
iVinArrow [24]

Answer:

a)supplying the  intake of an engine  with air at a  density greater  than the density  of the surrounding  atmosphere

Explanation:

Supercharging  is the process of  supplying the  intake of an engine  with air at a  density greater  than the density  of the surrounding  atmosphere.

By doing this , it increases  the power out put  and increases the  brake thermal  efficiency of the  engine.It also  increases the  volumetric efficiency of the  engine.

So the our  option a is  right.

4 0
3 years ago
In python, how would I randomize numbers and insert them into a file?
BabaBlast [244]
Random integer values can be generated with the randint() function. This function takes two arguments: the start and the end of the range for the generated integer values. Random integers are generated within and including the start and end of range values, specifically in the interval [start, end].
7 0
3 years ago
Other questions:
  • A model of a submarine, 1 : 15 scale, is to be tested at 183 ft/s in a wind tunnel with standard sea-level air, while the protot
    10·1 answer
  • The function below takes a two parameters: a list called a_list and a value called a_value. Complete the function to first check
    11·1 answer
  • What is the entropy of a closed system in which 25 distinguishable grains of sand are distributed among 1000 distinguishable equ
    5·2 answers
  • technician A says that voltage is electric pressure .Technician B says the amperage is electrical flow who is right
    11·1 answer
  • Two long conducting cylindrical shells are coaxial and have radii of 20 mm and 80 mm. The electric potential of the inner conduc
    10·1 answer
  • What are the potential hazards relating to materials handling injuries?
    12·2 answers
  • Which geometric curved solids are most commonly used by engineers?
    8·2 answers
  • I'll give a free brainliest
    7·2 answers
  • Which type of work is a textile engineer most likely to do?
    8·1 answer
  • 6. The humanistic perspective focuses on free will, Free will is your ability to OA. believe what others believe. B. make your o
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!