Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Problem 3 data: 2005.6 1930.2 1965.6 2100.5 2065.8 1988.1 2024.6 2163.5 1945.4 1872.3 1906.6 2037.5 2010.3 1985.2 2600.3 1600.2 1899.9 1980.4 2004.3 1999.3 2025.3 1982.3

image text in transcribed

Problem 3 data:

2005.6 1930.2 1965.6 2100.5 2065.8 1988.1 2024.6 2163.5 1945.4 1872.3 1906.6 2037.5 2010.3 1985.2 2600.3 1600.2 1899.9 1980.4 2004.3 1999.3 2025.3 1982.3 1984.6 2012.4 2035.6 2065.4 2003.4 2050.4 1950.3 2032.2 1976.7

This is for MATLAB

You are being assigned three problems. Do all three problems in one script file: Class_17_App.m Include comment statements to help organize your script file. Include the standard header. Problem 1 Create the following vector four different ways. A -[4 8 12 16 20 24] 1. A1 - Typing in each element using commas/spaces to separate them 2. A2 - Using the [first value spacing : last valuel notation 3. A3-Using the linspace command 4. A4 - Using a for loop. The for loop must create the vector and add an element to it each time it passes through the loop Problem 2 Create the following matrix 1 23 B-123 three different ways 1. B1 - Typing in each element manually using commas, semicolons etc. to organize them 2. B2 Creating 3 vectors which are the three rows of B and combining together 3. B3 Creating 3 vectors which are the three columns of B and combining together 4. Extra Credit: B4- Using nested for loops (a for loop within a for loop) Problem 3 Background Renewable energy is a growing field; however, in order to determine what energy source we should use we must understand how much energy we consume Problem Statement You are an electrical engineer working with renewable energy. The file Class17_watts.txt has the maximum power in Watts required in a house for each day for the month of March. You want to compute the average power requirement for the month of March. You also want to know what the usage was on March 15th (the 15 data point in the file.) You will need to load the data into a vector and compute the average using a for loop. Additionally, print to the screen the 15th data point in the file to 1 decimal place and include units. You are being assigned three problems. Do all three problems in one script file: Class_17_App.m Include comment statements to help organize your script file. Include the standard header. Problem 1 Create the following vector four different ways. A -[4 8 12 16 20 24] 1. A1 - Typing in each element using commas/spaces to separate them 2. A2 - Using the [first value spacing : last valuel notation 3. A3-Using the linspace command 4. A4 - Using a for loop. The for loop must create the vector and add an element to it each time it passes through the loop Problem 2 Create the following matrix 1 23 B-123 three different ways 1. B1 - Typing in each element manually using commas, semicolons etc. to organize them 2. B2 Creating 3 vectors which are the three rows of B and combining together 3. B3 Creating 3 vectors which are the three columns of B and combining together 4. Extra Credit: B4- Using nested for loops (a for loop within a for loop) Problem 3 Background Renewable energy is a growing field; however, in order to determine what energy source we should use we must understand how much energy we consume Problem Statement You are an electrical engineer working with renewable energy. The file Class17_watts.txt has the maximum power in Watts required in a house for each day for the month of March. You want to compute the average power requirement for the month of March. You also want to know what the usage was on March 15th (the 15 data point in the file.) You will need to load the data into a vector and compute the average using a for loop. Additionally, print to the screen the 15th data point in the file to 1 decimal place and include units

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

Intranet And Web Databases For Dummies

Authors: Paul Litwin

1st Edition

0764502212, 9780764502217

More Books

Students also viewed these Databases questions