Your model contains "var c2;" and then also "subject to c2: ...". You cannot use the same name for both a variable and a constraint, so when AMPL's processor reaches the constraint you get a "c2 is already defined" error.
After the error, the AMPL processor has stopped in the middle of a command, as shown by the "ampl?" prompt. As a result the rest of the commands were not processed, and also your "reset;" was not processed. This was the source of all the subsequent errors, which you should not see again once the first error is fixed.
Bob Fourer
am...@googlegroups.com
=======