This study presents a modified version of a classical 3-D numerical ray tracing code [originally by Jones and Stephenson (A versatile three-dimensional ray tracing computer program for radio waves in the ionosphere. Office of Telecommunications Report 75-76, US Government Printing Office, Washington, DC, 1975)], now linked to ionosphere, neutral atmosphere, Earth's magnetic field, and traveling ionospheric disturbances (TIDs) models. This method is applied to study the effect of TIDs on radio waves by simulating the waves' propagation in a disturbed ionosphere. A 3-D cubic interpolation method is implemented in the ray tracing code to solve discontinuities and guarantee the ray tracing validity and accuracy under all conditions. Changes of the ground range distance (R) and the bearing angle (σ) are assessed for various simulated ray paths. A Pedersen ray case is also shown, for which small changes of signal frequency lead to enhanced variations. The study of HF ray path variations in terms of various TIDs characteristics and under different background ionospheric conditions and transmitter locations and radiation pattern can contribute to the mitigation of TIDs effects, either helping to improve existing methods or to develop new ones. The 3-D ray tracing code described and implemented in this work may well work for this purpose.