20 vues

Transféré par api-26783388

- Adding and Subtracting Angles
- iready-sample-diagnostic-items-math
- course outline
- Writing Algebraic Equations Practice
- 2011 PSPM Kedah Add Maths 2 w Ans
- grade 8 lesson 6 algebra and algebraic reasoning
- Math 062 Glossary_English Language Document_United States_English Glossary Review
- CONTASSS
- rationalequationslesson 1
- geometry research
- Simmonds
- sp_add_maths_kbsm
- Numerical Methods Intro
- NNTDM-20-2-20-28
- day 13
- Engineering-Mathematics-1 (1).pdf
- Simultaneous Linear Equation
- 2011-2012 Hs Course Descriptions 2011 Final
- Two Degree Non Homogenous Differential Equations
- Grade 8 Math Curriculum 2018-2019

Vous êtes sur la page 1sur 15

Date: 31st October, 2006

Submitted by:

Atul Bhatia (200611024)

Hina Shah (200611032)

Nitin Rawat (200611025)

Problem 1:

Aims of the problem:

•

To analyze real lines in discrete grid in our digital image by considering

intersection of lines in N2

• To establish a relation of the line in N2 and Diophantine Equations

Every intersecting line in R2 does not necessarily intersect in our discrete. In discrete grid

of the image each position is characterized by a member of N2 that can be from (0,0) to

(M,N) where M can be the width of the image and N height of the image. So a real line in

R2 when represented in the discrete grid is approximated to elements of N2.

As an example, consider the following image which contains some lines:

Now zooming (by 8x) each of the areas of intersection we see the following results:

a. b. c.

Figure (a) shows the intersection of real lines l and m in N2. As can be seen here the lines

are actually not intersecting in N2 although they will intersect in R2. Points of line l in N2

near the so called intersection are: (88, 86) and (89, 87). While points of line m in N2 near

the so called intersection are: (88, 87) and (89, 86).

Figure (b) shows the intersection of real lines l and n. Points of line l in N2 near the so

called intersection are: (124, 116) and (125, 117). While points of line n in N2 near the so

called intersection are: (124, 117) and (125, 116).

Figure (c) shows the intersection of line l and p. These two lines actually intersect in N2

as can be seen in the image. The point of intersection is (152, 140).

Each of the lines is a set in N2 and the intersection of two lines would mean that two lines

have one element in common. As seen in Figure (a) conventional intersection of set

(Please note that (0,0) is taken as the top left corner of the original image.)

Diophantine Equations:

Diophantine Equations is an indeterminate polynomial equation that only allows the

variables to be integers [1]. Lines in N2 can be represented by a Diophantine equation of

type

ax + by = c

where x and y are integer variables and c is the greatest common divisor of a and b and

both of them are also integers. This is a linear Diophantine equation.

As an example consider a pair of Diophantine Equations as::

7x + 18y = 208

x + y = 25

Solving the two equations for lines above, the point of intersection comes out to be

(22,3).Image showing both lines and their intersection is as

follows:

x+y=25

(22,3)

7x+18y=208

(0,0)

a b

Figure (a) shows two lines of respective equations, while Figure (b) is the zoomed

version of the intersected area. The point of intersection has a gray value of 64 and is

marked within the circle. The intersection point as discussed earlier is (22,3) .

Actually, proper solutions for second equation are points like (40, -4), (22,3), (4,10),

(-14, 17), (-32, 24), etc. What is shown in the image is a line joining all these points, by

creating a path between the points by 8- neighborhood (please refer definition 2.2 in [3]).

The path has points that have been obtained by approximating the values of (x,y)

obtained for each possible x here.

Now let us have an example of two linear Diophantine equations which do not have a

perfect intersection point:

7x + 18y = 208

2x + 3y = 1

The intersection point for these two lines does not turn out to be an integer. So these two

lines would not intersect in our discrete grid of N2 for the image. Instead the intersection

point will be approximated to some integer pair. The actual intersection occurs at point

(-40.4, 27.667)

2x+18y=208 approximations

(0,0)

2x+3y=1

a. b.

Figure (a) shows the two lines formed by Diophantine equations given above. As seen

before the point of intersection is not a member of N2 , but rather is (-40.4, 27.267). This

point has been approximated to (-40, 27) in figure (b) above. Other intersections that are

visible in the figure are also nothing but simple approximation of such values in R2 to

values in N2.

Problem 2

Aims of the Problem: To rotate a solid object by 45 degrees with respect to the center of

gravity of the object.

Solid object that we first would be considering is a rectangle. The original image to be

transformed (rather rotated) is given below. The center of gravity of the square is

coordinate (100, 100).

(100, 100), it would be first required to translate the

object to origin (0,0) and then rotate it by 45 degrees

and then again translate the rotated object back to

(100,100) origin position.

The transformations of objects are done actually using

series of matrix multiplications. Transformations done

in this way are called affine transforms [4]. For

example our case would need 3 matrix multiplications

as the following steps are required:

1. Translating to the origin (0,0)

2. Rotate by 45 degrees

3. Translate back to origin (100, 100)

If the coordinate is given in terms of a matrix of the form X=[x y 1], then various

transformation matrices are given as follows:

Translation by tx and ty :

T=[1 0 0

0 1 0

tx t y 1 ]

hence X*T results in new coordinates w = x+ tx, z= y+ ty

Rotation by angle θ

R = [ cos θ sin θ 0

-sin θ cos θ 0

0 0 1]

Hence X*R results in new coordinates w=xcos θ - ysin θ, z = xsin θ + ycos θ

Therefore the combined matrix for the required composite transformation would be

T*R*T-1 which will be given as:

F = [ cos θ sin θ 0

-sin θ cos θ 0

tx’ ty’ 1]

where tx’ = tx(cos θ -1) - tysin θ

ty’ = txsin θ + ty(cos θ -1)

x’ = xcos θ - ysin θ + tx’

y’ = xsin θ + ycos θ + ty’

Again the new coordinates obtained would be real numbers and hence would have to be

approximated to integer values. This would result into replication of several input pixels

into the same pixel position in the output. The effect of this can be seen in the image

obtained by direct matrix multiplication which is shown below:

the codes section.

The black pixels that are seen here in the rotated white

square are present as several input pixel positions are

mapped to a single pixel position, hence some are left

without any mapping, and hence are black.

The rotation also generates a problem of filling up the

extra pixels that have been created due to rotation.

Because now the line that was straight before would

not be straight and hence would take up more pixels

and hence a jagged edge would be created as a result

of the phenomenon. ([5] and [7])

In order to tackle with this problem, interpolation would be required to be performed.

value of the original pixels in the original image by

performing the inverse transform of the pixels that

have been obtained by rotation. This would give us an

approximation of what is obtained.

After this the rotation of the images seems to be a bit sophisticated process! This was a

case of a solid object. But if we had a different object with variations in pixel values then

one would have to take care of the nearest neighborhoods also in order to produce

accurate results.

Problem 3:

Aims of the problem:

• To take an image of size NxN, and decimate it by a factor of 2.

• Interpolate the image of size N/2 x N/2 to the original size using various

interpolation techniques like bilinear, spline and bicubic.

• To increase the decimation factor by 4 and 8 and then to try to obtain the original

image.

• To comment on super resoluction

Decimating by a factor of 2, 4and 8 following images are obtained:

Image obtained by decimating the original image by a factor or 2 (size 512 x 512)

Result of decimation by factor 4 (size 256 x 256) Result of decimation by factor 8 (128x128)

We have used 3 interpolation methods in order to convert the image of size 512x512 to

its original size. (i.e. 1024x1024), we used 3 types of interpolation methods : nearest

neighbor method, bilinear method and bicubic.

While nearest neighbor simply replicates the value of the nearest neighbor of the pixel,

bilinear method uses the weighted average of the nearest 2x2 neighborhood of known

pixels around the unknown pixel and bicubic method uses a neighborhood of size 4x4. [5]

Listing for the same has been provided in the codes section.

Results obtained cane be summarized as follows:

Bicubic Interpolation

Zoomed part of each or these images is shown as follows:

Although none of the images are exactly same as the original image, there is a noticeable

difference between the interpolated images.

Nearest Neighbor method uses simple replication, hence the image appears to be rougher.

This is the reason why one sees the jagged edges at the boundary of the petals

Bilinear method is much smoother than the nearest neighbor method as it tried to use a

value that is near to its nearest neighbor and lies between the values of the unknown

pixel’s neighbors.

Bicubic linear interpolation is computationally expensive, but this tries to take up a large

neighborhood and hence results into a more detailed and a smoother image.

SUPER RESOLUTION

Low resolution in the image occurs due to lower spatial sampling frequency,

which produces distortion in the image due to high frequency components. This cases lost

in the information due to high frequency components such as edges and textures.

Degradation can also be caused by camera motion or out of focus. Thus image captured

with low resolution camera suffers from aliasing, blurring and presence of noise. Super-

resolution (SR) refers to the process of producing a high spatial resolution image from

several low resolution images, thereby increasing the maximum spatial frequency and

removing the degradations that arise during the image capturing process using a low

resolution camera. In fact, the super-resolution process extrapolates the high frequency

components and minimizes aliasing and blurring.

In order to obtain super-resolution we must look for non redundant information

among the various frames in an image sequence. The most obvious method for this seems

to be to capture multiple low resolution observations of the same scene through subpixel

shifts due to the camera motion. These subpixel shifts can occur due to the controlled

motion in imaging systems, e.g., a landsat satellite captures images of the same area on

the earth every eighteen days as it orbits around it.

motion, blurr, zoom, photometry, learning based techniques

Problem 4:

Aims:

• To find the possible configurations in which two ellipses can act as elliptic gears.

• To create an animated sequence of rotation of elliptic gears

There are 2 possible configurations in which given two polynomials would act as elliptic

gears.

other in order to act as elliptic gears.

Hence the major axes of both the ellipses as well as

the minor axes of both the ellipses are rotating. The

rotation of both ellipses will be in different

directions. Hence, if one ellipse rotates in clockwise

direction, the other would rotate in anticlockwise

direction. The distance between the shown focal

points remains constant throughout. (The image has

been taken from [6])

axis of one ellipse stationary and the other major

axis is rotating.

As seen in the adjacent figure [8]. The horizontally lying

ellipse would not move. The other ellipse moves around

this driver gear. Again, while the distance between the

two focal points of the two ellipses remains constant

here (as shown in the figure), the major axis is the only

one that is rotating. Hence the focal point in the

horizontally lying gear is the pivot and the other ellipse

moves with respect to this focal point only.

In the other configuration the distance between the centers of the two ellipses remains the

same.

References:

1. www.wikipedia.com/wiki/Diophantine_equation

2. Introduction to Diophantine Equations – Tom Davis

http://www.geometer.org/mathcircles/

3. Digital Topology, A.Rosenfield, American Mathematical Monthly 86: 621-630

4. Digital Image Processing Using Matlab® – Rafael C. Gonzales, Section 5.11

(Chapter 5).

5. http://www.cambridgeincolour.com/tutorials/image-interpolation.htm

6. http://mathworld.wolfram.com/Ellipse.html

7. Matlab Documentation

8. http://www.ies.co.jp/math/java/conics/elgear/elgear.html

Codes:

Listing 1 for Problem 1:

I=zeros(200, 200, 'uint8');

I(:,:) = 255; %creating a white background

%creating the visual X and Y axis

I(100, :) = 0;

I(:, 100) = 0;

% in this case the lines plotted are:

% 2x + 3y = 1 (this is visible as a black line)

% 7x + 18y = 208 (this is visible as a gray line)

% after finding the y coordinate for the respective x coordinate

% calculated coordinates are tranferred to the new origin (100,100)

for x=-50:50

y = (1 - 2*x)/3;

I(uint8(100-y), uint8(100+x)) = 0;

y = (208 - 7*x)/18;

I(uint8(100-y), uint8(100+x)) = 128;

end

imshow(I);

Listing 2 for Problem 2

% Creating the original image

I = zeros(200, 200, 'uint8');

I(:,:) = 0;

for i=50:150

for j=50:150

I(i,j) = 255;

end

end

imshow(I); figure;

J = zeros(200, 200, 'uint8');

ty=-100; %parameter for translation in y direction

theta = pi/4; %angle for rotation

% Derivation of this matrix is explained in the documentation

T= [ cos(theta) sin(theta) 0

-sin(theta) cos(theta) 0

tx*cos(theta)-ty*sin(theta)-tx tx*sin(theta)+ty*cos(theta)-ty 1];

for i=50:150

for j=50:150

Y = [i j 1]*T;

J(uint8(Y(1)),uint8(Y(2))) = 255;

end

end

imshow(J); figure;

% original image....

Tinv = inv(T);

for i= 2:199

for j= 2:199

Y = [i j 1]*Tinv;

if 2<=uint8(Y(1)) && uint8(Y(1))<=199 && 2<=uint8(Y(2)) &&

uint8(Y(2))<=199

J(i,j) = I(uint8(Y(1)),uint8(Y(2)));

end

end

end

imwrite(J, 'result.bmp');

imshow(J);

Listing for Problem 3 (Decimation)

%Listing for Porblem 3, Lab challenge 2

%image. For example while decimating by a factor of 4 all the rows and

%columns which are at a distance of 4 are only taken into consideration

to

%for the new image. Hence per one pixel we are actually removing the

%informaton of some 4 pizels on each of the pixel's side, i.e. 4 above,

4

%below 4 each on left and right sides.

%decimation by a factor of 2

J= zeros(size(I,1)/2, size(I,2)/2, 'uint8');

k=1;

for i=1:2:size(I,1)

l=1;

for j = 1:2:size(I,2)

J(k,l) = I(i,j);

l=l+1;

end

k=k+1;

end

imwrite(J,'rose_decimate2.bmp');

imshow(J); figure;

%decimation by a factor of 4

J= zeros(size(I,1)/4, size(I,2)/4, 'uint8');

k=1;

for i=1:4:size(I,1)

l=1;

for j = 1:4:size(I,2)

J(k,l) = I(i,j);

l=l+1;

end

k=k+1;

end

imwrite(J,'rose_decimate4.bmp');

imshow(J); figure;

%decimation by a factor of 8

J= zeros(size(I,1)/8, size(I,2)/8, 'uint8');

k=1;

for i=1:8:size(I,1)

l=1;

for j = 1:8:size(I,2)

J(k,l) = I(i,j);

l=l+1;

end

k=k+1;

end

imwrite(J,'rose_decimate8.bmp');

imshow(J);

I = imread('rose_decimate2.bmp');

% Parameters for scaling by a factor of 2 (i.e. zooming by 2

sx=2; %Scale parameter in x direction

sy=2; %Scale paramter in y direction

T = [ 2 0 0

0 2 0

0 0 1 ];

tform=maketform('affine', T);

%Perform scaling using 'Nearest Neighbor' method

g= imtransform(I, tform, 'nearest');

imwrite(g,'nearest_interpolated.bmp');

g= imtransform(I, tform, 'bilinear');

imwrite(g,'bilinear_interpolated.bmp');

g= imtransform(I, tform, 'bicubic');

imwrite(g,'bicubic_interpolated.bmp');

- Adding and Subtracting AnglesTransféré parMuhammad Ijaz
- iready-sample-diagnostic-items-mathTransféré parapi-373598912
- course outlineTransféré parapi-294158678
- Writing Algebraic Equations PracticeTransféré parMr. Peterson
- 2011 PSPM Kedah Add Maths 2 w AnsTransféré parjee2kk
- grade 8 lesson 6 algebra and algebraic reasoningTransféré parapi-249796897
- Math 062 Glossary_English Language Document_United States_English Glossary ReviewTransféré parRachel Sakhi
- CONTASSSTransféré parluiz_andrade_K
- rationalequationslesson 1Transféré parapi-299165253
- geometry researchTransféré parapi-280782230
- SimmondsTransféré parRui Cb
- sp_add_maths_kbsmTransféré parSaiyidatina Balkhis
- Numerical Methods IntroTransféré parRobin Singh
- NNTDM-20-2-20-28Transféré parhappymark2
- day 13Transféré parapi-245016022
- Engineering-Mathematics-1 (1).pdfTransféré parزكرياء بنحيرت
- Simultaneous Linear EquationTransféré parDimas Baskoro Heryunanto
- 2011-2012 Hs Course Descriptions 2011 FinalTransféré parIan Hardy
- Two Degree Non Homogenous Differential EquationsTransféré parTushar Gupta
- Grade 8 Math Curriculum 2018-2019Transféré parDaniel Walsh
- 15616133 Engineering Graphics Question BankTransféré parSiva Kumar
- Reasonable Basic Algebra-All3review-discussionsTransféré parNick Te
- lesson with differentiationTransféré parapi-302927915
- g8m4l11- standard form of a linear equationTransféré parapi-276774049
- Intersection of planesTransféré parEugene Sze
- Central PlaceTransféré parAtul Saini
- IIT_JEE2011_TS.pdfTransféré parsaif alam
- practice solving literal equationsTransféré parapi-277541665
- 2009-hsc-exam-mathematics-extension-2Transféré parJun Nyap
- Syllabus CH Chemical Engineering 2017Transféré paraditya_lomte

- ucf (1)Transféré parapi-26783388
- ucf (1)Transféré parapi-26783388
- Thesis Report CorrectedTransféré parapi-26783388
- Thesis Presentation FinalTransféré parapi-26783388
- Thesis Presentation FinalTransféré parapi-26783388
- sudhirl_Ram1Transféré parapi-26783388
- sudhirl_Ram1Transféré parapi-26783388
- sudhirl_RamfinalTransféré parapi-26783388
- Ramayan SetuTransféré parapi-26783388
- DAC_AD7541 (1)Transféré parapi-26783388
- DAC_AD7541 (1)Transféré parapi-26783388
- DSP Sp3 ManualTransféré parapi-26783388
- UcfTransféré parapi-26783388
- Dsp Lab Manual (1)Transféré parapi-26783388
- Dsp Lab Manual (1)Transféré parapi-26783388
- 1_Introduction to ScilabTransféré parapi-26783388
- Rupul_safaya_thesis for Multipath FadingTransféré parapi-26783388
- Who Test WhomTransféré parapi-26783388
- subjectsSkillsForSWDevTransféré parapi-26783388
- IT523 Lab Challenge 3 Report[1]Transféré parapi-26783388
- Digital Communication Receiver Design Course ContentTransféré parapi-26783388
- Lecture 21bTransféré parapi-26783388
- Dip Lab Module Challenge#1to5Transféré parapi-26783388
- MosfetTransféré parapi-26783388
- SocTransféré parapi-26783388
- BookTransféré parapi-26783388
- Lab Challenge 1 Report MtechGroup[1]Transféré parapi-26783388
- MOSFET ParametersTransféré parapi-26783388
- StsTransféré parapi-26783388

- “Comprendiendo agencias y resistencias: niñ@s en situaciónes de violencias doméstica.”Transféré parSeminari Interdisciplinar de Metodologia de Recerca Feminista
- Management and cost accountingTransféré parJITIN01007
- E-Blood Bank Application using Cloud ComputingTransféré parIRJET Journal
- TwiningTransféré pargivamathan
- Limitations of the Ferrozine Method for Quantitative Assayof Mineral Systems for Ferrous and Total IronTransféré parBryan Flores Mogollon
- Lv DilatationTransféré parFebryan Yovi Saputra
- Teaching Art Using Technology- The Views of High School Students in GreeceTransféré parkidszalor1412
- 14Transféré parNutan Karamcheti
- Shushan KosmetTransféré partherempongss
- An Estrogen Receptor-based Trans Activator XVE...Transféré parFauziah Abu Bakar
- Etap Electrical Tutorial PDFTransféré parGary
- Infanticide in Ancient RomeTransféré parJ. R. Silvey
- Gelinas-Dull_8e_Chapter_15_Revised_September_2009.pptTransféré parmicaerguiza
- 36BuffLRev165Transféré parzac
- Foundation IELTS Masterclass SB 2015 175pTransféré parJeyson López
- Burning and CoolingTransféré parNguyen Thien Tung
- Metatranscriptomica Revela Diferenciasenergeticas in Situ y Metab Del Nitrogeno Entre Simbiontes de Aperturas Hidrotermales Sanders Et Al 2013Transféré parvalenciabasto
- Circuit.cellar.090.Jan.1998Transféré parsarah kaya
- 416_10_MongoTransféré parDiana Roxana
- Developing Client ComponentsTransféré parParvez2z
- netswipe-mobile-sdk-implementation-guide-for-android_v1_2_1_jumio_sdk.pdfTransféré parbsecsr71
- Data Acquisition System High SpeedTransféré parEsteban Rodriguez
- PHY101Transféré parDaniel Catolico
- Building in the NorthTransféré parDianna Lambert
- Bauwa JiTransféré parsambitdwivedi
- Rr410507 Digital Speech and Image ProcessingTransféré parvasuvlsi
- Place Meaning and Significance of the Traditional ShoppingTransféré parMei-Ann Cayabyab-Patano
- UT Dallas Syllabus for soc3342.001 06s taught by Meryl Nason (mnason)Transféré parUT Dallas Provost's Technology Group
- Tox 5301 Syllabus.docTransféré parAnonymous tPsyiz
- Energy MetabolismTransféré parNorberto R. Bautista