Skip to main content
. 2017 Feb 1;36(2):193–209. doi: 10.1177/0278364917691113
Algorithm 2 Random sample consensus robotically actuated delivery sheath localization
Inputs:
Ac{xc,v|v=1,,w}   ⊳ Set of detected edge points (xc)
f:H3mc   ⊳ Computes the algebraic circle model parameters (mc) from a set (H3) of three randomly selected edge points
C(mc,xc)   ⊳ Cost function for a single edge point (1 if xc is an inlier to the algebraic circle parameters (mc), 0 otherwise)
n   ⊳ Number of iterations
Outputs:
mc*   ⊳ Best model parameters
Sc*   ⊳ Best consensus set (inliers)
Jc*   ⊳ Best cost
Method:
 1: for i1,n do
 2: H3,irandom_3pnts(Ac)   ⊳ (I) Hypothesis
 3: mc,if(H3,i)
 4: ifsuffice(mc,i)then   ⊳ (II) Preliminary test
 5:  Sc,i{xcAc|C(mc,i,xc)=1}
 6:  Jc,ixcAcC(mc,i,xc)
 7:  ifJc*<Jc,ithen   ⊳ (III) Evaluation
 8:   Jc*Jc,i
 9:   mc*mc,i
 10:   Sc*Sc,i
 11:  end if
 12: end if
 13: ii+1
 14: end for