Solver example of SP both python and mathematica