You are on page 1of 4

>> A=[ 225 254 203 202;50 0 58 120;145 150 125 251;40 5 78 77]

A=
225 254 203 202
50 0 58 120
145 150 125 251
40 5 78 77

>> fmin=min(A)
fmin =
40 0 58 77

>> fmin1=min(min(A))
fmin1 = 0
>> fmax=max(A)
fmax =
225 254 203 251
>> fmax1=max(max(A))
fmax1 = 254
>> fmax1=max(max(fmax1))
fmax1 = 254

>> B=[ 225.5 254.2 203.1 202.8;50 0.2 58 120;145 150 125 251;40 5 78 77]
B=

225.50000 254.20000 203.10000 202.80000


50.00000 0.20000 58.00000 120.00000
145.00000 150.00000 125.00000 251.00000
40.00000 5.00000 78.00000 77.00000

>> fmin1=min(min(B))
fmin1 = 0.20000
>> fmin1=round(min(min(B)))
fmin1 = 0

>> C=B(2:3,2:3)
C=
0.20000 58.00000
150.00000 125.00000
>> B(:,3)=0
B=
225.50000 254.20000 0.00000 202.80000
50.00000 0.20000 0.00000 120.00000
145.00000 150.00000 0.00000 251.00000
40.00000 5.00000 0.00000 77.00000

>> B=imread('corazon.jpg');
>> size(B)
ans =

480 601

>> fmax1=round(max(max(B)))
fmax1 = 249
>> fmin1=round(min(min(B)))
fmin1 = 1

>> B=imread('corazon.jpg');
>> size(B)
ans =
480 601
>> imshow(B)

>> figure ()
>> C=B(150:350,100:300);
>> imshow(C)
>> A=imread('marte.jpg');
>> size(A)
ans =

307 617 3
>> imshow(A)

>> a1=A(:,:,1);
>> imshow(a1)
>> a2=A(:,:,2);
>> imshow(a2)

>> a3=A(:,:,3);
>> imshow(a3)

You might also like