code: def zaffine(c0, c1, c2, d):
      
  
      xx, yy = zmeshgrid(d)
      Hx, Hy = _vector.vector.to_list(xx), _vector.vector.to_list(yy)
  
      Hs = _cp.deepcopy(Hx)
      Hs[0][:, :, 0] = c1 * Hx[0][:, :, 0] + c2 * Hy[0][:, :, 0]
      Hs[-1][1, :, :] = c1 * Hx[-1][1, :, :] + (c0 + c2 * Hy[-1][1, :, :])
  
      d = len(Hs)
      for k in range(1, d - 1):
          Hs[k][1, :, 0] = c1 * Hx[k][1, :, 0] + c2 * Hy[k][1, :, 0]
  
      return _vector.vector.from_list(Hs)
docs: Generate linear function c0 + c1 ex + c2 ey in z ordering with d cores in QTT
      :param c0:
      :param c1:
      :param c2:
      :param d:
      :return: