Sunteți pe pagina 1din 83

Metode numerice n ingineria electric- LUCRARI DE LABORATOR

LABORATOR Spt. 3 /4

ANALIZA CU ELEMENTE FINITE A SISTEMELOR MECANICE CU


RESORTURI
Descriere teoretic
Se consider un sistem mecanic format din patru resorturi coliniare, de caracteristici
ki , i 1...4 , care este sub aciunea forelor externe F2 , F3 i F4 (Figura 1a), paralele cu

resorturile. Utiliznd metoda elementelor finite, ne propunem s determinm distribuia


deplasrilor n sistemul de resorturi i reaciunile n perei.
(k1 = a, k2 = 2a, k3 = 4a, k4 = a, F2 P , F3 2 P , F4 3P ).

Figura 1a. Sistemul fizic dat.


Pentru a calcula deplasrile capetelor libere ale resorturilor (u2, u3 i u4) i reaciunile
provocate de reazeme (F1 i F5) se consider modelul analitic, constituit din
1. Ecuaia de echilibru F1 F2 F3 F4 F5 0 , (1)
2. Ecuaia constitutiv F k u , (2)
3. Condiii la limit u1 0 ; u5 0 . (3)
Fiecare element se caracterizeaz prin prezena unui resort cu un coeficient de
proporionalitate k i a dou noduri marginale ( i , j ). Pentru fiecare nod se noteaz variabilele

problemei, adic forele nodale Fi , F j i deplasrile ui i u j (Figura 1b).

Figura 1b. Element finit generic.


Metode numerice n ingineria electric- LUCRARI DE LABORATOR

Aplicand Principiul suprapunerii efectelor rezult Modelul elemental de comportare

Fi Fia Fib k ui k u j
, (10)
F j F ja F jb k ui k u j
adic
k k ui Fi
k , (11)
k u j F j

i care reprezint relaia fore-deplasri nodale.


Particulariznd acest model pentru fiecare element finit n parte i raportnd la ntreaga
configuraie nodal a sistemului, se poate genera ntreaga structur funcional a sistemului
mecanic considerat, sau a altor sisteme similare.
n cazul sistemului considerat, se scriu pentru fiecare resort ecuaiile elementale i se
expandeaz (adic se raporteaz la sistemul global de noduri).
Asamblnd contribuia fiecrui element si aplicnd principiul suprapunerii efectelor, se
obine sistemul asamblat care modeleaz sistemul fizic de resorturi,
adic
k1 k1 0 0 0 u1 F1
k k k k2 0 0 u2
1 1 2 F2
0 k2 k 2 k3 k3 0 u3 F3 , (13)

0 0 k3 k3 k4 k4 u4 F4
0 0 0 k4 k4 u5 F5

Ecuaia (13) reprezint modelul global de comportare a sistemului considerat.


Condiiile la limit u1 0, u5 0 se implementeaz sub forma

1 0 0 0 0 u1 0
0 k k k2 0 0 u F
1 2 2 2
0 k2 k2 k3 k3 0 u3 F3 .

0 0 k3 k3 k4 0 u4 F4
0 0 0 0 1 u5 0
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

Se observ c aceast ecuaie matriceal este echivalent cu un sistem de 5 ecuaii, n

care prima i ultima reprezint condiiile la limit u1 0, u5 0 .


Se cunosc forele F2 = P, F3 = Q i F4 = R, sub forma
1 0 0 0 0 u1 0
0 k k k2 0 0 u2 P
1 2
0 k2 k2 k3 k3 0 u3 Q . (14)

0 0 k3 k3 k4 0 u4 R
0 0 0 0 1 u5 0

Din acest sistem matriceal se determin deplasrile u2, u3, u4 i valorile banale
u1 0, u5 0 . Valorile u2, u3 i u4 s-ar putea determina considernd, n locul acestui sistem

matriceal, doar ecuaiile 2, 3 i 4 din sistemul algebric corespunztor.


nlocuind n ecuaia matriceal (13) valorile cunoscute u2 , u3 , u4 , u1 = 0, u5 = 0 i forele
P, Q i R cunoscute, rezult ecuaia matriceal
k1 k1 0 0 0 0 F1
k k k k2 0 0 u2 P
1 1 2
0 k2 k2 k3 k3 0 u3 Q ,

0 0 k3 k3 k4 k4 u4 R
0 0 0 k4 k4 0 F5

de unde se determin forele F1 i F5 din reazemele sistemului. Aceste dou fore se pot
determina, evident, i din sistemul algebric format din prima i a cincea ecuaie a sistemului
corespunztor.

Rezolvare numeric n Matlab.


a) Realizai aplicaia Matlab sub forma unei funcii cu datele de intrare k1 = 1, k2 = 2, k3
= 3, k4 = 4, F2 = 10, F3 = 20 i F4 = 30 numerice.

function [u,F,suma]=resorturi1(k1, k2, k3, k4, F2, F3, F4)


% matricea proprietatilor caracteristice
M=[k1 -k1 0 0 0;...
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

-k1 k1+k2 -k2 0 0;...


0 -k2 k2+k3 -k3 0;...
0 0 -k3 k3+k4 -k4;...
0 0 0 -k4 k4];
% impunerea conditiilor la limita in matricea sistemului
LM=M;
LM(1,1)=1; LM(5,5)=1;
LM(1,2)=0; LM(2,1)=0; LM(4,5)=0; LM(5,4)=0;
% afisarea celor doua matrici
M
LM
% vectorul fortelor cu conditii la limita impuse
LF=[0;F2;F3;F4;0]
% calcularea deplasarilor si reactiunilor la capete
u=inv(LM)*LF
F=M*u
disp('Verificare: sistemul trebuie sa ramana in echilibru')
sum(F)

Apelarea funciei din linia de comand:


>> [u,F,suma]=resorturi1(1, 2, 3, 4, 10, -20, 30)

b) Realizai aplicaia Matlab sub forma unei funcii care produce rezultatele
simbolic.
function [u,F,suma]=resorturi2

syms k1 k2 k3 k4 F2 F3 F4 a P

k1=a;k2=2*a;k3=4*a;k4=a;
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

F2=P;F3=-2*P;F4=3*P;
%k1=1; k2=2; k3=3; k4=4;
%F2=10; F3=-20; F4=30;
% matricea proprietatilor caracteristice
M=[k1 -k1 0 0 0;...
-k1 k1+k2 -k2 0 0;...
0 -k2 k2+k3 -k3 0;...
0 0 -k3 k3+k4 -k4;...
0 0 0 -k4 k4];
% impunerea conditiilor la limita in matricea sistemului
LM=M;
LM(1,1)=1; LM(5,5)=1;
LM(1,2)=0; LM(2,1)=0; LM(4,5)=0; LM(5,4)=0;
% afisarea celor doua matrici
M
LM
% vectorul fortelor cu conditii la limita impuse
LF=[0;F2;F3;F4;0]
% calcularea deplasarilor si reactiunilor la capete
u=inv(LM)*LF
F=M*u
disp('Verificare: sistemul trebuie sa ramana in echilibru')
sum(F)

Apelarea funciei din linia de comand:


>> [u,F,suma]=resorturi2
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

Aplicaie laborator 1
S se simuleze un sistem de 3 resorturi n care se cunosc k 1, k2, k3 i forele F2 , F3 care
acioneaz n nodurile 2 i 3. S se determine deplasrile nodurilor libere u 2 i u3 i reaciunile
F1 i F4.
a) Realizai aplicaia Matlab sub forma unei funcii cu datele de intrare numerice
k1 = 1, k2 = 3, k3 = 2, F2 = 15, F3 = -13.
Listing program
function [u,F,suma]=resorturi1(k1, k2, k3, F2, F3)
% matricea proprietatilor caracteristice
M=[k1 -k1 0 0 ; -k1 k1+k2 -k2 0 ; 0 -k2 k2+k3 -k3 ; 0 0
-k3 k3];
% impunerea conditiilor la limita in matricea sistemului
(elementele din matricea M de pe pozitia 1,1 si n,n sunt
1, iar cele de pe marginea matricei raman 0 cu exceptia
celor 2)
LM=M;
LM(1,1)=1; LM(4,4)=1;
LM(1,2)=0; LM(2,1)=0; LM(4,3)=0; LM(3,4)=0;
% afisarea celor doua matrici
M
LM
% vectorul fortelor cu conditii la limita impuse (se
inlocuiesc cu 0 in matricea coloana F elementul 1,1 si
n,n)
LF=[0;F2;F3;0]
% calcularea deplasarilor si reactiunilor la capete
u=inv(LM)*LF
F=M*u
disp('Verificare: sistemul trebuie sa ramana in
echilibru')
sum(F)
% suma trebuie sa fie 0 ca sa fie in echilibru
end
command:
[u,F,suma]=resorturi1(1,3,2,15,-13)
Afisare rezultate
[u,F,suma]=resorturi1(1,3,2,15,-13)

M=
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

1 -1 0 0
-1 4 -3 0
0 -3 5 -2
0 0 -2 2

LM =

1 0 0 0
0 4 -3 0
0 -3 5 0
0 0 0 1

LF =

0
15
-13
0

u=

0
3.2727
-0.6364
0
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

F=

-3.2727
15.0000
-13.0000
1.2727

Verificare: sistemul trebuie sa ramana in echilibru

ans =

-2.2204e-16

b) Realizai aplicaia Matlab sub forma unei funcii care produce rezultatele simbolic
pentru datele de intrare k1 = a, k2 = 3a, k3 = 2a, F2 = 15F, F3 = -13F.

Listing program
function [u,F,suma]=resorturi2
syms k1 k2 k3 F2 F3 a P
k1=a;
k2=3*a;
k3=2*a;
F2=15*P;
F3=-13*P;
% matricea proprietatilor caracteristice
M=[k1 -k1 0 0 ; -k1 k1+k2 -k2 0 ; 0 -k2 k2+k3 -k3 ; 0 0
-k3 k3];
% impunerea conditiilor la limita in matricea sistemului
(elementele din matricea M de pe pozitia 1,1 si n,n sunt
1, iar cele de pe marginea matricei raman 0 cu exceptia
celor 2)
LM=M;
LM(1,1)=1; LM(4,4)=1;
LM(1,2)=0; LM(2,1)=0; LM(4,3)=0; LM(3,4)=0;
% afisarea celor doua matrici
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

M
LM
% vectorul fortelor cu conditii la limita impuse (se
inlocuiesc cu 0 in matricea coloana F elementul 1,1 si
n,n)
LF=[0;F2;F3;0]
% calcularea deplasarilor si reactiunilor la capete
u=inv(LM)*LF
F=M*u
disp('Verificare: sistemul trebuie sa ramana in
echilibru')
sum(F)
end

command: [u,F,suma]=resorturi2

Afisare rezultate
[u,F,suma]=resorturi2

M=

[ a, -a, 0, 0]
[ -a, 4*a, -3*a, 0]
[ 0, -3*a, 5*a, -2*a]
[ 0, 0, -2*a, 2*a]

LM =

[ 1, 0, 0, 0]
[ 0, 4*a, -3*a, 0]
[ 0, -3*a, 5*a, 0]
[ 0, 0, 0, 1]

LF =
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

0
15*P
-13*P
0

u=

0
(36*P)/(11*a)
-(7*P)/(11*a)
0

F=

-(36*P)/11
15*P
-13*P
(14*P)/11

Verificare: sistemul trebuie sa ramana in echilibru

ans =

Aplicaie laborator 2
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

Se consider un sistem de 5 resorturi n care se cunosc


k1 = 1, k2 = 2, k3 = 3, k4 = 4, k5 = 1;
solicitat axial de forele F2 = -8, F3 = 6 , F4 = 3, F5 = -10, care acioneaz asupra sistemului
de resorturi in nodurile 2, 3, 4, respectiv 5.
S se determine deplasrile nodurilor libere u2 , u3, u4 i u5 i reaciunile F1 i F6.

a) Realizai aplicaia Matlab sub forma unei funcii cu datele de intrare numerice
k1 = 1, k2 = 2, k3 = 3, k4 = 4, k5 = 1, F2 = -8, F3 = 6 , F4 = 3, F5 = -10.
Listing program
function [u,F,suma]=resorturi1(k1, k2, k3, k4, k5, F2, F3,
F4, F5)
% matricea proprietatilor caracteristice
M=[k1 -k1 0 0 0 0 ; -k1 k1+k2 -k2 0 0 0; 0 -k2 k2+k3 -k3
0 0 ;
0 0 -k3 k3+k4 -k4 0; 0 0 0 -k4 k4+k5 -k5; 0 0 0 0 -k5 k5];
% impunerea conditiilor la limita in matricea sistemului
(elementele din matricea M de pe pozitia 1,1 si n,n sunt
1, iar cele de pe marginea matricei raman 0 cu exceptia
celor 2)
LM=M;
LM(1,1)=1; LM(4,4)=1;
LM(1,2)=0; LM(2,1)=0; LM(5,6)=0; LM(6,5)=0;
% afisarea celor doua matrici
M
LM
% vectorul fortelor cu conditii la limita impuse (se
inlocuiesc cu 0 in matricea coloana F elementul 1,1 si
n,n)
LF=[0;F2;F3;F4;F5;0]
% calcularea deplasarilor si reactiunilor la capete
u=inv(LM)*LF
F=M*u
disp('Verificare: sistemul trebuie sa ramana in
echilibru')
sum(F)
% suma trebuie sa fie 0 ca sa fie in echilibru
end
command: [u,F,suma]=resorturi1(1,2,3,4,1,-8,6,3,-10)
Afisare rezultate
M=

1 -1 0 0 0 0
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

-1 3 -2 0 0 0
0 -2 5 -3 0 0
0 0 -3 7 -4 0
0 0 0 -4 5 -1
0 0 0 0 -1 1

LM =

1 0 0 0 0 0
0 3 -2 0 0 0
0 -2 5 -3 0 0
0 0 -3 1 -4 0
0 0 0 -4 5 0
0 0 0 0 0 1

LF =

0
-8
6
3
-10
0

u=
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

0
-2.0234
0.9648
0.9570
-1.2344
0

F=

2.0234
-8.0000
6.0000
8.7422
-10.0000
1.2344

Verificare: sistemul trebuie sa ramana in echilibru

ans =

b) Realizai aplicaia Matlab sub forma unei funcii care produce rezultatele simbolic
pentru datele de intrare k1 = a, k2 = b, k3 = a+b, k4 = 2a, k5 = 3b, F2 = -8F, F3 = 6F ,
F4 = 3F, F5 = -10F.
Listing program
function [u,F,suma]=resorturi2
syms k1 k2 k3 k4 k5 F2 F3 F4 F5 a b P
k1=a; k2=b; k3=a+b; k4=2*a; k5=3*b;
F2=-8*P; F3=6*P; F4=3*P; F5=-10*P
% matricea proprietatilor caracteristice
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

M=[k1 -k1 0 0 0 0 ; -k1 k1+k2 -k2 0 0 0; 0 -k2 k2+k3 -k3


0 0 ;
0 0 -k3 k3+k4 -k4 0; 0 0 0 -k4 k4+k5 -k5; 0 0 0 0 -k5 k5];
% impunerea conditiilor la limita in matricea sistemului
(elementele din matricea M de pe pozitia 1,1 si n,n sunt
1, iar cele de pe marginea matricei raman 0 cu exceptia
celor 2)
LM=M;
LM(1,1)=1; LM(4,4)=1;
LM(1,2)=0; LM(2,1)=0; LM(5,6)=0; LM(6,5)=0;
% afisarea celor doua matrici
M
LM
% vectorul fortelor cu conditii la limita impuse (se
inlocuiesc cu 0 in matricea coloana F elementul 1,1 si
n,n)
LF=[0;F2;F3;F4;F5;0]
% calcularea deplasarilor si reactiunilor la capete
u=inv(LM)*LF
F=M*u
disp('Verificare: sistemul trebuie sa ramana in
echilibru')
sum(F)
% suma trebuie sa fie 0 ca sa fie in echilibru

Command: [u,F,suma]=resorturi2
Afisare rezultate
F5 =

-10*P

M=

[ a, -a, 0, 0, 0, 0]
[ -a, a + b, -b, 0, 0, 0]
[ 0, -b, a + 2*b, - a - b, 0, 0]
[ 0, 0, - a - b, 3*a + b, -2*a, 0]
[ 0, 0, 0, -2*a, 2*a + 3*b, -3*b]
[ 0, 0, 0, 0, -3*b, 3*b]
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

LM =

[ 1, 0, 0, 0, 0, 0]
[ 0, a + b, -b, 0, 0, 0]
[ 0, -b, a + 2*b, - a - b, 0, 0]
[ 0, 0, - a - b, 1, -2*a, 0]
[ 0, 0, 0, -2*a, 2*a + 3*b, 0]
[ 0, 0, 0, 0, 0, 3*b]

LF =

0
-8*P
6*P
3*P
-10*P
0

u=

0
(20*P*(a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) - (3*P*(2*a^2*b +
5*a*b^2 + 3*b^3))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) - (8*P*(6*a^3 +
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

15*a^2*b - 2*a^2 + 8*a*b^2 - 7*a*b + 3*b^3 - 6*b^2))/(6*a^4 +


21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) - (6*P*(- 4*a^2*b + 2*a*b + 3*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3)
(20*P*(a^3 + 2*a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(3*P*(2*a^3 + 7*a^2*b + 8*a*b^2 + 3*b^3))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) - (6*P*(- 4*a^3 - 4*a^2*b + 2*a^2 + 5*a*b + 3*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (8*P*b*(- 4*a^2 + 2*a + 3*b))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3)
(20*P*(a^3 + 3*a^2*b + a*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) - (6*P*(a + b)^2*(2*a + 3*b))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) - (3*P*(2*a + 3*b)*(a^2 + 3*a*b + b^2))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) + (8*P*b*(a + b)*(2*a + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)
(16*P*a*b*(a + b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(6*P*a*(a^2 + 3*a*b + b^2))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(12*P*a*(a + b)^2)/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) - (10*P*(a^3 +
3*a^2*b - a^2 + 3*a*b^2 - 3*a*b + b^3 - b^2))/(6*a^4 + 21*a^3*b -
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -


3*b^3)

F=

a*((3*P*(2*a^2*b + 5*a*b^2 + 3*b^3))/(6*a^4 + 21*a^3*b - 2*a^3 +


19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(20*P*(a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) + (8*P*(6*a^3 +
15*a^2*b - 2*a^2 + 8*a*b^2 - 7*a*b + 3*b^3 - 6*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (6*P*(- 4*a^2*b + 2*a*b + 3*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3))

b*((6*P*(- 4*a^3 - 4*a^2*b + 2*a^2 + 5*a*b + 3*b^2))/(6*a^4 +


21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (3*P*(2*a^3 + 7*a^2*b + 8*a*b^2 + 3*b^3))/(6*a^4
+ 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) - (20*P*(a^3 + 2*a^2*b + a*b^2))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) - (8*P*b*(- 4*a^2 + 2*a + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) - (a +
b)*((3*P*(2*a^2*b + 5*a*b^2 + 3*b^3))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

(20*P*(a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -


9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) + (8*P*(6*a^3 +
15*a^2*b - 2*a^2 + 8*a*b^2 - 7*a*b + 3*b^3 - 6*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (6*P*(- 4*a^2*b + 2*a*b + 3*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3))
b*((3*P*(2*a^2*b + 5*a*b^2 + 3*b^3))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(20*P*(a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) + (8*P*(6*a^3 +
15*a^2*b - 2*a^2 + 8*a*b^2 - 7*a*b + 3*b^3 - 6*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (6*P*(2*a*b - 4*a^2*b + 3*b^2))/(6*a^4 + 21*a^3*b
- 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3)) - (a + 2*b)*((6*P*(2*a^2 - 4*a^2*b - 4*a^3 + 5*a*b +
3*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b +
11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) + (3*P*(2*a^3 + 7*a^2*b +
8*a*b^2 + 3*b^3))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) - (20*P*(a^3 +
2*a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) - (8*P*b*(2*a -
4*a^2 + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b +
11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) - (a + b)*((20*P*(a^3 +
3*a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) - (6*P*(a +
b)^2*(2*a + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b
+ 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) - (3*P*(2*a + 3*b)*(a^2 +
3*a*b + b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b +
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) + (8*P*b*(a + b)*(2*a + 3*b))/


(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 -
11*a*b^2 + 3*b^4 - 3*b^3))
(3*a + b)*((20*P*(a^3 + 3*a^2*b + a*b^2))/(6*a^4
+ 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) - (6*P*(a + b)^2*(2*a + 3*b))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) - (3*P*(2*a + 3*b)*(a^2 + 3*a*b + b^2))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) + (8*P*b*(a + b)*(2*a + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) + (a
+ b)*((6*P*(2*a^2 - 4*a^2*b - 4*a^3 + 5*a*b + 3*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (3*P*(2*a^3 + 7*a^2*b + 8*a*b^2 + 3*b^3))/(6*a^4
+ 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) - (20*P*(a^3 + 2*a^2*b + a*b^2))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) - (8*P*b*(2*a - 4*a^2 + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) +
2*a*((10*P*(a^3 + 3*a^2*b - a^2 + 3*a*b^2 - 3*a*b + b^3 - b^2))/
(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 -
11*a*b^2 + 3*b^4 - 3*b^3) + (6*P*a*(a^2 + 3*a*b + b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (12*P*a*(a + b)^2)/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(16*P*a*b*(a + b))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3))

- 2*a*((20*P*(a^3 + 3*a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 +


Metode numerice n ingineria electric- LUCRARI DE LABORATOR

19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -


(6*P*(a + b)^2*(2*a + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(3*P*(2*a + 3*b)*(a^2 + 3*a*b + b^2))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) +
(8*P*b*(a + b)*(2*a + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) - (2*a
+ 3*b)*((10*P*(a^3 + 3*a^2*b - a^2 + 3*a*b^2 - 3*a*b + b^3 - b^2))/
(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 -
11*a*b^2 + 3*b^4 - 3*b^3) + (6*P*a*(a^2 + 3*a*b + b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (12*P*a*(a + b)^2)/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(16*P*a*b*(a + b))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3))

3*b*((10*P*(a^3 + 3*a^2*b - a^2 + 3*a*b^2 - 3*a*b + b^3 - b^2))/


(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 -
11*a*b^2 + 3*b^4 - 3*b^3) + (6*P*a*(a^2 + 3*a*b + b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (12*P*a*(a + b)^2)/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(16*P*a*b*(a + b))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3))

Verificare: sistemul trebuie sa ramana in echilibru

ans =
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

b*((6*P*(2*a^2 - 4*a^2*b - 4*a^3 + 5*a*b + 3*b^2))/(6*a^4 +


21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (3*P*(2*a^3 + 7*a^2*b + 8*a*b^2 + 3*b^3))/(6*a^4
+ 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) - (20*P*(a^3 + 2*a^2*b + a*b^2))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) - (8*P*b*(2*a - 4*a^2 + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) - (a +
b)*((20*P*(a^3 + 3*a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(6*P*(a + b)^2*(2*a + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(3*P*(2*a + 3*b)*(a^2 + 3*a*b + b^2))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) +
(8*P*b*(a + b)*(2*a + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) - (a +
2*b)*((6*P*(2*a^2 - 4*a^2*b - 4*a^3 + 5*a*b + 3*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (3*P*(2*a^3 + 7*a^2*b + 8*a*b^2 + 3*b^3))/(6*a^4
+ 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) - (20*P*(a^3 + 2*a^2*b + a*b^2))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) - (8*P*b*(2*a - 4*a^2 + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) -
2*a*((20*P*(a^3 + 3*a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(6*P*(a + b)^2*(2*a + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(3*P*(2*a + 3*b)*(a^2 + 3*a*b + b^2))/(6*a^4 + 21*a^3*b - 2*a^3 +
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) +


(8*P*b*(a + b)*(2*a + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) - (a +
b)*((3*P*(2*a^2*b + 5*a*b^2 + 3*b^3))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(20*P*(a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) + (8*P*(6*a^3 +
15*a^2*b - 2*a^2 + 8*a*b^2 - 7*a*b + 3*b^3 - 6*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (6*P*(2*a*b - 4*a^2*b + 3*b^2))/(6*a^4 + 21*a^3*b
- 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3)) + (3*a + b)*((20*P*(a^3 + 3*a^2*b + a*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) - (6*P*(a + b)^2*(2*a + 3*b))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) - (3*P*(2*a + 3*b)*(a^2 + 3*a*b + b^2))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) + (8*P*b*(a + b)*(2*a + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) - (2*a
+ 3*b)*((10*P*(a^3 + 3*a^2*b - a^2 + 3*a*b^2 - 3*a*b + b^3 - b^2))/
(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 -
11*a*b^2 + 3*b^4 - 3*b^3) + (6*P*a*(a^2 + 3*a*b + b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (12*P*a*(a + b)^2)/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(16*P*a*b*(a + b))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) +
a*((3*P*(2*a^2*b + 5*a*b^2 + 3*b^3))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

(20*P*(a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -


9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) + (8*P*(6*a^3 +
15*a^2*b - 2*a^2 + 8*a*b^2 - 7*a*b + 3*b^3 - 6*b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (6*P*(2*a*b - 4*a^2*b + 3*b^2))/(6*a^4 + 21*a^3*b
- 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3)) + b*((3*P*(2*a^2*b + 5*a*b^2 + 3*b^3))/(6*a^4 + 21*a^3*b
- 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) - (20*P*(a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) +
(8*P*(6*a^3 + 15*a^2*b - 2*a^2 + 8*a*b^2 - 7*a*b + 3*b^3 -
6*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b +
11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) + (6*P*(2*a*b - 4*a^2*b +
3*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b +
11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) + (a + b)*((6*P*(2*a^2 -
4*a^2*b - 4*a^3 + 5*a*b + 3*b^2))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) +
(3*P*(2*a^3 + 7*a^2*b + 8*a*b^2 + 3*b^3))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) - (20*P*(a^3 + 2*a^2*b + a*b^2))/(6*a^4 + 21*a^3*b - 2*a^3
+ 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
(8*P*b*(2*a - 4*a^2 + 3*b))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) +
2*a*((10*P*(a^3 + 3*a^2*b - a^2 + 3*a*b^2 - 3*a*b + b^3 - b^2))/
(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 -
11*a*b^2 + 3*b^4 - 3*b^3) + (6*P*a*(a^2 + 3*a*b + b^2))/(6*a^4 +
21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 +
3*b^4 - 3*b^3) + (12*P*a*(a + b)^2)/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) -
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

(16*P*a*b*(a + b))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -


9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3)) + 3*b*((10*P*(a^3
+ 3*a^2*b - a^2 + 3*a*b^2 - 3*a*b + b^3 - b^2))/(6*a^4 + 21*a^3*b -
2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 -
3*b^3) + (6*P*a*(a^2 + 3*a*b + b^2))/(6*a^4 + 21*a^3*b - 2*a^3 +
19*a^2*b^2 - 9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) +
(12*P*a*(a + b)^2)/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 -
9*a^2*b + 11*a*b^3 - 11*a*b^2 + 3*b^4 - 3*b^3) - (16*P*a*b*(a +
b))/(6*a^4 + 21*a^3*b - 2*a^3 + 19*a^2*b^2 - 9*a^2*b + 11*a*b^3 -
11*a*b^2 + 3*b^4 - 3*b^3))

Calcule matematice fundamentale in Matlab

Aplicatii
1. Determinati numarul complex z cunoscnd partea sa reala si partea
imaginara:
Re z = 2 Im z= -5
>> a=2;
>> b=-5
>> complex(a,b)
2. Sa se aproximeze prin fractii rationale numerele: rad2, rad3 din 3,
rad4din 4,rad 5din 5,rad 6 din 6

>> rats[2^(1/2),3^(1/3),4^(1/4), 5^(1/5), 6^(1/6)]


3. Sa se calculeze cu 14 zecimale valoarea fractiei 8959/3700

>> format long


>> ans=8959/3700
4. Sa se scrie numarul 6562 din baza 7 n baza 10

>> base2dec (6562,7)


5. Determinati cti metri are 1 yard

>> to=m
>> from=yd
>> unitsratio(to,from)
6. Cti inci au 0.254 m?
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>> 0.254*unitsratio(yd,m)
7. Determinati cte grade are un radian

>> unitsratio(deg,rad)
8. Transformati n grade unghiul de 57 1745

>> dms2deg(57,17,45)
9. Calculati tg113.43

>> tan(dms2rad(113.43,0,0))
10. Determinati coordonatele sferice ale punctului P3,4,12

>> [th,phi,r] = cart2sph(3,-4,-12);


11. Sa se calculeze expresiile urmatoare:

a)
>> rats(3^(1/(17+5*sqrt(2)))+3^(1/(17-5*sqrt(2))))

b)
>>sqrt(4+sqrt(7))/sqrt( 3+sqrt(5))+sqrt(4-sqrt(7))/sqrt(3-sqrt(5))

c)

>> A=log6(7)-log6(7/36)+log(5)+3^7+exp(3)

d)
>> M=abs(x-1)+2*abs(x-2)+3*abs(x-3)
>> x=4
>>M=
>>

e)

>> N=abs(1+z)+abs(1+z^2)+abs(1+z^3);
>>z=i;
>>N=
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

f)
>> pow(((1+i)/(1-i)),3)-pow(((1-i)/(1+i)),3)

g)
>> F=(pow(x,2)+3*x+1)/(pow(x,3)+2);
>> x=-1;
>> F=

h)
>> B=log3(rats(5^(1/x)));
>> x=7;
>> B=

i)

>> A=pow((2-tan(cot(x))),(1/(sin(x)-cos(x))));
>> x=pi/5;
>> A=

j)

>> C=cos(x)^4+cos(3*x)^4+cos(5*x)^4+cos(7*x)^4;
>> x=pi/8;
>>C=
>>

Tema:
1. Calculati

a)
rats(2^(1/(1+2^(1/(2+2*2^(1/(4+2*2^(1/3))))))))
ans = 499/363
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

b)
>> a=1/2;
>> b=1/3;
>> loga(logb(3/4))
>>

c)
>> rats(2^(1/7*2^(1/7*2^(1/7))))
>>

d)
>> pow((-1+rats(2^(1/3))*i))
>>

e)
>> lg(cos(dms2rad(320.39,0,0)))
>>

f)
>> cot(dms2rad(62,37,0))
2. Determinati valoarea expresiilor urmatoare:

a)
>> u=2/pi*asin(2*x/(x^2+1));
>> x=2.2;
>> u=
>>

b)
>> A= (sin(x)+x*cos(x))/(exp(x)-exp(-x)-2*sin(x));
>> x=1.6;
>> A=
>>

c)
>> A=(1+z+z^2)/(1-z+z^2);
>> z=-I;
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>A=
>>
3. Verificati daca:

a)
>> e=3^x+4^x+5^x;
>> r=6^x;
>> x=3;
>> e=
>>r=
>>

b)
>> e=x^3-3*x-14;
>>x=rats(3^(1/(7+4*2^(1/3))
>>e=
>>

c)
>> e=x^2+(1-2*i)*x-(3+i);
>> x=1+I;
>> e=
>>

d)
>> e=cos(3/7)+sin(x);
>>x=-(7*pi/8);
>> e=
>> x=21*pi/22;
>> e=
>>

4. Sa se efectueze urmatoarele operatii:

a)
>> r= base2dec(110000010,2)+base2dec(1111110000,2)
>>

b)
>> r=base2dec(12201200,6)/base2dec(1442,6)
>>
5. Determinati cti radiani reprezinta unghiul de 57 1745
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>> dms2rad(57,17,45)

Definirea tablourilor si a functiilor (in linia de


comanda)
Aplicatii
1. Sa se sorteze n ordine descrescatoare elementele vectorului x
0.76 1 20 8 7, cu precizarea indicelui fiecarui element.
>> x=[-0.76 -1 20 8 -7];
>> [y,I]=sort(x,descend);
2. Sa se determine indicii elementelor din vectorul x 0.76 1
6 8 1, a
caror valoare este egala cu 1.
>> x=[-0.76 -1 -6 8 -1]
>> u=find(x==-1)
>>
3.

>> u=[1 2 3]';


>> v=[-1 -2 -3]';
>> a=[u v];

4.
a) Transforma"i matricea A ntr-un vector coloana b ;
>> A=[1 -7 99 3;4.7 0 0.9 -7;5.7 4 5 78;-78 12 -7.4 3];
>> b=A(:);
b) Sa se extraga submatricea D de dimensiune 3x2 , ce consta din
elementele situate pe ultimele trei linii si primele doua coloane
ale matricei A .
>> D=A(2:4,1:2);
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

5. Sa se calculeze produsul scalar si cosinusul unghiului dintre vectorii

>> a=[2 1 -1];


>> x=a/2;
>> s=dot(a,x);
>> u=s/(norm(a)*norm(x));

! daca unghiul este 0 => sunt coliniari, altfel se calculeaza cos

6. n spa"iu se dau punctele A3,2,1, B4,4,0, C5,5,5, D1,5,1.


Sa se verifice daca A,B,C,D sunt coplanare.

Pasul 1: scriem punctele


>>A=[3 2 1];
>>B=[4 4 0];
>>C=[5 5 5];
>>D=[-1 5 -1];
Pasul 2: determinam expresiile analitice ale vectorilor AB, AC, AD
>> a=B-A;
>>b=C-A;
>>c=D-A;
Pasul 3: calculam produsul mixt al vectorilor AB, AC, AD
>> M=[a;b;c]
>>v=det(M);
Pasul 4: Calculam volumul tetraedului ABCD
>> v=abs(v)/6

!Daca v=0 sunt coplanar, altfel nu

7. Calcula"i produsul vectorial al vectorilor


>> u=[3 -2 1];
>> v=[0 -1 4];
>> cross(u,v);
8.

>> f=@(x) sin(2*x)+2*sin(3*x/2)


>> f (pi)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

Tema

1. Sa se genereze:
a) o matrice identitate 7x7 ;
>> ones(7)
>>
b) o matricea nula 10x10 ;
>> zeros(10)
>>

c) o matrice aleatoare 10x11 cu elemente distribuite uniform si


normal.
>> Randn(10,11)
2.

>> x=[-0.76 -1 20 8 -7];


>> (y, I)=sort(x)

3. Se considera matricea

>> C=[1 -1 0 ; 0 2 3 ; 4 0 -1]


>> C^3-2*C^2-C+14*ones(3)
>>

4.
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

! Produsul a doua matrici este posibil daca si numai daca numarul


coloanelor matricei X este egal cu numarul liniilor matricei Y => Ba, Bd,
BC, Cd, aC, dBC, adBC

>>a=[1; 0; -2]
>>B=[0 9 ; 1 -5; 3 8]
>>C=[4 1 0; 7 0 1; -1 1 1]
>> d=[0 2 -7]
>>a*d
>>d*a
>>d*B
>>C*B
>>d*C
>>C*a
>>C^2
>>d*C*B
>>a*d*C
>> a*d*C*a
>>a^2
5.

>> X=[1 3; 3 3]
>> u=find(X>=3)
>>

6.

>> A=[1 3 4 32; 5 -0.76 23 0]


>> B=A(1:2;2:3)
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

7.

>> f=@(x,y) rots(2^1/(x^2+y^2));


>>f(-1,2.5)=
>>

8. Sa se calculeze produsul mixt al vectorilor

>> a=[2 1 -1]


>> b=[3 2 1]
>> c=[0 -1 2]
>>d=cross(a,b);
>>cross(d,c)
>>
Calcul simbolic n Matlab 7.0 cu aplica!ii n Algebra

Aplicatii

1. Scrie!i sub o forma simplificata matricea

>>syms x //declaram x ca simbolic


>> A=[pow2(cos(x))+pow2(sin(x)) x^2/x; 2*sin(x)*cos(x)
exp(log(x^2))]
>> u=simple(A)
>>
2. Simplificati expresia

>> syms n
>> E=(3^(n+2)*5^n+3^n*5^(n+1))/
(3^(n+1)*5^n+2*3(n+1)*5^n);
>> simplify(E)
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

3. Calculati determinantul, transpusa si inversa simbolica pentru


urmatoarea matrice:

>> syms x
>> A[cos(x) sin(x) ; sin(x) cos(x)]
>> det(A)
>> simplify(det(A))
>> transpose(A) //transpusa
>>inv(A)

4. Sa se factorizeze expresia

>> syms x y
>> E=x^3+y*x^2-2*sqrt(3)*x^2*y-
2*sqrt(3)*x*y^2+3*y^2*x+3*y^3
>>factor(E)

5. Calculati suma
>> syms k n
>> S=simplify(symsum(1+1/(2^(k-1)),k,1,n))

6. Sa se dezvolte determinantul

iar rezultatul sa fie pus sub


forma de produs.

>> syms a b c
>> A=[a+b a+b-c b+c; a-b-c a+b a+c; a+c b+c a-b+c]
>>factor(det(A))
>>

7. Descompuneti n frac!ii simple expresia:


Metode numerice n ingineria electric- LUCRARI DE LABORATOR

Pasul1: scriem vectorul polinomului de la numerator


>>A=[1 1];
Pasul 2. Scriem vectorul linie ce con!ine coeficien!ii polinomului de la
numitorul
frac!iei
>>B=[1 -7 15 -9]
>>[r,p,k]=residue(B,A)
r=
-0.5000
2.0000
0.5000

p=
3.0000
3.0000
1.0000

k=
[]

Deci:

8. Colectati coficientii expresiei

>> syms x y
>> collect(x*y+x^2*y^3+x^3*y+y-y^2)
>>

9. Expandati expresia:

>>syms x
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>E=(x^2*sqrt(2)-
x*sqrt(3)+sqrt(5))*(x^2*sqrt(2)+x*sqrt(3)+sqrt(5))-
(x^2*sqrt(2)+sqrt(5))^2
>>expand(E)

Fie p1xx a , p xx2 bx c

10.

>> syms x x1 x2 x3 a b c
>> p1=x+a;
>>p2=x^2+b*x+c
>>A[1 subs(p1,x,x1) subs(p2,x,x1); 1 subs(p1,x,x2) subs(p2, x, x2);
1 subs(p1, x, x3) subs(p2, x ,x3)]
>>factor(det(A))
>>

11. Rezolvati ecuatia in raport cu


variabila x

>> syms x m
>> x=solve(x^2-2*(m+2)*x+m^2-1,x)
>>
12. Rezolvati sistemul de ecuatii urmator n raport cu x, y, z :

>> syms x y z m
>> [x, y, z]=solve(3*x+4*y+m*z,4*x+m*y+3*z-6,m*x+3*y+4*z-
3-m,x,y,z)
>>

13. Determinati matricea A astfel nct:


Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>> syms a b c
>> A[a b c]
>> //Calculam X=toata ecuatia intr-un membru
>>X=transpose(2*A-3* [1 2 0])-3*transpose(A)+transpose[2 1 -1]
>> //determinam a, b, c astfel incat x=[0;0;0]
>>[a, b, c]=solve(X(1), X(2), X(3))
>>

Tema

1. Se considera matricea . Calculati:

>> syms a b c d
>> X=[a b; c d]
>>s=X^2-2*a*X+(a^2+b^2)*ones(2)
>>simplify(s)
>>

2. Fie matricele patrate

Calculati
>> syms l
>> A=[l 0 0; 0 l 0; 0 0 l]
>> B=[0 1 0; 0 0 1; 0 0 0]
>>D=A+B
>>D^100
>>

3. Simplificati expresiile:

a)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>> syms x
>> simplify((x^3-3*x^2+2*x)/(x^2-2*x))
>>

b)
>>syms x
>> simplify((x^2/(x+2)-x^3/(x^2+4*x+4))/(x/(x+2)-x^2/(x^2-
4)))
>>

c)

>> syms x
>> G=(x^2+x*sin(pi/4)-3)/(x*sin(pi/4)-1)
>>simplify(G)
>>

4. Calculati suma

>> syms k n
>> simplify(simsum((3*k-2)^3,k,3,n))
>>

5. Se dau polinoamele

>> syms x
>> p=[1 -1 -3 1 0 -4 -3]
>>q=[2 0 -6 -8 -6]
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>[r,t,k]=residue(p,q)
>>

6. Descompuneti n fractii simple expresia

a)
>>a=[1]
>>b=[1 0 0 0 1 1]
>>[r,t,k]=residue(a,b)
>>

b)

>>a=[2 -3 1]
>>b=[1 2 -9 -18]
>> [r, t, k]=residue(a,b)
>>

c)
>> a=[1 -3 -3 0 10]
>> ec=(x-3)*(x+1)^2
>>..

7. Expandati expresia:

a)
>> syms x
>>E=x*(x-2)^2*(x-3)^3
>>expand(E)
>>

b)
>> syms p q
>> E=(p+q)^3-3*(p+q)^2*(p-q)+3*(p+q)(p-q)^2-(p-q)^3
>> expand(E)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>

8. Factorizati expresia:

a)
>>syms x y z
>>E=x^3+y^3+z^3+3*(x+y)*(x+z)*(y+z);
>>factor(E)
>>

b)
>>syms m
>>F=(2*m-3)*(m-1)^2-4*(2*m-3)
>>factor(F)
>>
9. Sa se scrie sub forma unui singur polinom produsul a doua
polinoame:

a)
>> syms x
>> p=x^3+x^2-1
>> q=x^2-x+1
>> c=p*q
>>coeffs(c)
>>

b)
>>syms x
>>r=(x^2-sqrt(2*sqrt(2))*x+sqrt(2))*(x^2+
sqrt(2*sqrt(2))*x+sqrt(2))
>>coeffs(r)
>>
10. Sa se calculeze determinantul

scriind rezultatul sub forma de produs.


>> syms a b c
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>> A=[a^2 (a+1)^2 (a+2)^2; b^2 (b+1)^2 (b+2)^2; c^2 (c+1)^2


(c+2)^2];
>>factor(det(A))
>>
11. Sa se calculeze determinantul Vandermonde de ordinul patru:

>> syms x1 x2 x3 x4
>> V=[1 1 1 1; x1 x2 x3 x4; x1^2 x2^2 x3^2 x4^2]
>>det(V)
>>
12. nlocuiti variabila simbolica b din expresia

cu valoarea 4 .
>>syms a b
>>e=2*a^2+8*b^3*a-3*(b-4);
>>subs(e,b,4)
>>
13. Se considera expresia

>> syms x m n
>> E=@(x) m*x+n
>>E(x-1)+2*E(x+2)-3*E(x+1)
>>

14. Fiind dat polinomul


Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>syms x, x1, x2, x3, x4


>>p=x^4+x^3+x^2+x+1
>>[x1,x2,x4,x4]=solve(p)
>>s=1/(x1-2)+1/(x2-2)+1/(x3-2)=1/(x4-2)
15. Rezolvati ecuatia:

a)
>>syms x m
>>e=3*x^3-2*m*x+1-m;
>>solve(e,x)
>>

b)
>>syms x a
>> e= (2^x+a*3^x)/(2^x-a*3^x)-2
>>solve(e,x)
>>

16. Rezolvati sistemul de ecuatii urmator n raport cu x, y, z :

>>syms x y z a
>>solve(a*x+y*z-1,x+a*y+z-a,x+y+a*z-a^2,x,y,z)
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

17. Determinati a,b si c astfel nct sistemul

>>syms x y z a b c
>>solve(x+a*y+c*z,b*x+c*y-3*z-1,a*x+2*y+b*z-5,a,b,c)
>>x=3
>>y=-1
>>z=2
>>a
>>b
>>c
>>
18. Determinati matricea A astfel nct:

>> syms a b c d e f
>>A[a bc ;d e f]
>>X=transpose(A+3*[1 -1 0; 1 2 4])-[2 1 ; 0 5 ; 3 8]
>>A=solve(X)
>>

Calcul simbolic n Matlab 7.0 cu aplica!ii n Analiza


matematica

Aplicatii

1. Calculati urmatoarele limite:

a)
>> syms x
>> limit(exp(1/x),x,0,'left')
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

b)
>> limit(exp(1/x),x,0,'right')
>>

c)
>> syms k
>>u=symsum(sin(k),k,1,n)
>>limit(1/(n+n^2),n,inf)*u
>>

d)
>>limit(n^(1/((2*n)!/(n!)^2)),n,inf)
>>
2. Sa se determine raza de convergenta pentru urmatoarea serie de
puteri:

a)
>>syms n
>>limit(rats(2^(1/(n^(log(n))^2))),n,inf)
>>

b)
>>syms n
>>1/limit(rats(n^1/((-1)^n*(n+1)/(n^2+n+1))),n,inf)
>>
3. Calculati:

>>syms n k
>>s=(k^2+3*k+1)/(k^2+3*k+2)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>simplify(n-symsun(s,k,1,n))
>>

4. Calculati suma seriei:

a)
>>syms k n
>>s=simple(symsum(log(1+1/k),k,1,n))
>>

b)
>>syms k n
>>simplify(symsum((2*k+1)/k^2*(k+1)^2),k,1,n))
>>

c)
>> syms k n
>>symsum((k^2+k-1)/((k+1)!),k,1,n)
>>

5. Sa se calculeze urmatoarele derivate:

a)
>> diff(cos(sqrt(x))^2)
>>
sau
>> f=@(x) cos(sqrt(x))^2;
>> diff(f(x))

b)
>>syms x
>>f=@(x) x*atan(x)-log(1+x^2)
>>diff(diff(f(x)))
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

c)
>>syms x
>>f=@(x) 1/(x^3+6*x^2+11*x+6)
>>diff(f(x),11)
>>
6. Dezvoltati n serie Taylor functia

>>syms x
>> taylor(exp(-x^2)/2,4,0.5);

7. Scrieti primii sapte termeni din dezvoltarea n serie de puteri a

functiei
>>syms x
>> taylor(1/2*log((1+x)/(1-x)),7)
>>
8. Sa se calculeze derivatele partiale de ordinul nti si al doilea
pentru functia

>> syms x y z
>> f=y^(x^z);
>> //calculam derivatele partiale de ordinul I ale lui f
>>s=diff(f,x)
>>t=diff(f,y)
>>u=diff(f,z)
>>//calculam derivatele de ordinul II ale lui f
>>simplify(diff(s,x))
>>simplify(diff(t,y))
>>simplify(diff(u,z))
>>simplify(diff(s,y))
>>simplify(diff(s,z))
>>simplify(diff(t,z))
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

9.

a)
>> syms x y z
>> P=sin(x);
>> Q=y*exp(y^2);
>> R=cos(2*z);
>> div=diff(P,x)+diff(Q,y)+diff(R,z)
>>

b)
>> r1=diff(R,y)-diff(Q,z);
>> r2=diff(P,z)-diff(R,x);
>> r3=diff(Q,x)-diff(P,y);
>> rot=[r1 r2 r3]
>>

10. Sa se calculeze gradientul urmatorului cmp scalar:

Se calculeaza dupa formula

>> syms x y z
>> f=x^4+x*y^2+y^3+x^2*z+1;
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>v=[x y z];
>> jacobian(f,v)

11. Fie

Calculati determinantul func!ional (jacobianul) al func!iilor f1,


f2 , adica

>> syms rho th a b


>> x=a*rho*cos(th);
>> y=b*rho*sin(th);
>> F=[x y];
>> v=[rho th];
>> J=jacobian(F,v)
>> simplify(det(J))

12.

Calculati determinantul func!ional (jacobianul) al functiilor f1,

f2 , f3 , adica
>> syms rho th phi
>> F=[rho*sin(th)*cos(phi) rho*sin(th)*sin(phi) rho*cos(th)];
>> v=[rho th phi];
>> J=jacobian(F,v);
>> simplify(det(J))
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

13.

Calcula!i determinantul func!ional (jacobianul) al func!iilor f1,

f2 , f3 , adica
>> syms ro fi z
>>F=[ro*cos(fi) ro*sin(fi) z]
>>v=[ro fi z]
>>J=jacobian(F,v)
>>simplify(det(J))

14. Sa se determine matricea Jacobiana

>> syms x y z
>> u=[x y z];
>>F=[(x+y+z)^2 2*x+y-2*z 3*x^2+2*x*y-12*x*x-18*z*y]
>> J=jacobian(F,u)
>>v=[-1 0 -1]
>>subs(J,u,v)
>>

15. Calculati

a)
>> syms x
>> a=simplify(int(x^(-4)*(1-x^2)^(3/2)))
>>

b)
>>syms x
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>int(1/x^2*sin(1/x)*exp(1/x))
>>

c)

>>syms x
>>int(x^2/(x*cos(x)-sin(x))^2)
>>

d)
>>syms x
>>int(sqrt((x^2-x+1)/(x^2+x+1))*(1-1/x^2))
>>

e)
>>syms x
>>int(rats(3^(1/(1+rats(4^(1/x)))))/sqrt(x))
>>

Tema

1. Calculati:

a)
>>limit(abs(x)/x,x,0,left)
>>

b)
>>limit(abs(x)/x,x,0,right)
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

c)
>>limit(x*exp(-(1/x))/tan(x)^2,x,0,left)
>>

d)
>>limit(((n+1)!)^(1/(n+1))-(n!)^(1/n),n,inf)
>>

e)
>>limit((sin(x)*(cos(x)^(1/3))-cos(x)*(sin(x)^(1/3)))/(log(tan(x)-
cos(2*x))),x,pi/4)
>>
2. Calcula!i suma seriei:

a)
>>syms k
>>symsum(k^2*(3^k-2^k)/6^k,k,1,inf)
>>

b)
>>symsum(2*n+3/n*(n+1)*(n+2),n,1,inf)
>>

c)
>>symsum(log(1+2/n*(n+3)),n,1,inf)
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

3. Sa se determine raza de convergen!a pentru urmatoarele serii de


puteri

a)
>>1/limit((1/(2^n+3^n))^(1/n),n,inf)
>>

b)
>>1/limit(abs(((1+1/n)^(n^2+n))^(1/n)),n,inf)
>>

4. Dezvoltati n serie Taylor functia n jurul lui x 2 ,


pentru n 4
>>syms x
>>f=@(x) sqrt(1+x^2)
>>taylor(f,2,4)
>>
5. Scrieti primii opt termeni din dezvoltarea n serie de puteri a functiei

>>syms x
>>f=@(x)=cos(x)^3
>>taylor(f,8)
>>
6. Sa se calculeze urmatoarea derivata:

a)
>>syms x
>>f=@(x) asin(2*x/(1+x^2))
>>diff(f)
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

b)
>>syms x
>>g=acos(x)/sqrt(1-x^2)
>>diff(diff(g))
>>

7. Sa se calculeze derivatele par!iale de ordinul nti si al doilea pentru


func!ia

a)
>>syms x y
>>f=@(x,y) atan((x+y)/(1-x*y))
>>f1x=diff(f,x)
>>f1y=diff(f,y)
>>f2x=diff(f1x,x)
>>f2y=diff(f1y,y)
>>f2xy=diff(f1x,y)

b)
>> syms x y
>>f=@(x,y) x^2*sin(y)^2
>>f1x=diff(f,x)
>>f1y=diff(f,y)
>>f2x=diff(f1x,x)
>>f2y=diff(f1y,y)
>>f2xy=diff(f1x,y)
8. Sa se calculeze gradientul urmatoarelor cmpuri scalare:

a)
>>syms x y z
>>f=x*y*z*exp(x^2+y^2+z^2)
>>v=[x y z]
>> jacobian(f,v)
//grad=val1*i+val2*j+val3*k
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

b)
>>syms x y z
>>v=[x y z]
>>f=log(sqrt(x^2+y^2+z^2))
>>jacobian(f,v)
>>

c)
>>syms x y z
>>v=[x y z]
>>f=atan((x+y+z-x*y*z)/(1-x*y-y*z-x*z))
>>jacobian(f,v)
>>
9. Se da cmpul vectorial

. Sa se determine
divergenta si rotorul lui v
>>syms x y z
>>p=3*x^2+2*x
>>q=-(z-3*y^2)
>>r=y+2*z
>>div=diff(p,x)+diff(q,y)+diff(r,z)
>>r1=diff(r,y)-diff(q,z)//3cu2 2cu3
>>r2=diff(p,z)-diff(r,x)//1cu3 3cu1
>>r3=diff(q,x)-diff(p,y)//2cu1 1cu2
>>r=[r1 r2 r3]
>>
10.

Calculati determinantul functional (jacobianul) al functiilor f1, f2 ,

adica
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>> syms ro th
>>f=[ ro*cos(th) ro*sin(th)]
>>v=[ro th]
>>J=jacobian(f,v)
>>simplify(det(J))
>>

11.

Calculati determinantul functional (jacobianul) al functiilor f1, f2 ,

adica
>> syms ro th a b
>>f=[a+ro*cos(th) b+ro*sin(th)]
>>v=[rot h]
>>J=jacobian(f,v)
>>simplify(det(J))
>>

12. Calculati:

a)
>>syms x
>>int(1/((1+x^(-4))^(1/4))^3)
>>

b)
>>syms x
>>int((1+sin(x))/(1+cos(x))*exp(x))
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

c)
>>syms x
>>int(log(1+tan(x)))
>>

d)
>>syms x
>>int((4*x^2-7*x+25)/(x^3-6*x^2+3*x+10))
>>

e)
>>syms x
>>int((x+(x+1)^(1/4))/sqrt(x+1))
>>

Calcul numeric n Matlab 7.0 cu aplicaii n Algebr

Aplicatii

1. Verificai dac numerele 87 i 41 sunt prime ntre ele


>> gcd(87,41)
>>
!Daca e unu sunt prime intre ele
2. Aflai cel mai mic multiplu comun al numerelor : 40, 36, 126.
>> lcm(lcm(40,36),126)
>>
3. Determinai rdcinile polinomului

a)
>> p=[1 1 -10 -34 -26];
>> x=roots(p)
>>

b)
>> p=[1 0 0 0 5 1];
>> x=roots(p)
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

4. Rezolvai ecuaiile neliniare:


a)
>> f=@ (x) 1+x-atan(x);
>> x=fzero(f,[-3 3])
b)
>> f=@(x) x^2-cos(pi*x)
>>x=fsolve(f,[-0.5,0.5])
>>
5. Un rezervor poate fi umplut cu ap de la un robinet de ap cald
i de la un
robinet cu ap rece. Dac robinetul de ap cald este deschis 3 min
i de ap rece 1 min, atunci n rezervor sunt l 50 . Dac apa cald
curge 1 min i apa rece 3 min, atunci n rezervor vor fi l 40 . Ci litri
de ap curg ntr-un minut din fiecare robinet? Notnd cu x min l
debitul robinetului de ap cald i cu y min l debitul
robinetului de ap rece rezult sistemul

>> A=[3 1;1 2];


>> b=[50 40]';
>> s=linsolve(A,b);
6. Gsii curenii din circuitul urmtor.
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>[i1 i2 i3 i4 i5 i6] = solve ('i1=i2+i3', 'i6=i1+i5', 'i2+i4=i6',


'i3+i5=i4', '10+5=20*i1', '-5+20=10*i3+5*i4', '-10=-5*i5-5*i4')
>>
7. Rezolvai sistemele neliniare:
a)

>>f=@(x) [x(1)^3+x(2)^3-6*x(1)+3; x(1)^3-x(2)^3-


6*x(2)+2];
>> s = fsolve(f,[0.5 0.5])
>>f(s)
b)

>> f=@(x) [x^2+y^2+z^2-9; x*y*z-1; x+y-z^2]


>>s=fsolve(f,[2.5 0.2 1.6])
>>f(s)

8. Determinati vectorii si valorile proprii ai matricei

>> A=[1 0 0; 1 2 -3; 1 -1 0];


>> [V,D]=eig(A);
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

9. Folosind factorizarea LU s se rezolve sistemul de ecuaii liniare


urmtor:

>> A=[8 -1 -2 0;0 10 1 2;-1 0 6 2;3 -1 2 12];


>> B=[2.3 -0.5 -1.2 3.7]';
>> [L,U]=lu(A);
>> L*U
>> Y=inv(L)*B;
>> X=inv(U)*Y
>> A*X
10. Rezolvai sistemul de ecuaii liniare urmtor folosind metoda
Cholesky:

>> A=[10 1 -1 -1;1 9 1 1;-1 1 11 1;-1 1 1 8];


>> B=[9 8 12 -7]';
>> R=chol(A);
>> R'*R //verificam
>> Y=inv(R')*B;
>> X=inv(R)*Y;//solutie
>> A*X //verificam ca vectorul x este solutie a sistemului

Tema

1. Determinai rdcinile polinomului

a)
>>p=[1 -2 0 -1 2]
>>x=roots(p)
>>

b)
>>p=[1 -2 3 -4 5 -6 7 -8]
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>x=roots(p)
>>

2. Rezolvai ecuaiile neliniare

a)
>> f=@(x) x*exp(x)-1
>>x=fsolve(f,[-0.7,0.7])
>>

b)
>>f=@(x) x-0.2-log(1+x)
>>x=fsolve(f,[-0.6,0.6])
>>

3. S se afle matricea necunoscut X din ecuaia matriceal

>>A=[1 1 -1 ; 2 1 0 ; 1 -1 1]
>>B=[1 -1 3; 4 3 2; 1 -2 5]
>>R=chol(A)
//verificam
>>R*R
>>Y=inv(R)*B
>>X=inv(R)*Y
//verificam daca e solutie
>>X*A
4. Rezolvai sistemele neliniare:

a)
>>f=@(x)[x-sin(x+y); y-cos(x-y)]
>>s=fsolve(f,[0 1])
>>f(s)
>>
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

b)
>> f=@(x) [y^3-20*x-1;x^3+x*y-10*y+10]
>>s=fsolve(f,[0.5 0.3])
>>f(s)

c)

>> f=@(x1) [x1+3*log(x1)-x2^2;2*x1^2-x1*x2-5*x1+1]


>>s=fsolve(f,[3 2])
>>f(s)

d)
>>f=@(x)[x^2+y^2+z^2;2*x^2+y^2-4*z;3*x^2-4*y+z^2]
>>s=fsolve(f,[0.5 0.5 0.5]
>>f(s)

5. Folosind factorizarea LU s se rezolve sistemul de ecuaii liniare


urmtor

>> A=[5 -1 -1; 1 6 1; 1 -1 7]


>>B=[5 -4 9]
>>[L, U]=lu(A)
>>L*U
>>Y=inv(L)*B
>>X=inv(U)*Y
//verificare
>>X*A
6. Determinai vectorii i valorile proprii corespunztori matricei
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>> A=[1 0 0 0 ; 0 0 1 0 ; 0 1 0 0 ; 0 0 0 1];


>> [V,D]=eig(A);

7. Determinai cele mai mari trei valori proprii (in modul) i vectorii
proprii coresponztori acestora, ai matricei

>> A=[3 4 -1.6 0 1 ; 0 -1 0.5 6 0 ; 0 0 -7.6 5 8 ; 6 4 3 20 -1; 8 0 -0.6


3 0]
>>[V,D]=eigs(A,3)
>>

8. Determinati vectorii si valorile proprii ai matricei

>> A=[3 2 2 ; 2 2 1 ; -6 -5 -4]


>> [V, D]=eig(A)
>>

Calcul numeric n Matlab 7.0 cu aplicaii n Analiz


Matematic

Aplicatii

1. Calculai derivatele de mai jos, n punctele indicate


Metode numerice n ingineria electric- LUCRARI DE LABORATOR

A)
>> syms x
>> f=diff(asin(2*sqrt(x)/(1+x)),2)
>> subs(f,x,5.7)

B)
>> syms x
>>f=diff(2^(x^2-2*x),3)
>>subs(f,x,-0.2)
2. Calculai derivatele pariale de ordinul al doilea ale funciei
urmtoare n punctul indicat:

>>syms x y
>> s=diff(2*x^3*y-exp(x^2),x)
>> ss=subs(subs(s,x,-1),y,1)
>> t=diff(2*x^3*y-exp(x^2),y)
>> tt=subs(subs(t,x,-1),y,1)
>> k=diff(s,x)
>> k1=subs(subs(k,x,-1),y,1)
>> p=diff(t,y)
>> p1=subs(subs(p,x,-1),y,1)
>> j=diff(s,y)
>> j1=subs(subs(j,x,-1),y,1)

3. Fie cmpul scalar

>> M=[1 1 1];


>> N=[2 3 -2];
>> s=N-M
>> w=norm(s);
>>u=s/w
>> syms x y z
>> phi=asin(z/sqrt(x^2+y^2));
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>> d1=diff(phi,x);
>> g=subs(subs(subs(d1,x,1),y,1),z,1);
>> d2=diff(phi,y);
>> h=subs(subs(subs(d2,x,1),y,1),z,1);
>> d3=diff(phi,z);
>> k=subs(subs(subs(d3,x,1),y,1),z,1)
>> d=dot(u,[g h k])

4. Calculai urmtoarele integrale simple:

a)
>> syms x
>> f=@(x) sin(2*x)/(1+sin(x)^2);
>> int(f(x),0,pi/2)

b)
>> syms x
>>f=@(x) x^2*sqrt(x^2+1)
>>int(f(x),0,1)
>>

5. Calculai valoarea urmtoarelor integrale improprii

a)
>>syms x
>>int(1/(x+1)^(2/3),-1,1)
>>

b)

>>syms x
>>int(1/sqrt(x*(1-x)),0,1)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>

c)
>>syms x
>>int(1/(1+x^2),-inf,inf)
>>
6. Calculai lungimea arcului de curb

a)

Se foloseste formula
>> simplify(int(sqrt(1+diff(log(sin(x)))^2),pi/3,pi/2))

b)

Se foloseste formula
>> syms t
>> x=diff(3*cos(t));
>> y=diff(3*sin(t));
>> z=diff(4*t);
>> L=int(sqrt(x^2+y^2+z^2),0,pi/2);

c)

Se foloseste formula
>> syms t
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>> ro=sin(t/3)^3;
>> L=eval(int(sqrt(ro^2+diff(ro)^2),0,pi/2))
>>

7. Calculai aria marginit de curbele


>>syms x
>> f=@(x) log(x);
>> g=@(x) log(x)^2;
>> syms y
>> u=solve(log(y)-log(y)^2,y)
>> A=eval(int(f(y)-g(y),y,u(1),u(2)))

8. Se consider domeniul plan

S se determine
coordonatele centrului de greutate al unei plci omogene ce are
forma lui F . Coordonatele centrului de greutate al
unei plci omogene de forma unui domeniu plan

se determina conform
formulelor:

>> syms x
>> I1=int(x*sin(x),0,pi);
>> I2=int(sin(x),0,pi);
>> I3=int(sin(x)^2,0,pi)/2;
>> xg=I1/I2
>> yg=I3/I2
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

9. Calculai urmtoarele integrale duble

a)
>> syms x y
>> f=@(x,y) cos(y)./(1+sin(x)*sin(y))
>> dblquad(f,0,pi/2,0,pi/2)

b)
>> syms x y
>> f=@(x,y) sqrt(x./(y.^3));
>> dblquad(f,1,2,1,2)

Tema

1. Calculai derivatele de mai jos, n punctele indicate

a)
>>syms x
>>f=@(x) atan((x+1)/(x-1))
>>der=diff(f)
>>x=3
>>der=

b)
>>syms x
>>f=diff(abs()x)*sqrt(x/(x-1),4)
>>subs(f,x,2)

2. Calculai derivatele pariale de ordinul al doilea ale funciilor


urmtoare n punctele indicate

a)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>subs x y
>>f=@(x,y) (x^2*y)^(1/3)
>>s=diff(f,x);
>>subs(subs(s,x,-2),y,2)
>>t=diff(f,y)
>>subs(subs(t,x,-2),y,2)
>>s2=diff(s,x)
>>subs(subs(s2,x,-2),y,2)
>>t2=diff(t,y)
>>subs(subs(t2,x,-2),y,2)
>>q=diff(s,y)
>>subs(subs(s,x,-2),y,2)

b)
>>subs x y
>>f=@(x,y) x*sin(x+y)
>>s=diff(f,x);
>>subs(subs(s,x,pi/4),y,0)
>>t=diff(f,y)
>>subs(subs(t,x, pi/4),y,0)
>>s2=diff(s,x)
>>subs(subs(s2,x, pi/4),y,0)
>>t2=diff(t,y)
>>subs(subs(t2,x, pi/4),y,0)
>>q=diff(s,y)
>>subs(subs(s,x, pi/4),y,0)

c)

>>syms x y z
>>f=@(x,y,z) x*exp(y*z)
>>s=diff(f,x)
>> subs(subs(subs(s,x,1),y,1),z,1)
>>t=diff(f, y)
>> subs(subs(subs(t,x,1),y,1),z,1)
>>v=diff(f,z)
>> subs(subs(subs(v,x,1),y,1),z,1)
>>s2=diff(s,x)
>> subs(subs(subs(s2,x,1),y,1),z,1)
>>t2=diff(t, y)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>> subs(subs(subs(t2,x,1),y,1),z,1)
>>v2=diff(v,z)
>> subs(subs(subs(v2,x,1),y,1),z,1)
>>v12=diff(s,y)
>> subs(subs(subs(v12,x,1),y,1),z,1)
>>v13=diff(s,z)
>> subs(subs(subs(v13,x,1),y,1),z,1)
>>v23=diff(t,z)
>> subs(subs(subs(v23,x,1),y,1),z,1)

3. Fie cmpul scalar

>> syms x y
>> f= x^2-y^2+x*y
>>u=pi/6
>>d1=diff(f,x)
>>r1=subs(subs(d1,x,2),y,2)
>>d2=diff(f,y)
>>r2=subs(subs(d2,x,2),y,2)
>>d=dot(u,[r1 r2])

4. Se d cmpul vectorial

>>P=x*z^3
>>Q=-2*x^2*z
>>R=2*y*z^4
>> div=diff(P,x)+diff(Q,y)+diff(R,z)
>>subs(subs(subs(div,x,1),y,-1),z,1)
>> r1=diff(R,y)-diff(Q,z);
>> r2=diff(P,z)-diff(R,x);
>> r3=diff(Q,x)-diff(P,y);
>> rot=[r1 r2 r3]
>>r1=subs(subs(subs(r1,x,1),y,-1),z,1)
>>r2=subs(subs(subs(r2,x,1),y,-1),z,1)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>r3=subs(subs(subs(r3,x,1),y,-1),z,1)
>>rot=

5. Calculai urmtoarele integrale simple:

a)

>>int(exp(x)*cos(x)^2,0,1)

b)
>>int((sqrt(x^2+2))/(x+1),1,5)

6. Calculai valoarea urmtoarelor integrale improprii

a)
>>int(1/sqrt(1-x^2),0,1)

b)
>>int(1/sqrt(x)*(x+1),3,inf)

7. Calculai urmtoarele integrale duble:

a)
>>syms x y
>>f=@(x,y)y*sin(x)^2*x
>>dblquad(f,0,pi,0,pi)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

b)
>>syms x y
>>f=@(x,y) x*y/sqrt(1+x^2+y^2)^3
>>dblquad(f,0,1,1,3)

Rezolvarea ecuatiilor diferentiale n Matlab 7.0

Aplicatii

1. Rezolvai ecuaia diferenial cu variabile separabile

a)
>> y=dsolve('Dy=exp(x)/(2*y*(exp(x)+1))','x')

b)
>> y=dsolve('Dy=y*(x^3+1)/x*(1-y^2)','x')

2. S se rezolve ecuaia diferenial omogen:

a)
>> y=dsolve('Dy=y/x+exp(y/x)','x')
b)

>> y=dsolve('Dy=-(y-x)/(y+x)','x')

3. S se rezolve ecuaia diferenial neomogen

a)
>> y=dsolve('Dy=2*x*y+2*x*exp(x^2)','x')

b)
>> y=dsolve('x*Dy-y=x^2*cos(x)','x')
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

4. S se integreze ecuaiile difereniale totale:

a)
//pasul 1: verificam daca e ecuatie diferentiala totala
>> syms x y t y0 x0 C
>>f=y*exp(x*y)-4*x*y;
>> g=x*exp(x*y)-2*x^2;
>> d1=diff(f,y);
>> d2=diff(g,x);
>> d1==d2
//daca raspunsul este 1 se aplica formula :

>> phi=int(subs(subs(f,x,t),y,y0),t,x0,x)+int(subs(g,y,t),t,y0,y)-C

b)

//pasul 1: verificam daca e ecuatie diferentiala totala


>> syms x y t y0 x0
>> f=y*(1+x*y);
>> g=-x;
>> d1=diff(f,y);
>> d2=diff(g,x);
>> d1==d2
//daca raspunsul nu e 1, se aplica formula

>> phi=simple((diff(f,y)-diff(g,x))/(-f))
>> miu=exp(int(phi,y))

//
>>Phi=int(subs(subs(f*miu,x,t),y,y0),t,x0,x)
+int(subs(g*miu,y,t),t,y0,y)-C
>> Phi=simple(Phi);
>> Phi
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

5. S se rezolve ecuaia diferenial de tip Bernoulli

a)
>> y=dsolve('Dy-4*y/x-x*sqrt(y)','x')

b)
>> y=dsolve('Dy=y/x-2*x*y^2','x')

c)
>> y=dsolve('2*x^2*Dy-4*x*y=y^2','y(1)=1',x)

6. S se integreze ecuaia de tip Riccati

a)
>> y=dsolve('x*Dy=y^2-(2*x+1)*y+x^2+2*x','x')

b)
>> y=dsolve('2*Dy+y^2+1/(x^2)=0','x')

c)
>> y=dsolve('2*(x-x^2*sqrt(x))*Dy+2*sqrt(x)*y^2-y-x=0','x')

7. S se determine soluia general a urmtoarelor ecuaii


difereniale omogene cu coeficieni constani:

a)
>> y=dsolve('D2y=y','x')

b)
>> y=dsolve('D4y+5*D2y+4*y=0','x')
8. S se determine soluia general a urmtoarelor ecuaii
difereniale neomogene cu coeficieni constani:

a)
>> y=dsolve('D2y-5*Dy+6*y=6*x^2-10*x+2','x')
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

b)
>> y=dsolve('D2y+Dy-6*y=2*cos(2*x)-10*sin(2*x)','x')

c)
>> y=dsolve('D3y-3*D2y+3*Dy-y=exp(x)*sqrt(x)','x')

d)
>> y=dsolve('D2y=x+sin(x)','x')

e)
>> y=dsolve('D3y=ln(x)','x')

9. S se integereze ecuaiile difereniale Euler urmtoare

a)
>> y=dsolve('x^2*D2y-x*Dy+y=6*x*ln(x)','x')

b)
>> y=dsolve('x*D3y+D2y=1+x','x')

c)
>> y=dsolve('(3*x+2)^2*D2y+7*(3*x+2)*Dy=-63*x+18','x')

d)
>> y=dsolve('D3y*(x-1)-
D2y=0','y(2)=2','Dy(2)=1','D2y(2)=1','x')

Tema

1. Rezolvati ecuatia diferentiala cu variabile separabile:

a)
>>dsolve(1+y^2+x*y*Dy=0,x)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

b)
>>dsolve(Dy=sqrt(-y^2+y+1)/sqrt(-x^2+x+1),x)
2. Sa se integreze ecuatia diferentiala totala:

>> syms x y t y0 x0 C
>>f=x^2-3*y^2;
>> g=2*x*y;
>> d1=diff(f,x);
>> d2=diff(g,y);
>> d1==d2
//daca raspunsul este 1 se aplica formula :

>> phi=int(subs(subs(f,x,t),y,y0),t,x0,x)+int(subs(g,y,t),t,y0,y)-C
//daca raspunsul nu e 1, se aplica formula

>> phi=simple((diff(f,y)-diff(g,x))/(-f))
>> miu=exp(int(phi,y))

//
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>Phi=int(subs(subs(f*miu,x,t),y,y0),t,x0,x)
+int(subs(g*miu,y,t),t,y0,y)-C
>> Phi=simple(Phi);
>> Phi
3. Sa se rezolve ecuatiile diferentiale omogene si reductibile la
omogene:

a)
>>dsolve(Dy=-2*x*y/(x^2+y^2),x)
b)

>>dsolve(Dy=(2*(x+y-1)^2+3*x*(2*x-y+1)/((x+y-1)^2-
3*x*(2*x-y+1)),x)

c)
>>dsolve(x*Dy-y=sqrt(x^2+y^2),x)

4. Sa se rezolve ecuatia diferentiala neomogena:

a)
>>dsolve(Dy+4*x*y = x*exp(-x^2),x)

b)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>dsolve(Dy-y*tan(x)=cos(x),x)

5. Sa se rezolve ecuatia diferentiala de tip Bernoulli:

a)
>>dsolve(Dy-3*x*y=x*y^2,x)

b)
>>dsolve(Dy+y/x=1/x^2*y^2,x)

6. Sa se integreze ecuatia diferentiala de tip Riccati:

a)
>>dsolve(Dy=y^2-x^2+1,x)

b)
>>dsolve(Dy=x/2*y^2-2/x*y-1/2*x^3,x)

7. Sa se determine solutia generala a urmatoarelor ecuatii diferentiale


omogene cu coeficienti constanti:

a)
>>dsolve(D2y+Dy+y=0,x)

b)
>> dsolve(D3y-5*D2y+17*Dy-13*y=0,x)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

c)
>>dsolve(D4y-3*D3y+5*D2y-3*Dy+4*y=0,x)
d)

>>dsolve(D5y-11*D4y+50*D3y-
94*D2y+13*Dy+169*y=0,x)

8. Sa se determine solutia generala a urmatoarelor ecuatii diferentiale


neomogene cu coeficienti constanti:

a)
>>dsolve(D2y+3*Dy+2*y=1/(1+exp(x)),x)
b)

>>dsolve(D2y-6*Dy+6*y=(9*x^2+6*x+2)/x^3*exp(3*x),
x)

c)
>>dsolve(D3y-4*Dy=cos(3*x),x)

d)
>>dsolve(D5y+4*D3y=x^2*exp(x),x)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

e)
>>dsolve(D7y-D3y=12*x,x)

9. Sa se integereze ecuatiile diferentiale Euler urmatoare

a)
>>dsolve(x^2*D2y+x*Dy+x=2*sin(log(x)),x)

b)
>>dsolve(x^3*D3y+3*x^2*D2y+x*Dy-y=x,x)
Rezolvarea sistemelor de ecuatii diferentiale n Matlab
7.0

Aplicatii
1. Sa se rezolve urmatorul sistem de ecuatii diferentiale liniare omogen

a)
>> [y1,y2]=dsolve('Dy1=y2','Dy2=-y1','x')

b)
>> [y1,y2,y3]=dsolve('Dy1=3*y2-4*y3','Dy2=-y3','Dy3=-
2*y1+y2','x')
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

c)
>>[y1,y2,y3]=dsolve('Dy1=y1+y2-3*y3','Dy2=4*y1+y2-
2*y3','Dy3=2*y1+y2-6*y3','y1(0)=2','y2(0)=1','y3(0)=-1','x')
2. Sa se rezolve urmatorul sistem de ecuatii diferentiale liniare
neomogen

a)
>> [y1,y2]=dsolve('Dy1=y2','Dy2=y1+exp(x)+exp(-x)','x')

b)
>> [y1,y2,y3]=dsolve('Dy1=y2+y3-x-x^2','Dy2=3*y1+y3-2-
^2','Dy3=3*y1+y2+x-
3','x')
3. Sa se determine solutia sistemului de ecuatii diferentiale de ordinul
nti
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>> [x,y]=dsolve('Dx-Dy=y-4*x+1','Dx+2*Dy=4*y+2*x+t','x(0)=-
1','y(0)=2','t')

Tema

1. Sa se rezolve urmatorul sistem de ecuatii diferentiale liniare


omogen:

a)
>>[y1, y2
,y3]=dsolve(Dy1=y2+y3,Dy2=y3+y1,Dy3=y1+y2)

b)
>> [y1, y2, y3]=dsolve(Dy1=-2*y1+2*y2+2*y3,Dy2=-
10*y1+6*y2+8*y3, Dy3=3*y1-y2-2*y3)

c)
>>dsolve(Dy/Dx-3*y+8*z-4*u=0,Dz/Dx+y-
5*z+2*u=0,Du/Dx+3*y-14*z+6*u=0)
2. Sa se rezolve urmatorul sistem de ecuatii diferentiale liniare
neomogen

a)
>>dsolve(Dy1=2*y1+y2-2*y3-x+2,Dy2=-
y1+1,Dy3=y1+y2-y3+1-x,x)

b)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>[x,y]=dsolve(t*Dx/Dt=y+1/t,t*Dy/Dt=-x+t)

c)
>>[y1,y2,y3]=dsolve(Dy1=y2+y3-exp(x),Dy2=y1+y3-
exp(x),Dy3=y1+y2-exp(x),x)

d)
>>[x,y,z]=dsolve(Dx/Dt=z+y-4*x+1,Dy/Dt=2*y+x-
z+1,Dz/Dt=y+z-2*x+1)

3. Rezolvati problema Cauchy

a)
>>[x,y,z]=dsolve(Dx/Dr=x+y-3*z,Dy/Dt=4*x+y-
2*z,Dz/Dt=2*x+y-6*z,x(0)=2,y(0)=1,z(0)=-1)

b)
>>[y1,y2,y3]=dsolve(Dy1-3*y1+8*y2-
4*y3=1,Dy2+y1-5*y2+2*y3=-1,Dy3+3*y1-
14*y2+6*y3=2,y1(0)=2,y2(0)=3,y3(0)=4)

c)
Metode numerice n ingineria electric- LUCRARI DE LABORATOR

>>[x,y]=dsolve(3*Dx/Dt-
x+2*y=t+1,3*Dy/Dt+4*x+y=2*t+3,x(0)=2,y(0)=3)