Re: [petsc-users] Best way to scatter a Seq vector ?

2017-01-06 Thread Manuel Valera
Awesome, that did it, thanks once again. On Fri, Jan 6, 2017 at 1:53 PM, Barry Smith wrote: > >Take the scatter out of the if () since everyone does it and get rid of > the VecView(). > >Does this work? If not where is it hanging? > > > > On Jan 6, 2017, at 3:29 PM, Manuel Valera wrote

Re: [petsc-users] Best way to scatter a Seq vector ?

2017-01-06 Thread Barry Smith
Take the scatter out of the if () since everyone does it and get rid of the VecView(). Does this work? If not where is it hanging? > On Jan 6, 2017, at 3:29 PM, Manuel Valera wrote: > > Thanks Dave, > > I think is interesting it never gave an error on this, after adding the > vecass

Re: [petsc-users] Best way to scatter a Seq vector ?

2017-01-06 Thread Manuel Valera
Thanks Dave, I think is interesting it never gave an error on this, after adding the vecassembly calls it still shows the same behavior, without complaining, i did: if(rankl==0)then call VecSetValues(bp0,nbdp,ind,Rhs,INSERT_VALUES,ierr) call VecAssemblyBegin(bp0,ierr) ; call VecAssem

Re: [petsc-users] Best way to scatter a Seq vector ?

2017-01-06 Thread Dave May
On 6 January 2017 at 20:24, Manuel Valera wrote: > Great help Barry, i totally had overlooked that option (it is explicit in > the vecscatterbegin call help page but not in vecscattercreatetozero, as i > read later) > > So i used that and it works partially, it scatters te values assigned in > ro

Re: [petsc-users] Best way to scatter a Seq vector ?

2017-01-06 Thread Manuel Valera
Great help Barry, i totally had overlooked that option (it is explicit in the vecscatterbegin call help page but not in vecscattercreatetozero, as i read later) So i used that and it works partially, it scatters te values assigned in root but not the rest, if i call vecscatterbegin from outside ro

Re: [petsc-users] Best way to scatter a Seq vector ?

2017-01-05 Thread Barry Smith
> On Jan 5, 2017, at 6:21 PM, Manuel Valera wrote: > > Hello Devs is me again, > > I'm trying to distribute a vector to all called processes, the vector would > be originally in root as a sequential vector and i would like to scatter it, > what would the best call to do this ? > > I already

[petsc-users] Best way to scatter a Seq vector ?

2017-01-05 Thread Manuel Valera
Hello Devs is me again, I'm trying to distribute a vector to all called processes, the vector would be originally in root as a sequential vector and i would like to scatter it, what would the best call to do this ? I already know how to gather a distributed vector to root with VecScatterCreateToZ