Text this: New Characterizations of Weights in Hardy and Opial Type Inequalities via Solvability of Dynamic Equations