1. A method for optimizing radiation doses delivered by a set of beams, wherein each beam is a radiotherapy particle beam, comprising the steps of: providing a model of the set of beams, and a target dose; determining a model and a target dose in normal form, including a Gram matrix from the model; subsampling the target dose to determine initial intensity values for the set of beams, and iterating over the following steps until convergence: adding a very small positive value, 0<ε<<1, to each intensity value to ensure the intensity values are greater than zero; multiplying a vector of intensity values by the Gram matrix to determine a product; dividing, element-wise, the product into the form target dose to determine corresponding ratios; and determining whether the ratios are all close to 1, within a numerical error tolerance, and if true, outputting the intensity values of the set of beam, and otherwise if false, multiplying the intensity values by the ratios before a next iteration.