refactor grb_quad.jl