#250 Edited to be Compiled by Compile Model and to use Solution