first draft of .asc to .tri converter