Filamentary structures are recognized as a fundamental component of interstellar molecular clouds in observations by the Herschel satellite. These filaments, especially massive filaments, often extend in a direction perpendicular to the interstellar magnetic field. Furthermore, the filaments sometimes have an apparently negative temperature gradient, that is, their temperature decreases towards the center. In this paper, we study the magnetohydrostatic equilibrium state of negative-indexed polytropic gas with the magnetic field running perpendicular to the axis of the filament. The model is controlled by four parameters: center-to-surface density ratio ($rho_c/rho_s$), plasma $beta$ of the surrounding gas, radius of the parent cloud $R_0$ normalized by the scale height, and the polytropic index $N$. The steepness of the temperature gradient is represented by $N$. We found that the envelope of the column density profile becomes shallow when the temperature gradient is large. This reconciles the inconsistency between the observed profiles and those expected from the isothermal models. We compared the maximum line-mass (mass per unit length), above which there is no equilibrium, with that of the isothermal non-magnetized filament. We obtained an empirical formula to express the maximum line-mass of a magnetized polytropic filament as $lambda_{max}simeqleft[{left(lambda_{0,max}(N)/M_odot{rm pc^{-1}}right)^2+left[5.9(1.0+1.2/N)^{1/2}({Phi_{cl}}/{1mu {rm G,pc}})right]^2}right]^{1/2}M_odot {rm pc^{-1}}$, where $lambda_{0,max}(N)$ represents the maximum line-mass of the non-magnetized filament and $Phi_{cl}$ indicates one-half of the magnetic flux threading the filament per unit length. Although the negative-indexed polytrope makes the maximum line-mass decrease compared with that of the isothermal model, a magnetic field threading the filament increases the line-mass.