New Word 2007 Document (10)

New Word 2007 Document (10) - function y = cosmx ( x ) % y...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
Exercise 2 : 1. Write an m-file named cosmx.m (``COS Minus X'') that defines the function Recall that a function m-file is one that starts with the word function . In this case it should start off as
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: function y = cosmx ( x ) % y = cosmx(x) computes the difference y=cos(x)-x % your name and the date y = ??? (This is very simple-the object of this exercise is to get going.)...
View Full Document

Ask a homework question - tutors are online