incorrect WENO coefficient in GRHydro WENO reconstruction code

Issue #2647 resolved
Roland Haas created an issue

The GRHydro WENO reconstruction code selected by GRHydro::recon_method = "weno" employs incorrect values for the weno_coeffs array that is constructed from the WENO $omega_r$ values.

The current values are in fact WENO interpolation instead of WENO reconstruction.

Pull request

https://bitbucket.org/einsteintoolkit/einsteinevolve/pull-requests/17/rhaas-wenocoeffsfix

corrects the coefficients, re-computing them from the original publication used to implement the code (“WHAM paper”, https://arxiv.org/abs/0704.2608) and updates the test data as well.

The attached stand-alone test (extracted code from GRHydro) demonstrates the issue and shows that only WENO-Z and WHAM’s WENO do show the WENO property of exactly reconstructing smooth data of low order polynomials (2nd order in the test, but should be up to 5th order). It also shows that WENO as implemented by GRHydro is actually WENO interpolation.

This effectively reduces WENO to a 2nd order accurate scheme similar to a basic tvd scheme I would guess.

Comments (15)

  1. Roland Haas reporter

    @Zach Etienne could I ask you to review this? It would be important to have the corrected WENO coeffs in the next release and this is complicated enough that a second pair of eyes would be very helpful.

  2. Roland Haas reporter

    In case it helps, the “average to left” matrix that one needs is the product of the “average to center” and “center to left” matrices show in the WHAM paper. And in Maple code this would be:

    with(linalg);
    C_cl := matrix([[15/8, -5/4, 3/8], [3/8, 3/4, -1/8], [-1/8, 3/4, 3/8]]);
    C_ac := matrix([[23/24, 1/12, -1/24],[-1/24, 13/12, -1/24],[-1/24, 1/12, 23/24]]);
    C_al := multiply(C_cl, C_ac);
    

    which gives:

           [ 11/6  -7/6   1/3 ]
    C_al = [  1/3   5/6  -1/6 ]
           [ -1/6   5/6   1/3 ]
    

    which is almost what shows up in the code. The matrix is used in the code. Except that the code sorts by a different index (see comment “ these are from equ. (18) and (19) when substituting into each other and sorting by the index i-r+j”).

  3. Roland Haas reporter

    The interpolation vs. reconstruction behaviour should be checked against PPM to decide if WENO or WENOZ coefficients should be updated (one is reconstruction the other one is interpolation).

  4. Roland Haas reporter

    I did some more tests and incorporated GRHydro’s PPM ( Ian Hawke, Toni Font, Luca Baiotti, Frank Loeffler) to my test and find that PPM does reconstruction not interpolation.

    So WENO (which does interpolation) should be changed.

    Attached please find the test code and test output.

  5. Log in to comment