B=imread('lenna.jpg');
A=double(rgb2gray(B));
subplot(1,2,1);
imshow(A,[]);
title('Original Image');
%imshow(C,[]);
[m n]=size(A);
F=zeros(m,n,'double');
F=A;
C=fft2(A);
D=fftshift(C);
%imshow(uint8(C));
%[th r]=cart2pol(real(C),imag(C));
limit=15;
for u=1:m
for v=1:n
D1(u,v)=sqrt(((u-(m/2))^2)+((v-(n/2))^2));
if D1(u,v)>=limit
H=1;
else
H=0;
end
I1(u,v)=H*D(u,v);
end
end
% F1=ifft2(I1);
F1=ifftshift(I1);
...
Thursday, September 13, 2012
[MATLAB] Low pass filter using Fourier transformation
B=imread('lenna.jpg');
A=double(rgb2gray(B));
subplot(1,2,1);
imshow(A,[]);
title('Original Image');
%imshow(C,[]);
[m n]=size(A);
F=zeros(m,n,'double');
F=A;
C=fft2(A);
D=fftshift(C);
%imshow(uint8(C));
%[th r]=cart2pol(real(C),imag(C));
limit=15;
for u=1:m
for v=1:n
D1(u,v)=sqrt(((u-(m/2))^2)+((v-(n/2))^2));
if D1(u,v)<=limit
H=1;
else
H=0;
end
I1(u,v)=H*D(u,v);
end
end
% F1=ifft2(I1);
F1=ifftshift(I1);
...
Leach protocol tcl script NS2 simulation
# Copyright (c) 1997 Regents of the University of California.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
# 1. Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials...
Technical aptitude paper[Sample]
1. If you are using C language to implement the heterogeneous linked list, what pointer type
will you use?
2. Minimum number of queues needed to implement the priority queue?
3. What is the type of the algorithm used in solving the 8 Queens problem?
4. In RDBMS, what is the efficient data structure used in the internal storage representation?
5. What are the two classes of hardware building blocks?
6. Expand IDEA.
7. What is wide-mouth frog?
8. What are the typical elements of a process image?
9. What are the key object oriented concepts...
Download NCERT Books for free
There is a portal which provides you all versions(Hindi,English and Urdu) of NCERT books of all standards and available free for download as PDF.
Link:
http://ncertbooks.prashanthellina.co...
[LINUX]Sample code of Makefile
all: cal
lex.yy.c: cal1.l y.tab.h
lex -ll cal1.l
lex.yy.o: lex.yy.c
gcc -c lex.yy.c
y.tab.c: cal1.y
yacc -d cal1.y
y.tab.o: y.tab.c
gcc -c y.tab.c
cal: lex.yy.o y.tab.o
gcc -o temp lex.yy.o y.tab.o -ll -ly
y.tab.h: cal1.y
yacc -d cal1.y...
[MATLAB] pseudo ternary technique using simulink
close all;
clear all;
d=[1,0,1,1,0];
p=-2;
for i=1:length(d)
if i>1
if d(i)==0
p=-p;
a(i)=p;
else
a(i)=0;
end
else
if d(i)==0
p=2;
a(i)=p;
else
a(i)=0;
end
...
[MATLAB] NRZ-L technique using simulink
close all;
clear all;
d=[1,0,1,1,0];
for i=1:length(d)
if d(i)==1
a(i)=-2;
else
a(i)=2;
end
hold on;
for j=i:0.01:i+1
plot(j,a(i),'.-r');
end
grid on;
en...
[MATLAB] NRZ-I technique using simulink
close all;
clear all;
d=[1,0,1,1,0];
for i=1:length(d)
if i>1
if d(i)==1
a(i)=-a(i-1);
else
a(i)=a(i-1);
end
else
if d(i)==1
a(i)=-2;
else
a(i)=2;
end
end
hold on;
for j=i:0.01:i+1
...
Subscribe to:
Posts (Atom)