Skip to content

Cannot run example #1

@loongmxbt

Description

@loongmxbt

In examples/create-a-model.ipynb, when I run into

m.add_constraints(3*x + 7*y, '>=', 10)
m.add_constraints(5*x + 2*y, '>=', 3);

The console shows:

---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-23-72c2b3a3f44b> in <module>
----> 1 m.add_constraints(3*x + 7*y, '>=', 10)
      2 m.add_constraints(5*x + 2*y, '>=', 3);

TypeError: add_constraints() missing 1 required positional argument: 'rhs'

Python version 3.7.9
pip install linopy

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions