Re: Integer Solutions
- To: mathgroup at smc.vnet.net
- Subject: [mg37513] Re: [mg37496] Integer Solutions
- From: "Eric L. Strobel" <fyzycyst at comcast.net>
- Date: Sat, 2 Nov 2002 03:30:47 -0500 (EST)
- Reply-to: fyzycyst at mailaps.org
- Sender: owner-wri-mathgroup at wolfram.com
on 11/1/02 1:44 AM, Munsup Seoh at munsup.seoh at wright.edu wrote: > I have a question. Please help me. Can I solve the following equation with > a simple "Solve" command in Mathematica? > > ((x1, x2, x3, x4): x1 + x2 + x3 + x4 == 4; x1, x2, x3, x4 are nonnegative > integers} One equation, four unknowns? I think Solve isn't what you want. I'm not familiar with the optimization part of Mathematica (though I'd like to be), but this certainly looks like an optimization with cost function L = (x1 + x2 + x3 + x4) - 4 and constraints x1 > 0, x2 > 0, x3 > 0, x4 > 0. I assume this is a "toy" problem used to explore possible solutions of your real problem, as the answer x1 = x2 = x3 = x4 = 1 is pretty obvious by inspection. - Eric. -- Eric Strobel (fyzycyst at NOSPAM^mailaps.org) ===================================================================== You can lead an idiot to knowledge, but you can't make him think... =====================================================================