% Prechodne deje realizovane na transformatoru a vedeni

clear
clc

% Zakladni technicke parametry transformatoru
Un1=400
Un2=110
Snt=200
dP0p=0.3
dPfep=dP0p
dPkp=1
dPcup=dPkp
Ukp=10
I0p=1
frekv=50
omega=2*pi*frekv

% Vypocty parametru nahraniho schematu
Znt=Un1^2/Snt

Rk=(dPkp/100)*(Un1^2/Snt)
Rk1=Rk/2
Zk=(Ukp/100)*(Un1^2/Snt)
Xs=sqrt(Zk^2-Rk^2)
Ls=Xs/omega
Ls1=Ls/2

Gfe=(dP0p/100)*(Snt/Un1^2)
Rfe=1/Gfe
Y0=(I0p/100)*(Snt/Un1^2)
Xh=1/sqrt(Y0^2-Gfe^2)
Lh=Xh/omega

% Kontrola pres komplexni vyjadreni impedance Zk a admitance Y0
Zk2=abs(Rk+i*Xs)
Y02=abs(1/Rfe + 1/(i*Xh))
