Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Applying equation to Matrix
Date: Sun, 22 Aug 2010 17:20:19 +0000 (UTC)
Organization: UCC
Lines: 16
Message-ID: <i4rm8j$gd7$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-03-blr.mathworks.com
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1282497619 16807 172.30.248.38 (22 Aug 2010 17:20:19 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Sun, 22 Aug 2010 17:20:19 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 2454065
Xref: news.mathworks.com comp.soft-sys.matlab:664087

I want to apply equation to a matrices elements individualy. 
ie if  any element in C is less than 50 i want it to change element to 0
If it is greater than 50 but less than 600 i want it to apply the equation below to the element
and less than 1100 and greater than 600 apply the last equation to the element

ie working its way through the matrix

if 0<C<50;
C=0;
elseif 600>C>=50;
C=(.2666*C+155.29);
elseif 1100>C>=600;
C=(.4041*C+106.8);
else
C=C
end