The mechanism of decomposition of the butanal and pentanal long chain aldehydes was investigated using the ab initio transition state theory-based master equation approach. The rate constants of the homolytic bond scission reactions of butanal and pentanol leading to the formation of CHO+C3H7, CH2CHO+C2H5, C2H4CHO+CH3, C3H7CO+H, C2H5 (CHCHO)-C-center dot+H and CH2CHO+C3H7, C2H4CHO+C2H5, C3H6CHO+CH3, C4H9CO+H, C3H7 (CHCHO)-C-center dot+H, respectively, as well as of the reverse barrierless recombination channels, were determined using Variable Reaction Coordinate Transition State Theory. The potential energy surfaces were determined at the multireference CASPT2/aug-cc-pVTZ level on omega B97X-D/jun-cc-pVTZ structures, while stochastic samplings were performed at the CASPT2 level using a (4e,4o) active space. Rate laws for the alkyl+R-CHO, H+R- (CHCHO)-C-center dot, and H+R- (CO)-C-center dot classes of reactions were then determined. Rate constants of H-abstraction reactions and of the three body butanal -> CO+H2+C3H6 channel were determined using omega B97X-D/jun-cc-pVTZ structures and Hessians and CCSD(T) energies, extrapolated to the complete basis set. It was found that the calculated homolytic bond scission reactions are faster by a factor of 2-3 with respect to literature previous estimates. The calculated reaction rates were inserted in the CRECK kinetic scheme and used to simulate literature speciation data of butanal and pentanal pyrolysis in shock tubes and ignition delay times, finding that their inclusion into the kinetic scheme enhances the predictive capabilities of the mechanism. The aldehyde decomposition mechanism and the rate constants determined in this study are suitable to be used to interpret and predict the reactivity of aldehydes in a wide range of temperatures and pressures.