Skip to main content
. Author manuscript; available in PMC: 2017 May 4.
Published in final edited form as: Proc IEEE Int Symp Biomed Imaging. 2016 Jun 16;2016:229–232. doi: 10.1109/ISBI.2016.7493251
Data: Head model, ROI definition, desired directional field, n
Result: Optimal stimulus pattern with at most n current sources
1 z0 // Initialize objective
2 ← {0} //Active set
3 t ← 0
4 while ≠ ø do
5  determination of r // Next branch
6 – ℱr
7  determination of p(r)
8  determination of branching
r12p(r)
9 for i ← 1 to p(r) do
10   t+iri
11   calculation of (xt+i, zt+i)
12   if zt+i > then
13    if xt+i then
14     zt+i
15    else
16      + t+i
17 tt + p(r)