The perturbative treatment of subdominant oscillation and matter effect in neutrino beams/superbeams, propagating over long baselines and being used to look for CP violation, is studied here for a general matter density function varying with distance. New lowest order analytic expressions are given for different flavour transition and survival probabilities in a general neutrino mixing basis and a variable earth matter density profile. It is demonstrated that the matter effect in the muon neutrino (antineutrino) flavour survival probability vanishes to this order, provided the depletion, observed for atmospheric muon neutrinos and antineutrinos at super-Kamiokande, is strictly maximal. This result is independent of the earth density profile and the distance L between the source and the detector. In the general variable density case we show that one cannot separate the matter induced asymmetry from a genuine CP effect by keeping two detectors at distances L 1 and L 2 from the source while maintaining a fixed ratio L 1 /E 1 = L 2 /E 2 . This needs to be done numerically and we estimate the asymmetry generated by the earth matter effect with particular density profiles and some chosen parameters for very long baseline neutrino oscillation experiments.