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
Veseljchak [2.6K]
3 years ago
12

Exercise 5.46 computes the standard deviation of numbers. This exercise uses a different but equivalent formula to compute the s

tandard deviation of n numbers. To compute the standard deviation with this formula, you have to store the individual numbers using a list, so that they can be used after the mean is obtained. Your program should contain the following functions:
Compute the standard deviation of values def deviation(x) Compute the mean of a list of values def mean (x) write a test program that prompts the user to enter a list of numbers and displays the mean and standard deviation, as shown in the following sample run Programming Exercises 351 Enter numbers: 1.9 2.5 3.7 2 1 6 3 4 5 2 FEner The mean is 3.11 The standard deviation is 1.55738
Engineering
1 answer:
ruslelena [56]3 years ago
4 0

Answer:

// This program is written in Java Programming Language

// Comments are used for explanatory purpose

// Program starts here

import java.util.Scanner;

public class STDeviation {

// Declare and Initialise size of Numbers to be 10

int Numsize = 10;

public static void main(String args [] ) {

Scanner scnr = new Scanner(System.in);

// Declare digits as double

double[] digits = new double[Numsize];

System.out.print("Enter " + Numsize + " digits: ");

// Input digits using iteration

for (int i = 0; i < digits.length; i++)

{

digits[i] = scnr.nextDouble();

}

// Calculate and Print Mean/Average

System.out.print("Average: " + mean(digits)+'\n');

// Calculate and Print Standard Deviation

System.out.println("Standard Deviation: " + deviation(digits));

}

// Standard Deviation Module

public static double deviation(double[] x) {

double mean = mean(x);

// Declare and Initialise deviation to 0

double deviation = 0;

// Calculate deviation

for (int i = 0; i < x.length; i++) {

deviation += Math.pow(x[i] - mean, 2);

}

// Calculate length

int len = x.length - 1;

return Math.sqrt(deviation / len);

}

// Mean Module

public static double mean(double[] x) {

// Declare and Initialise total to 0

double total = 0;

// Calculate total

for (int i = 0; i < x.length; i++) {

total += x[i];

}

// Calculate length

int len = x.length;

// Mean = total/length

return total / len;

}

}

You might be interested in
Technician A says that a voltage drop of 0.8 volts on the starter ground circuit is within specifications. Technician B says tha
Romashka-Z-Leto [24]

Answer:

Technician A is wrong

Technician B is right

Explanation:

voltage drop of 0.8 volts on the starter ground circuit is not within specifications. Voltage drop should be within the range of 0.2 V to 0.6 V but not more than that.

A spun bearing can seize itself around the crankshaft journal causing it not to move. As the car ignition system is turned on, the stater may draw high current in order to counter this seizure.

8 0
3 years ago
Give five general principles involved in the process of sewage filtration?​
aleksandr82 [10.1K]

Answer:

Some general principles are given below in the explanation segment.

Explanation:

Sewage treatment seems to be a method to extract pollutants from untreated sewage, consisting primarily of domestic sewage including some solid wastes.

<u>The principles are given below:</u>

  • Unless the components throughout the flow stream become greater than the ports or even the gaps throughout the filter layer, those holes would be filled as either a result of economic detection.
  • The much more common element of filtration would be the use of gravity to extract a combination.
  • Broadcast interception or interference.  
  • Inertial influence.
  • Sieving seems to be an excellent method to distinguish particulates.

8 0
3 years ago
Which of the following might be a job or task of an IT worker who manages
-Dominant- [34]

Answer:

I'm pretty sure it's letter d

7 0
3 years ago
Find the number of Btu conducted through a wall in 8 hours. The wall is 8 feet high by 24 feet long and has a total R-value of 1
dedylja [7]

Answer:

ΔQ = 4930.37 BTu

Explanation:

given data

height h = 8ft

Δt = 8  hours

length L = 24 feet

R value = 16.2 hr⋅°F⋅ft² /Btu

inside temperature t1 = 68°F

outside temperature t2 = 16°F

to find out

number of Btu conducted

solution

we get here number of Btu conducted by this expression that s

\frac{\Delta Q}{\Delta t} =\frac{-A}{R} (t2 -t1)     ......................1

here A is area that is = h × L = 8 × 24 = 1492 ft²

put here value we get

\frac{\Delta Q}{8} =\frac{-192}{16.2} (16-68)

solve it we get

ΔQ = 4930.37 BTu

7 0
3 years ago
Sk the first 3D printed house
quester [9]
2,000 the answer __________im Shayla_________I like food _________do you________the crunch for me_______km not fat tho______are u no worrys________is u are u still pretty
8 0
3 years ago
Other questions:
  • Given the unity feedback system
    5·1 answer
  • A 15 cm × 15 cm circuit board dissipating 20 W of power uniformly is cooled by air, which approached the circuit board at 20C w
    11·1 answer
  • A 10-ft-long simply supported laminated wood beam consists of eight 1.5-in. by 6-in. planks glued together to form a section 6 i
    5·1 answer
  • A student is using a 12.9 ft ramp to raise an object 6 ft above the ground.
    5·1 answer
  • Consider a 1000-W iron whose base plate is made of 0.5-cm-thick aluminum alloy 2024-T6 (rho = 2770 kg/m3 and cp = 875 J/kg·°C).
    12·1 answer
  • Which type of design does not need special care for the placement of dimensions?
    5·1 answer
  • If these components have weights WA = 50000 lb , WB=8000lb, and WC=6000lb, determine the normal reactions of the wheels D, E, an
    14·1 answer
  • Select the correct answer.
    12·1 answer
  • Drop the name below the corresponding part. (Look at the picture above to answer)
    5·1 answer
  • What do you think the top TWO game elements are that directly contribute to player immersion?
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!