Optimization of dialysis needs methods for quantitative assessment of fluid and solutes transport in body compartments and solute and fluid exchange between body and dialysate. A mathematical model describing the dynamics of these quantities during dialysis is presented. This model is first and foremost based on the existing models, but also includes some new solutions. All parts were combined and extended by the detailed descriptions of selected aspects. The virtual patient model was applied to simulate and test different methods of treatment and their influence on the condition of the patient. The purpose of this model is to serve as a decision support system for selection of optimal treatment options for particular patient.