Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 3

UNIVERSITETI POLITEKNIK I TIRANËS

FAKULTETI I TEKNOLOGJISË DHE INFORMACIONIT


DEPARTAMENTI I ELEKTRONIKËS DHE TELEKOMUNIKACIONIT

DETYRË KURSI

Tema : Zgjidhje ushtrimesh


Lënda: Analizë Numerike

Punoi:
1. Alisja Mezini
2. Andeta Ilnica
3. Ari Basho
4. Ariena Silo

Pranoi:
Msc. Roberto Datja

Tiranë , Janar , 2022


GJEOMETRIKISHT

f(x) = f1(x) – f2(x)

f1(x) = ln(x)

f2(x) = 2-x

⇒ f1(x) dhe f2(x) ka një


rrënjë në segmentin

I = [0,5;2]

ANALITIKISHT

f(x) = ln(x) + x – 2 është I vazhdueshëm në I = [0,5;2]


f(a)・f(b) = (-2,1931)・0,6931 = -1,52 < 0
f(a) = f(0,5) = ln(0,5) + 0,5 – 2 = -2,1931 < 0
⇒ Ǝ c ∊ [ 0,5;2] , f(c) = 0
f(b) = f(2) = ln(2) + 2 – 2 = 0,6931 > 0

f’(x) = ( ln(x) + x – 2 )’ = 1/x + 1


f’(x) → ruan shenjën positive në [ 0,5;2 ]
f’(a) = f’(0,5) = 1/0,5 + 1 = 3 > 0
⇒ Rrënja është e vetme.
f’(b) = f’(2) = 1/2 + 1 = 1,5 > 0

METODA E SEKANTES

f (x n )
x n−x n−1
xn+1 = xn - f (x n)−f ( xn −1 ) = xn – f(xn)
f (x n )−f (x n−1)
x n−x n−1
⇒ x0 = 0,5
f(x0) = f(0,5) = ln(0,5) + 0,5 -2 = (-2,19)
⇒ x1 = 1
f(x1) = f(1) = ln(1) + 1 -2 = (-1)
⇒ x2 = 2
f(x2) = f(2) = ln(2) + 2 -2 = 0,69

Hapi 1 :

(x0=0,5 ; x1=1)

x 1−x 0 1−0 , 5
⇒ x2 = x1 – f(x1) = 1 – (-1) = 1,42
f (x 1 )−f (x 0) (−1)−(−2 ,19)

Hapi 2 :

(x1=1 ; x2=2)

x 2−x 1 2−1
⇒ x3 = x2 – f(x2) = 2 – 0,69 = 1,59
f (x 2 )−f (x 1) 0 , 69−(−1)

MATLAB
⇒ Kodi ne Matlab :

You might also like