Is it safe to use heat tape on a drain line (p-trap)?
I would build a small insulated enclosure around the trap and drain. Could easily be constructed with a couple pieces of lumber or some left over log siding. (see you have log siding on the wall) Heat tape could scorch the PVC and be hard to regulate.