Studies of bunch distortion and bursting threshold in the generation of coherent THz-radiation at the ANKA storage ring