grape_functions.py 文件源码

python
阅读 32 收藏 0 点赞 0 评论 0

项目:quantum-optimal-control 作者: SchusterLab 项目源码 文件源码
def get_dressed_info(H0):
    # assign index of the dressed state according to the overall with bare state
    w_c, v_c = la.eig(H0)
    dressed_id=[]
    for ii in range(len(v_c)):
        index = np.argmax(np.abs(v_c[:, ii]))
        if index not in dressed_id:
            dressed_id.append(index)
        else:
            temp = (np.abs(v_c[:, ii])).tolist()
            while index in dressed_id:
                temp[index] = 0
                index = np.argmax(temp)
            dressed_id.append(index)

    return w_c, v_c, dressed_id
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号