blob: 71888bbc881e0244f5b019e4e1ded9039045b035 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
clear
//
//
//
//Variable declaration
Vrms=200 //voltage(V)
RL=1000 //load resistance(ohm)
//Calculation
Im=Vrms*sqrt(2)/RL //peak current(A)
Idc=2*Im/%pi //average DC current(A)
Vdc=int(Idc*RL) //dc voltage(V)
x=(Vrms/Vdc)**2
gama=sqrt(x-1)*Vdc //ripple factor(V)
//Result
|