e0404 / matRad

An open source multi-modality radiation treatment planning sytem developed by e0404 @ DKFZ
http://www.matRad.org
Other
223 stars 176 forks source link

About the dose calculation for KV photon beam with matRad. #476

Closed YeseulKima closed 3 years ago

YeseulKima commented 3 years ago

Hi! I'm a noob for this field and trying to get used to this program for my research. My questions are about the dose calculation of the photon beam (~ 250 keV). I've read the reference papers and have a few questions to ask.

Reference: [1] http://www.ncbi.nlm.nih.gov/pubmed/8497215 & [2] diploma thesis of Martin Siggel "Entwicklung einer schnellen Dosisberechnung auf Basis eines Pencil-Kernel Algorithmus für die Strahlentherapie mit Photonen"

1. About the primary fluence

% prepare primary fluence array
primaryFluence = machine.data.primaryFluence;
r     = sqrt( (F_X-stf(i).ray(j).rayPos(1)).^2 + (F_Z-stf(i).ray(j).rayPos(3)).^2 );
Psi   = interp1(primaryFluence(:,1)',primaryFluence(:,2)',r,'linear',0);

% apply the primary fluence to the field
Fx = F .* Psi;

(^ "matRad_calcPhotonDose.m" , line 188~194)

image (^ Eq 19 of the first reference paper)

Q1. Does the value Psi (line 191) indicate the Ψ'(x,y) on the reference paper? (And then the value Fx (line 194) indicate Ψ'(x,y)*F(x,y) within the eq 19?)

image

Q2. ^ Which MC simulation did you use to get this primary fluence data? I'm wondering if I can ever replicate this part with some commercialized MC simulations such as TOPAS or Geant4.

2. Kernel calculation method

image image (^ p.23 of the second reference paper)

Q3. As long as I know the source file "init_kernel.cpp" is open-source. If so, where can I find it? And to solve equation 3.15, D_r(d) and D_i(d) should be obtained from MC simulation or experiment, right..?

I'd greatly appreciate any help you can offer.

Best regard, Yeseul Kim.

wahln commented 3 years ago

Here are some answers: 1) The primary fluence is assumed to be rotation symmetric in its center, thus it is given depending on the radius r. The piece of code computes the radius r on the discretized field coordinates and computes the respective fluence for every point. Your comparison of code & paper veriables is therefore correct. I am quite sure that the primary fluence is taken from measurements from an accelerator. In principle, you could also get this from let's say phsp files or your own simulation. For that you would need to model the bremsstrahlungs-target or some form of virtual source and score the fluence in the collimator plane, and extract the radial distribution. If you would like to have some form of asymmetric primary fluence, some code adaptations would be necessary. 2) The C++ kernel computation code referenced in the thesis is not available. However, among our repos here there's also a repository that re-implements this kernel computation in Matlab given the respective quantities from measurements or MC simulations (TPRs, PDDs, prim. fluence, etc.): https://github.com/e0404/photonPencilBeamKernelCalc @markbangert and @mingersming may be able to further comment on this.

YeseulKima commented 3 years ago

Dear wahln, Thank you indeed for your answer! And I'm sorry for my late reply..

I've checked the link you attached above. That project files and paper of professor Thomas Bortfeld helped me understand the ballpark process to obtain the pencil beam kernel. With the question no 2, I should try and pay more time.. I really appreciate your help though.

I hope all is well with you in this difficult time.

Best regards, Yeseul Kim.