1 | initial version |
Well, you sure can't use that script, that's not python. The tubular neighborhood of radius R can be plotted easily with a parametric_surface3d plot, if you can write its parametric equations. Parametric equations for a tubular neighborhood require a Frenet frame for the curve which might be problematic, but you seem to know about that. I don't know of anyone who has worked the equations already, although there is some people working in diff geometry in Sage right now, so I might be wrong. Doens't seem too hard, anyway, does it?
Alternatively, if you can find the implicit equations for the tubular neighborhood, you can use implicit_plot3d (though I don't see how this can be done in some generality).