After struggling and searching on Google of a way to get CPLEX solver for AMPL on my Ubuntu 16.04 Xenial.
1- Go to
and download “ampl.gz” and “cplex.gz” then extract both files.
2- Give both of them execution right with “chmod +x ampl cplex” command.
3- Run AMPL by typing “./ampl”
4- on AMPL load your solver by typing: option solver ‘./cplex’
(don’t forget the quotation marks)
5- Load your .mod file, and you’re ready to solve…