Skip to content

Commit

Permalink
Update matRad_fluenceOptimization.m
Browse files Browse the repository at this point in the history
Some fields necessary for RBExD optimization have to be written if initial weights are passed in
  • Loading branch information
HomolkaN committed Dec 1, 2022
1 parent 093eb96 commit 74f4f5d
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions matRad_fluenceOptimization.m
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,15 @@
%do nothing as wInit was passed to the function
matRad_cfg.dispInfo('chosen provided wInit!\n');

% Write ixDose which is needed for the optimizer
if pln.bioParam.bioOpt
dij.ixDose = dij.bx~=0;

%pre-calculations
dij.gamma = zeros(dij.doseGrid.numOfVoxels,dij.numOfScenarios);
dij.gamma(dij.ixDose) = dij.ax(dij.ixDose)./(2*dij.bx(dij.ixDose));
end

elseif strcmp(pln.bioParam.model,'constRBE') && strcmp(pln.radiationMode,'protons')
% check if a constant RBE is defined - if not use 1.1
if ~isfield(dij,'RBE')
Expand Down

0 comments on commit 74f4f5d

Please sign in to comment.