Physical exercise has been proven to be beneficial for both healthy subjects and cardiac patients. It can improve cardiovascular health and promote recovery from various heart conditions. Heart Rate (HR) is a cardiovascular variable, which can be easily monitored and provides important insights about cardiac functions during and after physical exercise. This study presents a HR-based modeling and control framework to monitor physiological changes during exercise, from which the exercise intensity is optimized to capitalize exercise outcomes. HR models were previously developed to investigate exercise physiology, but efficient model identification has not been extensively discussed in the literature. Most existing HR models are nonlinear state-space models, and traditional optimization techniques may fail to provide accurate model identification results. In this work, we propose to use particle filter (PF) to identify HR model parameters and further optimize the intensity of exercise, e.g., walking or running speed, based on the calibrated model. Specifically, sequential importance sampling and resampling (SISR) and smoothing were chosen to estimate state variables, and particle marginal Metropolis-Hastings method was used to identify model parameters from HR observations. In addition, using predictions calculated from the HR model, treadmill speed was optimized by minimizing the difference between predictions and the target HR. The modeling and control framework is validated with different case studies. The results demonstrate that the proposed method is a useful tool for personalized HR modeling and exercise control, which can benefit both regular exercise training and cardiac rehabilitation.