A program that calculates the energy needed to heat water

Assignment Help Computer Engineering
Reference no: EM132168425

Using the Design Recipe and NetBeans, construct an algorithm, and then write a Java program based on the algorithm, to solve each of the following problems:

Science: calculating energy) Write a program that calculates the energy needed to heat water from an initial temperature to a final temperature.

Your program should prompt the user to enter the amount of water (M) in kilograms and the initial and final temperatures of the water.

The formula to compute the energy is

Q = M * (finalTemperature - initialTemperature) * 4184


where M is the weight of water in kilograms, temperatures are in degrees Celsius, and energy Q is measured in joules. Make sure your program declares and uses a named constant for the term 4184.

Sample Run (user input in color):

run:

Enter the amount of water in kilograms: 55.5

Enter the initial water temperature: 3.5

Enter the final water temperature: 10.5

The energy needed is 1625484.0

BUILD SUCCESSFUL (total time: 10 seconds)

Reference no: EM132168425

Questions Cloud

Conducted an experiment on different vehicle owners : Paul conducted an experiment on 12 different vehicle owners. Table below presents the fuel economy and CO2 emitted.
Forecast the number of tables to be sold in september : Using a four-period weighted moving average, with weights w1 = .5, w2 = .2, w3 = .2 and w4 = .1, forecast the number of tables to be sold in September.
Establish separate networks for each department : Company manager wants to establish separate networks for each department and one subnet for guest computers.
Forecast registrations from year 4 to year 12 : a) Develop a 3-year moving average to forecast registrations from year 4 to year 12.
A program that calculates the energy needed to heat water : Write a program that calculates the energy needed to heat water from an initial temperature to a final temperature.
What is the forecast for july : The number of checks received in June was 40 million, while the forecast was 42 million. A smoothing constant of .2 is used.
Write a single statement that computes the number of seconds : Using directives for creating symbolics, write a single statement that computes the number of seconds in a day.
Contain a chip purchased from a local vendor : In Operations Management, Suppose you make electronic calculators that contain a chip purchased from a local vendor
How do you refocus the organization on quality : How do you refocus the organization on quality and how do you conduct root cause analysis to investigate some of the problems within an organization.

Reviews

Write a Review

Computer Engineering Questions & Answers

  What is it and how managed security services

what is it and how managed security services (MSSPs) can add value

  Explain how each mechanism provides the service

security mechanisms (controls) can be used to support the communication security services below, and explain how each mechanism provides the service

  Research about the network security tools

Research one of the tools listed in the chapter or linked above. Discuss its relevance to the job and output. Does it give enough information?

  Generate and show all power-of-two numbers

show an arbitrary user-input integer.generate and display all power-of-two numbers in the range +128 to -128.

  Analyze the ongoing maintenance that will be required

Analyze the ongoing maintenance that will be required. Provide a workflow diagram in Visio or equivalent software to illustrate how the system will work.

  What factors in computer design would affect the decision

What factors in computer design would affect the decision.

  Find latest mark for given pupil in given subject

Module 55-5444:  OOP for Computer Science Assignment Specification. A small village infant school wishes to computerise its pupil records and you are to write a menu-driven application for this in C++. Find latest mark for given pupil in given subje..

  How many such strings have exactly five as

How many such strings have exactly five a's? How many such strings have three of each letter?

  How does implement a coprocessor interface

How does a coprocessor recognize a 68020 access?

  Define the technology that you are researching

Define the technology that you are researching, for example what is Nanotechnology? Provide positive feedback and additional comments.

  Who needs to be on the incident response team

In today's highly connected world, cyber incidents happen on a daily basis. Every corporation from the very large to small and medium (SME) companies need.

  Give an instance of the making-change problem

Give an instance of the making-change problem for which it is suboptimal to use the standard greedy algorithm.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd