[petsc-dev] strangness in Chebyshev estimate of eigenvalues

Jed Brown jed at jedbrown.org
Tue May 17 19:29:29 CDT 2016


That is my suggestion and I think you should use it so it's easier to debug.

On May 17, 2016 5:11:42 PM PDT, Mark Adams <mfadams at lbl.gov> wrote:
>OK, I thought you were suggesting that:
>
>unsigned int hash(unsigned int x) {
>    x = ((x >> 16) ^ x) * 0x45d9f3b;
>    x = ((x >> 16) ^ x) * 0x45d9f3b;
>    x = ((x >> 16) ^ x);
>    return x;}
>
>But, Barry is vetoing this.
>
>On Tue, May 17, 2016 at 4:18 PM, Jed Brown <jed at jedbrown.org> wrote:
>
>> Mark Adams <mfadams at lbl.gov> writes:
>>
>> > Why not just set each index with hash(i) = (i >> 32)^i and forget
>> > VecSetRandom in here?
>>
>> Because if your vertices are numbered lexicographically on a
>Cartesian
>> grid, this gives you a plane.  But just put in the legit hash (the
>one I
>> linked is pretty good) and then you don't have to worry about
>> accidentally stumbling upon pathological cases.
>>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20160517/990f2fac/attachment.html>


More information about the petsc-dev mailing list