Aufgabe:
Code 01:
g1:m+f+k=100;
g2:3*m+2*f+1/2*k=100;
l:solve([g1,g2],[m,f,k]);
L:makelist(ev(l,%r1=i),i,0,100);
Es müssen noch die Lösungen ausgefiltert werden, die keine natürliche Zahlen sind.
Code 02:
g1:m+f+k=100;
g2:3*m+2*f+1/2*k=100;
l:solve([g1,g2],[m,f,k]);
l:map(rhs,l[1]);
L:makelist(ev(l,%r1=i),i,0,100);
L:setify(L);
subset(L,lambda([e],is(e[1]>0 and e[1]=floor(e[1]) and e[2]>0 and e[2]=floor(e[2]) and e[3]>0 and e[3]=floor(e[3]))));
Code 03:
g1:x+y+z=100$
g2:3*x+2*y+1/2*z=100$
for x:1 thru 100 do
for y:1 thru 100 do
for z:1 thru 100 do
if is(ev(g1)) then
if is(ev(g2)) then
disp([x,y,z])$
wxMaxima 03:
Maxima-Online: http://maxima-online.org/?inc=r430503550
Unten die Berechnung mit http://maxima.cesga.es

Lösung mit Python: