58 pangkatvmax= vmax * (10**Nilaivmax) pangkatvmin= vmin * (10**Nilaivmin) vswr= pangkatvmax / pangkatvmin frekuensi= (3*(10**8))/pangkatlamda magnitud= (vswr-1)/(vswr+1) teta= math.degrees(math.atan(3.14+((4*3.14/lamda)*lmi n)))+3.8 magnitudrec= magnitud*math.cos(teta) tetarec= magnitud*math.sin(teta) r2= complex(magnitudrec, tetarec) zl= pangkatzo*((1+(r2))/(1-(r2))) self.ui.lineEditf.setText(str(frekuensi)) self.ui.lineEditmagnitud.setText(str(magnitud)) self.ui.lineEditteta.setText(str(teta)+"°") self.ui.lineEditr1.setText(str(magnitud)+"∠"+st r(teta)+"°") self.ui.lineEditr2.setText(str(r2)) self.ui.lineEditzl.setText(str(zl)) if __name__=="__main__": app = QApplication(sys.argv) w = MyForm() w.show() sys.exit(app.exec_()) 5.4.2 Penyelesaian Directional Coupler dengan Pemrograman Calldirectcoupler.py import sys import math from PyQt5.QtWidgets import QDialog, QApplication from Directcoupler import * class MyForm(QDialog): def __init__(self): super().__init__() self.ui = Ui_Dialog() self.ui.setupUi(self)
RkJQdWJsaXNoZXIy MTM3NDc5MQ==