In article <[EMAIL PROTECTED]>,
TG <[EMAIL PROTECTED]> wrote:
>Hi there.
>
>Anyone knows how to use numpy / scipy in order to solve this ?
>
>* A is an array of shape (n,)
>* X is a positive float number
>* B is an array of shape (n,)
>* O is an array of shape (n,) containing only zeros.
>
>A.X - B = O
>min(X)
>
>thanks.
>

In general, no X solves the equality, so it's easy to minimize X.

If A is a non-zero positive multiple of B, exactly one X solves
the equality, so it's again easy to minimize.

If A and B vanish, choose X as the smallest positive float.

I suspect you intended a slightly different problem.  It's hard 
to guess what it is.
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to