Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Logical Rules
Date: Thu, 13 Sep 2007 16:49:42 +0000 (UTC)
Organization: Caltech
Lines: 23
Message-ID: <fcbpn6$eo0$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-02-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1189702182 15104 172.30.248.37 (13 Sep 2007 16:49:42 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 13 Sep 2007 16:49:42 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1110432
Xref: news.mathworks.com comp.soft-sys.matlab:428390



I am trying to see if Matlab has a toolbox for something 
like this, or where I might look for ideas on how to 
efficiently solve the following

A{1}=[1,2]
A{2}=[2,3]
A{3}=[1,3]
A{4}=[1,2,3,4]

This reads:

Position 1 can be 1 or 2
Position 2 can be 2 or 3
Position 3 can be 1 or 3
Position 4 can be 1, 2, 3 or 4

Given that each number can only be used once, we know that 
Position 4 must be 4.

So my question is, how could I perform such logic in a 
general way? Any ideas where I should look?

Thanks so much.