Jelly, 31 2828 27 bytes
Jm2BỊḄ&þJ=J€$ḤṚ|Ɗị"Ø^;;⁶Ʋ€UZJm2BỊḄJ=&ɗⱮJḤṚ|Ɗị"Ø^;;⁶Ʋ€UZ
Yikes... Still feels a little golfable, but it might just be the wrong approach entirely. It seems tantalizingly simple with certain praclang tools, but with so much to juggle, it comes out suprisingly clunky in Jelly!
Returns a list of lines.
Jm2BỊḄ&þJ=J€$ḤṚ|ƊJm2BỊḄJ=&ɗⱮJḤṚ|Ɗ Build the tree:
Jm2 For every [1, 3 .. length],
B take its arbitrary-length binary representation
Ḅ and convert back from binary
Ị with all bits set to 1.
Jm2BỊḄ This creates a bitmask for the period of that column.
& Bitwise AND
þJ ɗⱮJ tabledFor witheach [1 .. length].,
=& = is Isits eachbitwise elementAND ofwith each rowmask equal to
J J€$ the length1-index of thethat rowmask?
ḤṚ Double and reverse the comparisons
|Ɗ and bitwise OR with the original comparisons.
ị"Ø^;;⁶Ʋ€UZ Format the tree:
ị Modular 1-index each row into
" Ʋ€ the corresponding character
Ø^; appended to "/\"
;⁶ with a space appended.
U Reverse each row
Z and transpose.