when you do x1=random(10), you are essentially telling desmos to treat x1 as a variable and find the 4 unkown constants: a, b, c and d. Because there are only 3 terms (x^4, x^2, constant), they are only 3 equations. So you are asking desmos to solve for 4 unknows with 3 equations. There are infinite set of solutions and desmos will randomly give you one set of these numerous solutions. When you do a=2, you are giving desmos another equation, so now there are 4 equations for 4 unknowns, fullly solvable. When you put a=2, b, c and d all become integers. that is not magic. That's just only solution for b, c and d and they happen be all integers. When you put other values for a, you will get other unique values for b, c, d and here is an example (a=8)