{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

MATLAB Quiz1

# MATLAB Quiz1 - xlabel't(SECONDS title'MY SIGNAL Gusev...

This preview shows pages 1–2. Sign up to view the full content.

MATLAB Quiz #1 ECEN 314-501 Andriy Gusev

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
% Gusev Andriy ECEN 314 Quiz 1 %part 1 clear all ; clc; close all ; plot([-4 0], [0 4]) %we plot the line from point (x,y)=>(-4,0) to (0,4) hold on ; %in order to stop screen from refreshing and erasing our line plot([0 0], [4 -4]) % here is the vertical line plot([0 4], [-4 0]) % line that goes from (0,-4) to (4,0) axis([-4 4 -5 5]) ylabel( 'x(t)'
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ); xlabel( 't(SECONDS)' ); title( 'MY SIGNAL' ); % Gusev Andriy ECEN 314 Quiz 1 part 2 function [out] = over(vec, lim) % here is our function out=sum((vec>=lim).*vec); %we get the vector compare it to lim(scalar) %than dot it with our vector that we have so this is what happens for over([5 1 3 6 9],4) Vector sum([1 0 0 1 1].[5 1 3 6 9])= 5+6+9=20...
View Full Document

{[ snackBarMessage ]}

### Page1 / 2

MATLAB Quiz1 - xlabel't(SECONDS title'MY SIGNAL Gusev...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online