xhorizon.tortoise.metfunc_tests module

This module provides test routines for verifying that metfunc object properties have been properly calculated.

xhorizon.tortoise.metfunc_tests.func_test(func, saveplots=False)

Runs a series of tests to verify that metfunc object properties have been properly calculated.

xhorizon.tortoise.metfunc_tests.nice_plot_background(func)

Fill the intervals I_j, with blue as trapped and green as untrapped. Separate intervals with vertical grey lines. Plot a horizontal black dotted line at y=0.

xhorizon.tortoise.metfunc_tests.f_test(func, saveout=False)

Plot metfunc.f(r) along with metfunc.rj and metfunc.kj to check that zeroes and slopes are accurate.

xhorizon.tortoise.metfunc_tests.F_test_0(func, saveout=False)

Plot metfunc.F(r) and metfunc.Finv(j,rstar) on top of metfunc.f(r) and metfunc.rj. Check that Finv is truly the inverse of F.

xhorizon.tortoise.metfunc_tests.F_test_1(func, saveout=False)

Plot the reciprocal numerical derivative dF/dr on top of f(r). Check that 1./(dF/dr) = f(r) so that tortoise function is an integral of f(r)^{-1}.

xhorizon.tortoise.metfunc_tests.F_test_2(func, saveout=False)

Plot the continuous version of F(r), with logarithmic infinities subtracted out. Plot the exponential function appearing in the Penrose coordinate metric. Check continuity at ri.