Question: Write a single Python program(py) file that fulfills all of the requirements given below. You will upload that single Python file to the BrightSpace Dropbo

 Write a single Python program(py) file that fulfills all of therequirements given below. You will upload that single Python file to the

Write a single Python program(py) file that fulfills all of the requirements given below. You will upload that single Python file to the BrightSpace Dropbo labeled -Homework 1 Upload. The description below requires that you write four different functions that perform four unrelated tasks. All four functions and the function named main0, used to call and test the four functions, must be placed in that single Python file. You will test your functions using the particular numerical values (integers, floats or arrays) given in the main0 function below. When we grade your assignment, we will run your program with those given numerical values, looking for correct answers. Then we will change the numerical values (includinjg changing the SIZES of the rays) and look for corect answers for those modified values as well. We will only use numerical values and aay sizes that make sense. We will not be testing your program to see how it handles bad data. In this assignment, you must use variables, loops, if statements, your own function definitions and functioin calls to write the required functions. For now, you may not use any of the powerful functions available in python modules, with one exception: you may import functions from the math module. a) Write a function defined as: def ArraySumEven(vals): vals: an aray (list) containing integers or floats retum value: the sum of all the even values in the array. Negative values can be even. b) Write a function defined as: defMatrixSumSmall vals, small) vals: a matix (list of lists) containing integers or floats small. a positive float or integer. Any lvalue := this value is considered to be small. retum value: the sum of the absolute values of all the small entries in the matix c) Write a function defined as: defHomer(x, coeffs): x: a float coeffs: an array containing the coefficients of a polynomial, in order from the coefficient of the lowest power to the coefficient of the highest power return value: the value of the polynomial for the given value of%, computed using Horner's Rule. Homer's Rule example (to be discussed in class): P(x) = a0+a1 * x+12 * x2 + a3 * x3 + a4 * x4 can be computed using Homer's Rule as: P(x) = (((24 * x a3) * x+12) * x + a1 )*x + ao

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!