Waves and oscillations can provide vital information about the internal
structure of waveguides they propagate in. Here, we analytically investigate
the effects of density and magnetic stratification on linear longitudinal
magnetohydrodynamic (MHD) waves. The focus of this paper is to study the
eigenmodes of these oscillations. It is our specific aim is to understand what
happens to these MHD waves generated in flux tubes with non-constant (e.g.,
expanding or magnetic bottle) cross-sectional area and density variations. The
governing equation of the longitudinal mode is derived and solved analytically
and numerically. In particular, the limit of the thin flux tube approximation
is examined. The general solution describing the slow longitudinal MHD waves in
an expanding magnetic flux tube with constant density is found. Longitudinal
MHD waves in density stratified loops with constant magnetic field are also
analyzed. From analytical solutions, the frequency ratio of the first overtone
and fundamental mode is investigated in stratified waveguides. For small
expansion, a linear dependence between the frequency ratio and the expansion
factor is found. From numerical calculations it was found that the frequency
ratio strongly depends on the density profile chosen and, in general, the
numerical results are in agreement with the analytical results. The relevance
of these results for solar magneto-seismology is discussed.Comment: 10 pages, 5 figures, published in ApJ, uses emulateap