Started work on ec

It doesn't work and I am not sure why. I am looking into a mechanism to
validate it.