thnx i got it working.
Am 30.07.2010 12:00, schrieb Harald Schilly:
On 30 Jul., 00:01, Johannes dajo.m...@web.de wrote:
Hi list,
i try to solve a linear equation in ZZ in the variables w_i:
Here is a MILP formulation of your problem, I've pasted the input cell
in {{{}}} and the
On 30 Jul., 00:01, Johannes dajo.m...@web.de wrote:
Hi list,
i try to solve a linear equation in ZZ in the variables w_i:
Here is a MILP formulation of your problem, I've pasted the input cell
in {{{}}} and the output in between
{{{
p = MixedIntegerLinearProgram(maximization=False)
# not
Harald, this is very informative for me. Maybe something stepwise
like this should be at the top of
http://www.sagemath.org/doc/reference/sage/numerical/mip.html
so that it's very visible as an example of doing everything, or at
least as an additional example in
On 30 Jul., 18:14, kcrisman kcris...@gmail.com wrote:
Harald, this is very informative for me. Maybe something stepwise
like this should be at the top of...
#9647
H
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
Hello !!
You may also like this :
http://www-sop.inria.fr/members/Nathann.Cohen/tut/LP/
Writing documentation for both graphhs and LP has been responsble for
many of my last sleepless nights, though this documentation is in
french. The next ones will be for the english version :-)
Nathann
--
On Jul 29, 6:01 pm, Johannes dajo.m...@web.de wrote:
Hi list,
i try to solve a linear equation in ZZ in the variables w_i:
sage: variables = [var(w + str(i),domain=ZZ)for i in range(s.nvertices())]
sage: eq
(w0 + w1 + w2 - 14*w3, w1 + 2*w2 - 8*w3, 2*w2 - 3*w3)
sage: result
[w0 ==
maybe it helps if i give my full pice of code:
def calc_wights_by_sum_to_zero(s):
#create the equations
variables = [var(w + str(i),domain=ZZ)for i in range(s.nvertices())]
equation = reduce(lambda f1,f2: f1 + f2, [variables[i] * s.vertex(i)
for i in range(s.nvertices())])