Calculation of an optimal tariff is a principal challenge for pricing actuaries. In this contribution we are concerned with the renewal insurance business discussing various mathematical aspects of calculation of an optimal renewal tariff. Our motivation comes from two important actuarial tasks, namely a) construction of an optimal renewal tariff subject to business and technical constraints, and b) determination of an optimal allocation of certain premium loadings. We consider both continuous and discrete optimisation and then present several algorithmic sub-optimal solutions. Additionally, we explore some simulation techniques. Several illustrative examples show both the complexity and the importance of the optimisation approach.