The numerical simulation of continuum dislocations