NEED HELP! Wrap circles issue, Armin Hofmann kind of style

I recently saw an interesting graphic design that uses the Durbin Path, original from Armin Hofmann graphic design, then YuinChien developed it.

In this rule, the wrapping path sometimes goes through ex-tangent line, sometimes goes through in-tangent line, I have checked the forum about the wrap topic, but I didn’t found related strategies.

Can anyone give some tips, thanks a lot!
20220726 wrap circle Armin Hofmann kind (9.2 KB)