Pankaj(ADS)

Featured post

Python Codes for Electric Potential

Python Codes for Electric Potential Code:- import numpy as np import math import matplotlib.pyplot as plot ''' Calculating Elect...

Saturday, 25 July 2020

Python-(Three Phase Half Wave Rectifier)

0 comments
Python Program
(Half Wave Thyristor Controlled Rectifier)
1.Input any value of Theta ie firing Angle.
for example(taking th =30 degree) 

Python Code:-
import numpy as np
import scipy as sp
import math
import matplotlib.pyplot as plot
'''------------Pankaj Aswal(Owner)------------------
            Three phase half Wave Converter
---------------------------------------------
'''

pi= math.pi
Vm = 220
th = int(input("Input the value of Theta(th) ; "))
print(th)
x = np.arange(0,4*np.pi,0.1)
T_R = np.sin(x - th)
print(T_R)
T_Y = np.sin((x -(th + 120)))
print(T_Y)
T_B = np.sin((x -(th + 240)))
print(T_B)
plot.plot(x,T_R,x,T_Y,x,T_B)
plot.xlabel('x value from 0 to 4pi')
plot.ylabel('Three phase supply')
plot.legend(['sin(0)','sin(120)','sin(240)'])
plot.show()
'''
Average Output Voltage of 'Three phase half Wave Converter"
'''
V_dc = (3*Vm)* (1/2*pi)* np.cos(th)
print(V_dc)
plot.plot(V_dc,'ro--')
plot.xlabel('RMS value of Voltage')
plot.ylabel('V_dc')
plot.legend(['V_dc'])
plot.show()

Output
1.>>> 
======== RESTART: D:/Desktop/Python(TUT)/3-phasehalfWaveConverter.py ========
Input the value of Theta(th) ; 30
30
[ 0.98803162  0.99849503  0.9989818   0.98948708  0.97010573  0.94103141
  0.90255461  0.85505978  0.79902148  0.73499962  0.66363388  0.58563734
  0.5017893   0.41292755  0.31993996  0.22375564  0.12533563  0.0256633
 -0.07426545 -0.17345216 -0.27090579 -0.36565262 -0.45674597 -0.54327567
 -0.62437714 -0.69924003 -0.76711635 -0.8273279  -0.87927306 -0.92243282
 -0.95637593 -0.98076325 -0.9953511  -0.99999374 -0.99464477 -0.97935764
 -0.95428509 -0.91967764 -0.87588108 -0.823333   -0.76255845 -0.69416467
 -0.61883502 -0.53732218 -0.45044059 -0.35905835 -0.26408852 -0.16648
 -0.06720807  0.03273538  0.13235175  0.23064571  0.32663513  0.41936092
  0.50789659  0.59135753  0.66890982  0.73977859  0.80325573  0.858707
  0.90557836  0.94340148  0.97179845  0.99048552  0.99927599  0.99808203
  0.98691556  0.96588815  0.93520992  0.89518737  0.8462204   0.78879829
  0.72349476  0.65096231  0.57192566  0.48717451  0.39755568  0.30396461
  0.20733642  0.1086366   0.00885131 -0.09102242 -0.18998668 -0.28705265
 -0.38125049 -0.471639   -0.55731505 -0.6374226  -0.71116122 -0.77779416
 -0.83665564 -0.88715753 -0.92879523 -0.96115272 -0.98390669 -0.99682979
 -0.9997929  -0.99276641 -0.97582052 -0.94912455 -0.91294525 -0.8676441
 -0.81367374 -0.75157342 -0.68196362 -0.60553987 -0.52306577 -0.43536536
 -0.34331493 -0.24783421 -0.14987721 -0.05042269  0.04953564  0.14899903
  0.24697366  0.34248062  0.43456562  0.52230859  0.60483282  0.68131377
  0.75098725  0.81315711  0.86720218  0.91258245  0.9488445   0.97562601]
[ 0.71487643  0.78111362  0.83954619  0.88959028  0.93074588  0.96260178
  0.98483968  0.99723739  0.99967103  0.99211629  0.97464865  0.94744264
  0.9107701   0.86499745  0.81058202  0.74806753  0.6780786   0.60131453
  0.51854232  0.43058901  0.33833339  0.24269727  0.14463618  0.04512995
 -0.05482721 -0.15423656 -0.25210482 -0.34745414 -0.43933181 -0.52681982
 -0.60904402 -0.68518286 -0.75447557 -0.81622982 -0.86982856 -0.91473627
 -0.95050423 -0.97677507 -0.9932863  -0.99987294 -0.99646917 -0.98310902
 -0.95992597 -0.92715165 -0.88511354 -0.83423167 -0.77501443 -0.70805351
 -0.63401795 -0.55364748 -0.46774516 -0.37716928 -0.28282486 -0.18565453
 -0.08662921  0.01326168  0.11302006  0.21164919  0.30816358  0.40159891
  0.49102159  0.57553815  0.65430412  0.72653251  0.79150161  0.8485623
  0.89714443  0.93676259  0.96702093  0.98761712  0.99834536  0.99909847
  0.98986891  0.97074891  0.94192951  0.90369866  0.85643835  0.80062079
  0.7368037   0.6656247   0.58779501  0.50409226  0.41535278  0.32246324
  0.22635176  0.12797864  0.0283268  -0.07160807 -0.17082746 -0.26833999
 -0.36317137 -0.45437405 -0.54103678 -0.62229364 -0.69733276 -0.76540435
 -0.82582828 -0.87800081 -0.92140064 -0.95559414 -0.98023966 -0.99509095
 -0.99999962 -0.99491662 -0.97989275 -0.95507811 -0.92072065 -0.87716365
 -0.82484232 -0.76427944 -0.69608013 -0.62092582 -0.53956742 -0.45281785
 -0.36154387 -0.26665746 -0.1691067  -0.06986628  0.03007222  0.12971025
  0.22805226  0.32411564  0.41694057  0.50559957  0.58920678  0.66692683]
[ 0.17604595  0.27344066  0.36810325  0.45908787  0.54548544  0.6264327
  0.70112085  0.76880363  0.82880478  0.88052479  0.92344688  0.9571422
  0.98127407  0.99560137  0.99998095  0.99436906  0.97882176  0.95349439
  0.91864002  0.87460691  0.82183501  0.76085161  0.69226603  0.61676356
  0.53509859  0.44808709  0.35659845  0.2615468   0.16388186  0.06457947
 -0.03536818 -0.13496244 -0.2332082  -0.32912382 -0.42175095 -0.51016408
 -0.59347982 -0.67086571 -0.74154852 -0.80482203 -0.86005403 -0.90669264
 -0.94427189 -0.97241628 -0.99084461 -0.99937275 -0.99791549 -0.98648738
 -0.96520262 -0.93427387 -0.89401017 -0.84481381 -0.78717636 -0.72167369
 -0.64896031 -0.56976272 -0.48487226 -0.39513711 -0.30145388 -0.20475862
 -0.10601749 -0.00621706  0.09364549  0.19257236  0.28957511  0.38368453
  0.47396029  0.5595004   0.63945017  0.71301076  0.77944719  0.83809563
  0.8883701   0.92976827  0.96187651  0.98437399  0.99703593  0.99973582
  0.99244668  0.97524134  0.94829171  0.91186706  0.86633134  0.81213952
  0.74983308  0.68003455  0.60344133  0.52081874  0.43299229  0.34083953
  0.24528121  0.14727212  0.04779154 -0.05216656 -0.15160343 -0.24952552
 -0.34495444 -0.43693669 -0.52455321 -0.60692857 -0.6832397  -0.75272413
 -0.81468758 -0.86851095 -0.91365644 -0.94967298 -0.9762007  -0.99297454
 -0.99982691 -0.99668934 -0.98359318 -0.96066929 -0.9281467  -0.88635038
 -0.83569794 -0.77669548 -0.70993253 -0.63607618 -0.55586436 -0.47009853
 -0.37963563 -0.28537953 -0.18827202 -0.08928336  0.0105974   0.11037226]
159.91642318489468
2.Scope


  
 
 

No comments:

Post a Comment