Looks and runs better here: https://turbowarp.org/1386371777?hqpen
Lines=(3^depth)+(3^i-1) where i=depth{+!}