Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C++ exercise Assignment A scientist has developed a mathematical model for a physical process, and he wants to check how good is model is. To

image text in transcribed

C++ exercise

Assignment A scientist has developed a mathematical model for a physical process, and he wants to check how good is model is. To evaluate the correctness of his model, he wants to test the results of his model under certain parameters and compare them with experimental results. Write a program that first reads the number of tests (testCount) as an int followed by the results of each test according to the model as a double array. (testModel) and finally the results of each test according to experiments as a double array. (testExperiment). Then, the program should calculate the error of the model by evaluating the average of the squares of the differences between the model result and experimental result (see formula below) using a function. testCount 1 Error = testCount i=0 (testModel; textExperiment,)? NOTE: Individual square of the difference between the model value and the experiment value calculations MUST be done in the function. Every other functionality MUST be done in the main function. NOTE: To calculate square of a number you MAY use the pow function within cmath library. NOTE: testCount will always be a positive integer whose value will be at most 50. NOTE: The sizes of both test Model and testExperiment arrays will always be equal to testCount. 7 5 5 3 3.5 2.3 5.6 7.1 10.3 3.0 2.1 Input 12344 56 45 92 51 48 100 23356 2.5 1.9 7.2 9.1 10.3 3.0 3.1 Output 1.4 32.6667 1.24571

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Advances In Databases And Information Systems 14th East European Conference Adbis 2010 Novi Sad Serbia September 2010 Proceedings Lncs 6295

Authors: Barbara Catania ,Mirjana Ivanovic ,Bernhard Thalheim

2010th Edition

3642155758, 978-3642155758

More Books

Students also viewed these Databases questions

Question

Outlining Your Speech?

Answered: 1 week ago

Question

Define Administration and Management

Answered: 1 week ago

Question

Define organisational structure

Answered: 1 week ago

Question

Question Can a Roth IRA invest in stock of the IRA owners business?

Answered: 1 week ago