I have a DM MPI Vec u, I want to scatter it to a sequential Vec w in processor 0. There is a function VecScatterCreateToZero allowing me to do that. However, the global indices get easily messed up if I do this way.
So I have to match the IS for u and w. And I think maybe I can use DMCompositeGetGlobalISs to get the IS, and then call VecScatterCreate(u,is[0],w,is[0],&ctx). But I'm not sure if I'm doing the right thing, and for now it gives me segmentation fault, memory errors on DMCompositeGetGlobalISs. So I need some help on this.
