def setUp(self):
        itau_data = get_itau_data_from_file()
        self.header_arquivo = itau_data['header_arquivo']
        self.seg_p = itau_data['seg_p1']
        self.seg_p_str = itau_data['seg_p1_str']
        self.seg_q = itau_data['seg_q1']
        self.seg_q_str = itau_data['seg_q1_str']
def phasor(bch, ax=0):
    """create phasor plot from bch"""
    f1 = bch.machine['p']*bch.dqPar['speed']
    w1 = 2*np.pi*f1
    xd = w1*bch.dqPar['ld'][-1]
    xq = w1*bch.dqPar['lq'][-1]
    r1 = bch.machine['r1']
    i1beta_phasor(bch.dqPar['up'][-1],
                  bch.dqPar['i1'][-1], bch.dqPar['beta'][-1],
                  r1, xd, xq, ax)