Since it is not mentioned in which language the program needs to be implemented, MATLAB is selected to develop the code.
MATLAB Code
%initializing the vector of Fahrenheit
fh=0:20;
%Display the heading on the command window
fprintf('Fahrenheit\tCelsius\n')
%'for' loop calling 'celsius' function
for m=1:length(fh)
%Calling 'celsius' function
cg=celsius(fh(1,m));
%Display fahrenheit and celsius temperature on command
window.
fprintf('%1.2f\t\t%1.2f\n',fh(m),cg)
end
%function definition
function c=celsius(f)
c=5/9*(f-32);
end
Output on the command window
Fahrenheit Celsius
0.00 -17.78
1.00 -17.22
2.00 -16.67
3.00 -16.11
4.00 -15.56
5.00 -15.00
6.00 -14.44
7.00 -13.89
8.00 -13.33
9.00 -12.78
10.00 -12.22
11.00 -11.67
12.00 -11.11
13.00 -10.56
14.00 -10.00
15.00 -9.44
16.00 -8.89
17.00 -8.33
18.00 -7.78
19.00 -7.22
20.00 -6.67
7. Celsius Temperature Table The formula for converting a temperature from Fahrenheit to Celsius is the...
C++ Code needed Celsius Temperature Table The formula for converting a temperature from Fahrenheit to Celsius is C =5/9(F -32) where F is the Fahrenheit temperature and C is the Celsius temperature. Write a function named celsius that accepts a Fahrenheit temperature as an argument. The function should return the temperature, converted to Celsius. Demonstrate the function by calling it in a loop that displays a table of the Fahrenheit temperatures 0 through 20 and their Celsius equivalents.
write program in java 5. Falling Distance When an object is falling because of gravity, the following formula can be used to determine the distance the object falls in a specific time period: d = 1/2 gta The variables in the formula are as follows: d is the distance in meters, g is 9.8, and t is the amount of time, in seconds, that the object has been falling. Write a method named fallingDistance that accepts an object's falling time...
Write a program that displays a table of Celsius temperatures 0 through a number entered by the user and their Fahrenheit equivalents as in the figure below. The formula for converting a Celsius temperature to a Fahrenheit temperature is: F = 9 / 5 * C + 32 where F is the Fahrenheit temperature and C is the Celsius Temperature. Your program must use a 'for' loop. Display all temperatures to one decimal place. Write a program that displays a...
Write a C++ console application that displays a table of Celsius temperatures from 0 through 20 and their equivalent Fahrenheit temperature values. The formula for converting from Celsius to Fahrenheit is: [In C++ Please] F==C + 32 Where, C is the temperature value in Celsius, and F is the equivalent temperature in Fahrenheit. Your program must use a loop to display the temperature values.
Write a program that displays a table of the Celsius temperatures 0 through 20 and their Fahrenheit equivalents. use formula for converting celsius to faremnheit
In Python, write a program that converts Celsius temperatures to Fahrenheit temperatures. The formula is as follows: F=(9/5)C+32 The program should ask the user to enter a temperature in Celsius, then display the temperature converted to Fahrenheit.
Write a program that converts Celsius temperatures to Fahrenheit temperatures. The formula is as follows: F=95C+32 The program should ask the user to enter a temperature in Celsius, and then display the temperature converted to Fahrenheit. I'm doing this on Python.
Temperature Converter Create a temperature conversion program that will convert the following to Fahrenheit: Celsius Kelvin Newton Your program should take a character which represents the temperature to convert from and a value to be converted to using the following specification: C - Celsius K - Kelvin N - Newton In addition your program should take in the following character to exit the program: X - eXit the program The numeric input for your program should be of type double....
Write a Python program that can convert a Fahrenheit temperature to Celsius, or vice versa. The program should use two custom functions, f_to_c and c_to_f, to perform the conversions. Both of these functions should be defined in a custom module named temps. Custom function c_to_f should be a void function defined to take a Celsius temperature as a parameter. It should calculate and print the equivalent Fahrenheit temperature accurate to three decimal places. Custom function f_to_c should be a value-returning...
FOR PYTHON Write a Python program that can convert a Fahrenheit temperature to Celsius, or vice versa. The program should use two custom functions, f_to_c and c_to_f, to perform the conversions. Both of these functions should be defined in a custom module named temps. Custom functionc_to_f should be a void function defined to take a Celsius temperature as a parameter. It should calculate and print the equivalent Fahrenheit temperature accurate to three decimal places. Custom function f_to_c should be a...