cost - else display'S must be between 0 and 500 end

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

View Full Document Right Arrow Icon
function [cost] = cost(s) s= floor(s); cost=(400-(s-21).^2).*sin(s.*pi./6);
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: else display('S must be between 0 and 500') end...
View Full Document

This note was uploaded on 10/02/2011 for the course ORIE 5430 taught by Professor Shoemaker during the Fall '11 term at Cornell.

Ask a homework question - tutors are online