Exemplo n.º 1
0
def gq(N, s=1.0, t=0, shift=0.0, scale=1.0):
    from spyctral.fourier.quad import gq
    from maps import theta_to_x

    [theta, w] = gq(N, s - 1.0, t)
    x = theta_to_x(theta, shift=shift, scale=scale)
    w *= scale

    return [x, w]
Exemplo n.º 2
0
def pgq(N, s=1.0, t=0, shift=0.0, scale=1.0):
    # from fourier.quad import genfourierw_pgquad as gq
    # from spyctral.fourier.quad import genfourier_gquad as gq
    from spyctral.fourier.quad import gq
    from weights import weight as wx
    from maps import theta_to_x

    [theta, w] = gq(N, s - 1.0, t)
    x = theta_to_x(theta, shift=shift, scale=scale)
    w *= scale
    w /= wx(x, s, t, shift=shift, scale=scale)

    return [x, w]