Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
croissant equation in eclipse clp
:- lib(ic).
croissant(X,Y,Z) :-
(X^2+Y^2+Z^2+7*sqrt(5)/2-11/2)^2 - ((1+sqrt(5))*X-7+3*sqrt(5))^2-(1+sqrt(5))^2*Y^2 $= 0,
locate([X,Y,Z], 1e-5).
# one of the solutions
croissant(X,Y,Z).
X = X{0.0 .. 7.4073630564431975e-6}
Y = Y{1.066573563196598 .. 1.0665754743970506}
Z = Z{7.4073630564431975e-6 .. 1.4814726112886395e-5}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.