Copying some solver code from another project