I am fitting some datasets with a user-defined function. I have something of the kind: f = Ax + By + Cz. A, B and C must be in the interval [-1,1] that I can set in the parameters bounds.
However I would like to use as a general linear constraint something like abs(A) + abs(B) + abs(C) = 1.
If I don't use the absolute value it works quite well but of course the sum is messed up by possible negative negative values of the parameters.
Anyone has an idea on how to implement this? The function is written in Origin C.
Origin 9.1 (64-bit) Sr2 Operating System: Windows 7