Take the 2-minute tour ×

I'm new to eclipse CLP and I want to implement a predicate that gets all the angles equivalent to a specific sinusoidal function, something like

:- lib(ic).
solve(L) :-
L = [X,Y,Z],
cos(X) #= sin(Y) + sin(Z),

I know that this scheme probably works for integral values of the variables; so I need an alternative solution that also uses CLP.

share|improve this question
add comment

1 Answer

Ok I figured it out,

V = [X,Y,Z],
V::[0 .. 180],
cos(X*pi/180) $= sin(Y*pi/180) + sin(Z*pi/180),

N.B: the cos and sin predicates work with radians

share|improve this answer
add comment

Your Answer


