jijmodeling 1.0.0rc2__cp38-cp38-manylinux_2_28_x86_64.whl → 1.0.0rc4__cp38-cp38-manylinux_2_28_x86_64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of jijmodeling might be problematic. Click here for more details.
- jijmodeling/__init__.pyi +3145 -158
- jijmodeling/jijmodeling.cpython-38-x86_64-linux-gnu.so +0 -0
- {jijmodeling-1.0.0rc2.dist-info → jijmodeling-1.0.0rc4.dist-info}/METADATA +8 -4
- jijmodeling-1.0.0rc4.dist-info/RECORD +8 -0
- jijmodeling-1.0.0rc2.dist-info/RECORD +0 -8
- {jijmodeling-1.0.0rc2.dist-info → jijmodeling-1.0.0rc4.dist-info}/WHEEL +0 -0
- {jijmodeling-1.0.0rc2.dist-info → jijmodeling-1.0.0rc4.dist-info}/license_files/LICENSE.txt +0 -0
jijmodeling/__init__.pyi
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import typing
|
|
1
|
+
import typing, enum
|
|
2
2
|
|
|
3
3
|
@typing.final
|
|
4
4
|
class AbsOp:
|
|
@@ -14,9 +14,108 @@ class AbsOp:
|
|
|
14
14
|
Note:
|
|
15
15
|
The AbsOp class does not have a constructor.
|
|
16
16
|
"""
|
|
17
|
-
def
|
|
17
|
+
def __new__(cls):
|
|
18
18
|
pass
|
|
19
19
|
|
|
20
|
+
def __add__(self, value, /):
|
|
21
|
+
"""
|
|
22
|
+
Return self+value.
|
|
23
|
+
"""
|
|
24
|
+
pass
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
def __mod__(self, value, /):
|
|
28
|
+
"""
|
|
29
|
+
Return self%value.
|
|
30
|
+
"""
|
|
31
|
+
pass
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
def __mul__(self, value, /):
|
|
35
|
+
"""
|
|
36
|
+
Return self*value.
|
|
37
|
+
"""
|
|
38
|
+
pass
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
def __neg__(self, /):
|
|
42
|
+
"""
|
|
43
|
+
-self
|
|
44
|
+
"""
|
|
45
|
+
pass
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
def __pow__(self, value, mod=None, /):
|
|
49
|
+
"""
|
|
50
|
+
Return pow(self, value, mod).
|
|
51
|
+
"""
|
|
52
|
+
pass
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
def __radd__(self, value, /):
|
|
56
|
+
"""
|
|
57
|
+
Return value+self.
|
|
58
|
+
"""
|
|
59
|
+
pass
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
def __rmod__(self, value, /):
|
|
63
|
+
"""
|
|
64
|
+
Return value%self.
|
|
65
|
+
"""
|
|
66
|
+
pass
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
def __rmul__(self, value, /):
|
|
70
|
+
"""
|
|
71
|
+
Return value*self.
|
|
72
|
+
"""
|
|
73
|
+
pass
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
def __rpow__(self, value, mod=None, /):
|
|
77
|
+
"""
|
|
78
|
+
Return pow(value, self, mod).
|
|
79
|
+
"""
|
|
80
|
+
pass
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
def __rsub__(self, value, /):
|
|
84
|
+
"""
|
|
85
|
+
Return value-self.
|
|
86
|
+
"""
|
|
87
|
+
pass
|
|
88
|
+
|
|
89
|
+
|
|
90
|
+
def __rtruediv__(self, value, /):
|
|
91
|
+
"""
|
|
92
|
+
Return value/self.
|
|
93
|
+
"""
|
|
94
|
+
pass
|
|
95
|
+
|
|
96
|
+
|
|
97
|
+
def __sub__(self, value, /):
|
|
98
|
+
"""
|
|
99
|
+
Return self-value.
|
|
100
|
+
"""
|
|
101
|
+
pass
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
def __truediv__(self, value, /):
|
|
105
|
+
"""
|
|
106
|
+
Return self/value.
|
|
107
|
+
"""
|
|
108
|
+
pass
|
|
109
|
+
|
|
110
|
+
|
|
111
|
+
def _repr_latex_(self, /):
|
|
112
|
+
"""
|
|
113
|
+
|
|
114
|
+
"""
|
|
115
|
+
pass
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
operand: typing.Any
|
|
20
119
|
def set_latex(self, /, latex=None):
|
|
21
120
|
"""
|
|
22
121
|
Set the LaTeX representation of the object.
|
|
@@ -45,9 +144,107 @@ class AddOp:
|
|
|
45
144
|
instantiation method is by calling the addition operation on other
|
|
46
145
|
expressions.
|
|
47
146
|
"""
|
|
48
|
-
def
|
|
147
|
+
def __new__(cls):
|
|
148
|
+
pass
|
|
149
|
+
|
|
150
|
+
def __add__(self, value, /):
|
|
151
|
+
"""
|
|
152
|
+
Return self+value.
|
|
153
|
+
"""
|
|
154
|
+
pass
|
|
155
|
+
|
|
156
|
+
|
|
157
|
+
def __mod__(self, value, /):
|
|
158
|
+
"""
|
|
159
|
+
Return self%value.
|
|
160
|
+
"""
|
|
161
|
+
pass
|
|
162
|
+
|
|
163
|
+
|
|
164
|
+
def __mul__(self, value, /):
|
|
165
|
+
"""
|
|
166
|
+
Return self*value.
|
|
167
|
+
"""
|
|
168
|
+
pass
|
|
169
|
+
|
|
170
|
+
|
|
171
|
+
def __neg__(self, /):
|
|
172
|
+
"""
|
|
173
|
+
-self
|
|
174
|
+
"""
|
|
175
|
+
pass
|
|
176
|
+
|
|
177
|
+
|
|
178
|
+
def __pow__(self, value, mod=None, /):
|
|
179
|
+
"""
|
|
180
|
+
Return pow(self, value, mod).
|
|
181
|
+
"""
|
|
182
|
+
pass
|
|
183
|
+
|
|
184
|
+
|
|
185
|
+
def __radd__(self, value, /):
|
|
186
|
+
"""
|
|
187
|
+
Return value+self.
|
|
188
|
+
"""
|
|
189
|
+
pass
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
def __rmod__(self, value, /):
|
|
193
|
+
"""
|
|
194
|
+
Return value%self.
|
|
195
|
+
"""
|
|
196
|
+
pass
|
|
197
|
+
|
|
198
|
+
|
|
199
|
+
def __rmul__(self, value, /):
|
|
200
|
+
"""
|
|
201
|
+
Return value*self.
|
|
202
|
+
"""
|
|
203
|
+
pass
|
|
204
|
+
|
|
205
|
+
|
|
206
|
+
def __rpow__(self, value, mod=None, /):
|
|
207
|
+
"""
|
|
208
|
+
Return pow(value, self, mod).
|
|
209
|
+
"""
|
|
210
|
+
pass
|
|
211
|
+
|
|
212
|
+
|
|
213
|
+
def __rsub__(self, value, /):
|
|
214
|
+
"""
|
|
215
|
+
Return value-self.
|
|
216
|
+
"""
|
|
217
|
+
pass
|
|
218
|
+
|
|
219
|
+
|
|
220
|
+
def __rtruediv__(self, value, /):
|
|
221
|
+
"""
|
|
222
|
+
Return value/self.
|
|
223
|
+
"""
|
|
224
|
+
pass
|
|
225
|
+
|
|
226
|
+
|
|
227
|
+
def __sub__(self, value, /):
|
|
228
|
+
"""
|
|
229
|
+
Return self-value.
|
|
230
|
+
"""
|
|
231
|
+
pass
|
|
232
|
+
|
|
233
|
+
|
|
234
|
+
def __truediv__(self, value, /):
|
|
235
|
+
"""
|
|
236
|
+
Return self/value.
|
|
237
|
+
"""
|
|
238
|
+
pass
|
|
239
|
+
|
|
240
|
+
|
|
241
|
+
def _repr_latex_(self, /):
|
|
242
|
+
"""
|
|
243
|
+
|
|
244
|
+
"""
|
|
49
245
|
pass
|
|
50
246
|
|
|
247
|
+
|
|
51
248
|
def set_latex(self, /, latex=None):
|
|
52
249
|
"""
|
|
53
250
|
Set the LaTeX representation of the object.
|
|
@@ -59,6 +256,7 @@ class AddOp:
|
|
|
59
256
|
pass
|
|
60
257
|
|
|
61
258
|
|
|
259
|
+
terms: typing.Any
|
|
62
260
|
@typing.final
|
|
63
261
|
class AndOp:
|
|
64
262
|
"""
|
|
@@ -74,9 +272,58 @@ class AndOp:
|
|
|
74
272
|
Note:
|
|
75
273
|
The AndOp class does not have a constructor.
|
|
76
274
|
"""
|
|
77
|
-
def
|
|
275
|
+
def __new__(cls):
|
|
276
|
+
pass
|
|
277
|
+
|
|
278
|
+
def __and__(self, value, /):
|
|
279
|
+
"""
|
|
280
|
+
Return self&value.
|
|
281
|
+
"""
|
|
282
|
+
pass
|
|
283
|
+
|
|
284
|
+
|
|
285
|
+
def __or__(self, value, /):
|
|
286
|
+
"""
|
|
287
|
+
Return self|value.
|
|
288
|
+
"""
|
|
289
|
+
pass
|
|
290
|
+
|
|
291
|
+
|
|
292
|
+
def __rand__(self, value, /):
|
|
293
|
+
"""
|
|
294
|
+
Return value&self.
|
|
295
|
+
"""
|
|
296
|
+
pass
|
|
297
|
+
|
|
298
|
+
|
|
299
|
+
def __ror__(self, value, /):
|
|
300
|
+
"""
|
|
301
|
+
Return value|self.
|
|
302
|
+
"""
|
|
303
|
+
pass
|
|
304
|
+
|
|
305
|
+
|
|
306
|
+
def __rxor__(self, value, /):
|
|
307
|
+
"""
|
|
308
|
+
Return value^self.
|
|
309
|
+
"""
|
|
310
|
+
pass
|
|
311
|
+
|
|
312
|
+
|
|
313
|
+
def __xor__(self, value, /):
|
|
314
|
+
"""
|
|
315
|
+
Return self^value.
|
|
316
|
+
"""
|
|
317
|
+
pass
|
|
318
|
+
|
|
319
|
+
|
|
320
|
+
def _repr_latex_(self, /):
|
|
321
|
+
"""
|
|
322
|
+
|
|
323
|
+
"""
|
|
78
324
|
pass
|
|
79
325
|
|
|
326
|
+
|
|
80
327
|
def set_latex(self, /, latex=None):
|
|
81
328
|
"""
|
|
82
329
|
Set the LaTeX representation of the object.
|
|
@@ -88,6 +335,7 @@ class AndOp:
|
|
|
88
335
|
pass
|
|
89
336
|
|
|
90
337
|
|
|
338
|
+
terms: typing.Any
|
|
91
339
|
@typing.final
|
|
92
340
|
class ArrayLength:
|
|
93
341
|
"""
|
|
@@ -95,8 +343,9 @@ class ArrayLength:
|
|
|
95
343
|
|
|
96
344
|
The ArrayLength class is to refer to the number of elements of an axis in an array.
|
|
97
345
|
|
|
98
|
-
This class is not intended to be
|
|
99
|
-
the `len_at` method
|
|
346
|
+
This class is not intended to be constructed directly. Instead, we
|
|
347
|
+
recommend using the `len_at` method of `Placeholder`, `Element` or
|
|
348
|
+
`Subscript`.
|
|
100
349
|
|
|
101
350
|
Attributes:
|
|
102
351
|
array: A variable with `ndim >= 1`.
|
|
@@ -113,9 +362,110 @@ class ArrayLength:
|
|
|
113
362
|
>>> a = jm.Placeholder("a", ndim=2)
|
|
114
363
|
>>> N = a.len_at(0, latex="N")
|
|
115
364
|
"""
|
|
116
|
-
def
|
|
365
|
+
def __new__(cls, array, axis, *, latex=None, description=None):
|
|
366
|
+
pass
|
|
367
|
+
|
|
368
|
+
def __add__(self, value, /):
|
|
369
|
+
"""
|
|
370
|
+
Return self+value.
|
|
371
|
+
"""
|
|
372
|
+
pass
|
|
373
|
+
|
|
374
|
+
|
|
375
|
+
def __mod__(self, value, /):
|
|
376
|
+
"""
|
|
377
|
+
Return self%value.
|
|
378
|
+
"""
|
|
379
|
+
pass
|
|
380
|
+
|
|
381
|
+
|
|
382
|
+
def __mul__(self, value, /):
|
|
383
|
+
"""
|
|
384
|
+
Return self*value.
|
|
385
|
+
"""
|
|
117
386
|
pass
|
|
118
387
|
|
|
388
|
+
|
|
389
|
+
def __neg__(self, /):
|
|
390
|
+
"""
|
|
391
|
+
-self
|
|
392
|
+
"""
|
|
393
|
+
pass
|
|
394
|
+
|
|
395
|
+
|
|
396
|
+
def __pow__(self, value, mod=None, /):
|
|
397
|
+
"""
|
|
398
|
+
Return pow(self, value, mod).
|
|
399
|
+
"""
|
|
400
|
+
pass
|
|
401
|
+
|
|
402
|
+
|
|
403
|
+
def __radd__(self, value, /):
|
|
404
|
+
"""
|
|
405
|
+
Return value+self.
|
|
406
|
+
"""
|
|
407
|
+
pass
|
|
408
|
+
|
|
409
|
+
|
|
410
|
+
def __rmod__(self, value, /):
|
|
411
|
+
"""
|
|
412
|
+
Return value%self.
|
|
413
|
+
"""
|
|
414
|
+
pass
|
|
415
|
+
|
|
416
|
+
|
|
417
|
+
def __rmul__(self, value, /):
|
|
418
|
+
"""
|
|
419
|
+
Return value*self.
|
|
420
|
+
"""
|
|
421
|
+
pass
|
|
422
|
+
|
|
423
|
+
|
|
424
|
+
def __rpow__(self, value, mod=None, /):
|
|
425
|
+
"""
|
|
426
|
+
Return pow(value, self, mod).
|
|
427
|
+
"""
|
|
428
|
+
pass
|
|
429
|
+
|
|
430
|
+
|
|
431
|
+
def __rsub__(self, value, /):
|
|
432
|
+
"""
|
|
433
|
+
Return value-self.
|
|
434
|
+
"""
|
|
435
|
+
pass
|
|
436
|
+
|
|
437
|
+
|
|
438
|
+
def __rtruediv__(self, value, /):
|
|
439
|
+
"""
|
|
440
|
+
Return value/self.
|
|
441
|
+
"""
|
|
442
|
+
pass
|
|
443
|
+
|
|
444
|
+
|
|
445
|
+
def __sub__(self, value, /):
|
|
446
|
+
"""
|
|
447
|
+
Return self-value.
|
|
448
|
+
"""
|
|
449
|
+
pass
|
|
450
|
+
|
|
451
|
+
|
|
452
|
+
def __truediv__(self, value, /):
|
|
453
|
+
"""
|
|
454
|
+
Return self/value.
|
|
455
|
+
"""
|
|
456
|
+
pass
|
|
457
|
+
|
|
458
|
+
|
|
459
|
+
def _repr_latex_(self, /):
|
|
460
|
+
"""
|
|
461
|
+
|
|
462
|
+
"""
|
|
463
|
+
pass
|
|
464
|
+
|
|
465
|
+
|
|
466
|
+
array: typing.Any
|
|
467
|
+
axis: typing.Any
|
|
468
|
+
description: str
|
|
119
469
|
def set_latex(self, /, latex=None):
|
|
120
470
|
"""
|
|
121
471
|
Set the LaTeX representation of the object.
|
|
@@ -167,21 +517,102 @@ class BinaryVar:
|
|
|
167
517
|
>>> x[123]
|
|
168
518
|
BinaryVar(name='x', shape=[NumberLit(value=124)])[NumberLit(value=123)]
|
|
169
519
|
"""
|
|
170
|
-
def
|
|
520
|
+
def __new__(cls, name: str, *, shape=None, latex=None, description=None):
|
|
171
521
|
pass
|
|
172
522
|
|
|
173
|
-
def
|
|
523
|
+
def __add__(self, value, /):
|
|
174
524
|
"""
|
|
175
|
-
|
|
176
|
-
If the LaTeX representation is not set, the default representation is set.
|
|
177
|
-
|
|
178
|
-
Args:
|
|
179
|
-
latex (str, optional): LaTeX representation of the object. Defaults to None.
|
|
525
|
+
Return self+value.
|
|
180
526
|
"""
|
|
181
527
|
pass
|
|
182
528
|
|
|
183
529
|
|
|
184
|
-
|
|
530
|
+
def __getitem__(self, key, /):
|
|
531
|
+
"""
|
|
532
|
+
Return self[key].
|
|
533
|
+
"""
|
|
534
|
+
pass
|
|
535
|
+
|
|
536
|
+
|
|
537
|
+
def __mul__(self, value, /):
|
|
538
|
+
"""
|
|
539
|
+
Return self*value.
|
|
540
|
+
"""
|
|
541
|
+
pass
|
|
542
|
+
|
|
543
|
+
|
|
544
|
+
def __neg__(self, /):
|
|
545
|
+
"""
|
|
546
|
+
-self
|
|
547
|
+
"""
|
|
548
|
+
pass
|
|
549
|
+
|
|
550
|
+
|
|
551
|
+
def __pow__(self, value, mod=None, /):
|
|
552
|
+
"""
|
|
553
|
+
Return pow(self, value, mod).
|
|
554
|
+
"""
|
|
555
|
+
pass
|
|
556
|
+
|
|
557
|
+
|
|
558
|
+
def __radd__(self, value, /):
|
|
559
|
+
"""
|
|
560
|
+
Return value+self.
|
|
561
|
+
"""
|
|
562
|
+
pass
|
|
563
|
+
|
|
564
|
+
|
|
565
|
+
def __rmul__(self, value, /):
|
|
566
|
+
"""
|
|
567
|
+
Return value*self.
|
|
568
|
+
"""
|
|
569
|
+
pass
|
|
570
|
+
|
|
571
|
+
|
|
572
|
+
def __rpow__(self, value, mod=None, /):
|
|
573
|
+
"""
|
|
574
|
+
Return pow(value, self, mod).
|
|
575
|
+
"""
|
|
576
|
+
pass
|
|
577
|
+
|
|
578
|
+
|
|
579
|
+
def __rsub__(self, value, /):
|
|
580
|
+
"""
|
|
581
|
+
Return value-self.
|
|
582
|
+
"""
|
|
583
|
+
pass
|
|
584
|
+
|
|
585
|
+
|
|
586
|
+
def __sub__(self, value, /):
|
|
587
|
+
"""
|
|
588
|
+
Return self-value.
|
|
589
|
+
"""
|
|
590
|
+
pass
|
|
591
|
+
|
|
592
|
+
|
|
593
|
+
def _repr_latex_(self, /):
|
|
594
|
+
"""
|
|
595
|
+
|
|
596
|
+
"""
|
|
597
|
+
pass
|
|
598
|
+
|
|
599
|
+
|
|
600
|
+
description: str
|
|
601
|
+
name: str
|
|
602
|
+
ndim: int
|
|
603
|
+
def set_latex(self, /, latex=None):
|
|
604
|
+
"""
|
|
605
|
+
Set the LaTeX representation of the object.
|
|
606
|
+
If the LaTeX representation is not set, the default representation is set.
|
|
607
|
+
|
|
608
|
+
Args:
|
|
609
|
+
latex (str, optional): LaTeX representation of the object. Defaults to None.
|
|
610
|
+
"""
|
|
611
|
+
pass
|
|
612
|
+
|
|
613
|
+
|
|
614
|
+
shape: tuple
|
|
615
|
+
@typing.final
|
|
185
616
|
class CeilOp:
|
|
186
617
|
"""
|
|
187
618
|
A class for representing the ceil operator
|
|
@@ -195,9 +626,108 @@ class CeilOp:
|
|
|
195
626
|
Note:
|
|
196
627
|
The CeilOp class does not have a constructor.
|
|
197
628
|
"""
|
|
198
|
-
def
|
|
629
|
+
def __new__(cls):
|
|
630
|
+
pass
|
|
631
|
+
|
|
632
|
+
def __add__(self, value, /):
|
|
633
|
+
"""
|
|
634
|
+
Return self+value.
|
|
635
|
+
"""
|
|
636
|
+
pass
|
|
637
|
+
|
|
638
|
+
|
|
639
|
+
def __mod__(self, value, /):
|
|
640
|
+
"""
|
|
641
|
+
Return self%value.
|
|
642
|
+
"""
|
|
643
|
+
pass
|
|
644
|
+
|
|
645
|
+
|
|
646
|
+
def __mul__(self, value, /):
|
|
647
|
+
"""
|
|
648
|
+
Return self*value.
|
|
649
|
+
"""
|
|
650
|
+
pass
|
|
651
|
+
|
|
652
|
+
|
|
653
|
+
def __neg__(self, /):
|
|
654
|
+
"""
|
|
655
|
+
-self
|
|
656
|
+
"""
|
|
657
|
+
pass
|
|
658
|
+
|
|
659
|
+
|
|
660
|
+
def __pow__(self, value, mod=None, /):
|
|
661
|
+
"""
|
|
662
|
+
Return pow(self, value, mod).
|
|
663
|
+
"""
|
|
664
|
+
pass
|
|
665
|
+
|
|
666
|
+
|
|
667
|
+
def __radd__(self, value, /):
|
|
668
|
+
"""
|
|
669
|
+
Return value+self.
|
|
670
|
+
"""
|
|
671
|
+
pass
|
|
672
|
+
|
|
673
|
+
|
|
674
|
+
def __rmod__(self, value, /):
|
|
675
|
+
"""
|
|
676
|
+
Return value%self.
|
|
677
|
+
"""
|
|
678
|
+
pass
|
|
679
|
+
|
|
680
|
+
|
|
681
|
+
def __rmul__(self, value, /):
|
|
682
|
+
"""
|
|
683
|
+
Return value*self.
|
|
684
|
+
"""
|
|
685
|
+
pass
|
|
686
|
+
|
|
687
|
+
|
|
688
|
+
def __rpow__(self, value, mod=None, /):
|
|
689
|
+
"""
|
|
690
|
+
Return pow(value, self, mod).
|
|
691
|
+
"""
|
|
692
|
+
pass
|
|
693
|
+
|
|
694
|
+
|
|
695
|
+
def __rsub__(self, value, /):
|
|
696
|
+
"""
|
|
697
|
+
Return value-self.
|
|
698
|
+
"""
|
|
699
|
+
pass
|
|
700
|
+
|
|
701
|
+
|
|
702
|
+
def __rtruediv__(self, value, /):
|
|
703
|
+
"""
|
|
704
|
+
Return value/self.
|
|
705
|
+
"""
|
|
706
|
+
pass
|
|
707
|
+
|
|
708
|
+
|
|
709
|
+
def __sub__(self, value, /):
|
|
710
|
+
"""
|
|
711
|
+
Return self-value.
|
|
712
|
+
"""
|
|
713
|
+
pass
|
|
714
|
+
|
|
715
|
+
|
|
716
|
+
def __truediv__(self, value, /):
|
|
717
|
+
"""
|
|
718
|
+
Return self/value.
|
|
719
|
+
"""
|
|
720
|
+
pass
|
|
721
|
+
|
|
722
|
+
|
|
723
|
+
def _repr_latex_(self, /):
|
|
724
|
+
"""
|
|
725
|
+
|
|
726
|
+
"""
|
|
199
727
|
pass
|
|
200
728
|
|
|
729
|
+
|
|
730
|
+
operand: typing.Any
|
|
201
731
|
def set_latex(self, /, latex=None):
|
|
202
732
|
"""
|
|
203
733
|
Set the LaTeX representation of the object.
|
|
@@ -261,9 +791,18 @@ class Constraint:
|
|
|
261
791
|
{'expression': x[i, j] <= 2, 'forall': [i, (j, j != i)]}
|
|
262
792
|
|
|
263
793
|
"""
|
|
264
|
-
def
|
|
794
|
+
def __new__(cls, name: str, expression, *, forall=None):
|
|
795
|
+
pass
|
|
796
|
+
|
|
797
|
+
def _repr_latex_(self, /):
|
|
798
|
+
"""
|
|
799
|
+
|
|
800
|
+
"""
|
|
265
801
|
pass
|
|
266
802
|
|
|
803
|
+
|
|
804
|
+
expression: typing.Any
|
|
805
|
+
forall: typing.Any
|
|
267
806
|
def is_equality(self, /):
|
|
268
807
|
"""
|
|
269
808
|
Returns true if the constraint is an equality constraint.
|
|
@@ -300,14 +839,21 @@ class Constraint:
|
|
|
300
839
|
pass
|
|
301
840
|
|
|
302
841
|
|
|
842
|
+
left: typing.Any
|
|
843
|
+
name: str
|
|
844
|
+
right: typing.Any
|
|
845
|
+
sense: typing.Any
|
|
303
846
|
@typing.final
|
|
304
847
|
class ConstraintSense:
|
|
305
848
|
"""
|
|
306
849
|
Equality of a constraint
|
|
307
850
|
"""
|
|
308
|
-
def
|
|
851
|
+
def __new__(cls):
|
|
309
852
|
pass
|
|
310
853
|
|
|
854
|
+
EQUAL: ConstraintSense
|
|
855
|
+
GREATER_THAN_EQUAL: ConstraintSense
|
|
856
|
+
LESS_THAN_EQUAL: ConstraintSense
|
|
311
857
|
@typing.final
|
|
312
858
|
class ContinuousVar:
|
|
313
859
|
"""
|
|
@@ -364,9 +910,90 @@ class ContinuousVar:
|
|
|
364
910
|
>>> x[123]
|
|
365
911
|
ContinuousVar(name='x', shape=[NumberLit(value=124)], lower_bound=NumberLit(value=0), upper_bound=NumberLit(value=2))[NumberLit(value=123)]
|
|
366
912
|
"""
|
|
367
|
-
def
|
|
913
|
+
def __new__(cls, name: str, *, shape=None, lower_bound, upper_bound, latex=None, description=None):
|
|
914
|
+
pass
|
|
915
|
+
|
|
916
|
+
def __add__(self, value, /):
|
|
917
|
+
"""
|
|
918
|
+
Return self+value.
|
|
919
|
+
"""
|
|
920
|
+
pass
|
|
921
|
+
|
|
922
|
+
|
|
923
|
+
def __getitem__(self, key, /):
|
|
924
|
+
"""
|
|
925
|
+
Return self[key].
|
|
926
|
+
"""
|
|
927
|
+
pass
|
|
928
|
+
|
|
929
|
+
|
|
930
|
+
def __mul__(self, value, /):
|
|
931
|
+
"""
|
|
932
|
+
Return self*value.
|
|
933
|
+
"""
|
|
934
|
+
pass
|
|
935
|
+
|
|
936
|
+
|
|
937
|
+
def __neg__(self, /):
|
|
938
|
+
"""
|
|
939
|
+
-self
|
|
940
|
+
"""
|
|
941
|
+
pass
|
|
942
|
+
|
|
943
|
+
|
|
944
|
+
def __pow__(self, value, mod=None, /):
|
|
945
|
+
"""
|
|
946
|
+
Return pow(self, value, mod).
|
|
947
|
+
"""
|
|
948
|
+
pass
|
|
949
|
+
|
|
950
|
+
|
|
951
|
+
def __radd__(self, value, /):
|
|
952
|
+
"""
|
|
953
|
+
Return value+self.
|
|
954
|
+
"""
|
|
955
|
+
pass
|
|
956
|
+
|
|
957
|
+
|
|
958
|
+
def __rmul__(self, value, /):
|
|
959
|
+
"""
|
|
960
|
+
Return value*self.
|
|
961
|
+
"""
|
|
962
|
+
pass
|
|
963
|
+
|
|
964
|
+
|
|
965
|
+
def __rpow__(self, value, mod=None, /):
|
|
966
|
+
"""
|
|
967
|
+
Return pow(value, self, mod).
|
|
968
|
+
"""
|
|
969
|
+
pass
|
|
970
|
+
|
|
971
|
+
|
|
972
|
+
def __rsub__(self, value, /):
|
|
973
|
+
"""
|
|
974
|
+
Return value-self.
|
|
975
|
+
"""
|
|
976
|
+
pass
|
|
977
|
+
|
|
978
|
+
|
|
979
|
+
def __sub__(self, value, /):
|
|
980
|
+
"""
|
|
981
|
+
Return self-value.
|
|
982
|
+
"""
|
|
983
|
+
pass
|
|
984
|
+
|
|
985
|
+
|
|
986
|
+
def _repr_latex_(self, /):
|
|
987
|
+
"""
|
|
988
|
+
|
|
989
|
+
"""
|
|
368
990
|
pass
|
|
369
991
|
|
|
992
|
+
|
|
993
|
+
description: str
|
|
994
|
+
lower_bound: typing.Any
|
|
995
|
+
name: str
|
|
996
|
+
ndim: int
|
|
370
997
|
def set_latex(self, /, latex=None):
|
|
371
998
|
"""
|
|
372
999
|
Set the LaTeX representation of the object.
|
|
@@ -378,6 +1005,8 @@ class ContinuousVar:
|
|
|
378
1005
|
pass
|
|
379
1006
|
|
|
380
1007
|
|
|
1008
|
+
shape: tuple
|
|
1009
|
+
upper_bound: typing.Any
|
|
381
1010
|
@typing.final
|
|
382
1011
|
class CustomPenaltyTerm:
|
|
383
1012
|
"""
|
|
@@ -428,17 +1057,96 @@ class CustomPenaltyTerm:
|
|
|
428
1057
|
>>> jm.CustomPenaltyTerm("custom penalty term", (x[i,j] - 2)**2, forall=[i, (j, j != i)]) # doctest: +ELLIPSIS
|
|
429
1058
|
<jijmodeling.CustomPenaltyTerm object at 0x...>
|
|
430
1059
|
"""
|
|
431
|
-
def
|
|
1060
|
+
def __new__(cls, name: str, expression, *, forall=None):
|
|
1061
|
+
pass
|
|
1062
|
+
|
|
1063
|
+
def _repr_latex_(self, /):
|
|
1064
|
+
"""
|
|
1065
|
+
|
|
1066
|
+
"""
|
|
432
1067
|
pass
|
|
433
1068
|
|
|
1069
|
+
|
|
1070
|
+
expression: typing.Any
|
|
1071
|
+
forall: typing.Any
|
|
1072
|
+
name: str
|
|
434
1073
|
@typing.final
|
|
435
1074
|
class DataType:
|
|
436
1075
|
"""
|
|
437
1076
|
|
|
438
1077
|
"""
|
|
439
|
-
def
|
|
1078
|
+
def __new__(cls):
|
|
1079
|
+
pass
|
|
1080
|
+
|
|
1081
|
+
FLOAT: DataType
|
|
1082
|
+
INTEGER: DataType
|
|
1083
|
+
@typing.final
|
|
1084
|
+
class DummyIndexedVar:
|
|
1085
|
+
"""
|
|
1086
|
+
A class for representing a subscripted variable with dummy indices
|
|
1087
|
+
|
|
1088
|
+
The DummyIndexedVar class is an intermediate representation to support syntactic sugar of sum/prod with slices.
|
|
1089
|
+
|
|
1090
|
+
Note:
|
|
1091
|
+
The DummyIndexedVar class does not have a constructor.
|
|
1092
|
+
"""
|
|
1093
|
+
def __new__(cls):
|
|
1094
|
+
pass
|
|
1095
|
+
|
|
1096
|
+
def prod(self, /):
|
|
1097
|
+
"""
|
|
1098
|
+
Take a prod of the decision variable over the elements for which the slice is given and return a ProdOp object.
|
|
1099
|
+
|
|
1100
|
+
Returns:
|
|
1101
|
+
ProdOp: A ProdOp object taken a prod of the decision variable over the elements for which the slice is given.
|
|
1102
|
+
|
|
1103
|
+
Note:
|
|
1104
|
+
An automatically created dummy index
|
|
1105
|
+
- has a name of the form `__dummy_{decision_var.name}_{axis}` where `axis` is the axis of the slice.
|
|
1106
|
+
- belongs to a range whose start defaults to 0 and end defaults to the length of the axis.
|
|
1107
|
+
- has description of the form `dummy index at {axis} for {decision_var.name}`.
|
|
1108
|
+
- has latex string of the form `\\ast_{axis}`.
|
|
1109
|
+
|
|
1110
|
+
Examples:
|
|
1111
|
+
Create a prodOp object taken a prod of the 2-dim binary variable over the 0-th elements for which the slice is given.
|
|
1112
|
+
|
|
1113
|
+
>>> import jijmodeling as jm
|
|
1114
|
+
>>> n = jm.Placeholder("n")
|
|
1115
|
+
>>> x = jm.BinaryVar("x", shape=(n, n))
|
|
1116
|
+
>>> i = jm.Element("__dummy_x_0", belong_to=n)
|
|
1117
|
+
>>> j = jm.Element("j", belong_to=n)
|
|
1118
|
+
>>> assert jm.is_same(x[:, j].prod(), jm.prod(i, x[i, j]))
|
|
1119
|
+
"""
|
|
1120
|
+
pass
|
|
1121
|
+
|
|
1122
|
+
|
|
1123
|
+
def sum(self, /):
|
|
1124
|
+
"""
|
|
1125
|
+
Take a sum of the decision variable over the elements for which the slice is given and return a SumOp object.
|
|
1126
|
+
|
|
1127
|
+
Returns:
|
|
1128
|
+
SumOp: A SumOp object taken a sum of the decision variable over the elements for which the slice is given.
|
|
1129
|
+
|
|
1130
|
+
Note:
|
|
1131
|
+
An automatically created dummy index
|
|
1132
|
+
- has a name of the form `__dummy_{decision_var.name}_{axis}` where `axis` is the axis of the slice.
|
|
1133
|
+
- belongs to a range whose start defaults to 0 and end defaults to the length of the axis.
|
|
1134
|
+
- has description of the form `dummy index at {axis} for {decision_var.name}`.
|
|
1135
|
+
- has latex string of the form `\\ast_{axis}`.
|
|
1136
|
+
|
|
1137
|
+
Examples:
|
|
1138
|
+
Create a SumOp object taken a sum of the 2-dim binary variable over the 0-th elements for which the slice is given.
|
|
1139
|
+
|
|
1140
|
+
>>> import jijmodeling as jm
|
|
1141
|
+
>>> n = jm.Placeholder("n")
|
|
1142
|
+
>>> x = jm.BinaryVar("x", shape=(n, n))
|
|
1143
|
+
>>> i = jm.Element("__dummy_x_0", belong_to=n)
|
|
1144
|
+
>>> j = jm.Element("j", belong_to=n)
|
|
1145
|
+
>>> assert jm.is_same(x[:, j].sum(), jm.sum(i, x[i, j]))
|
|
1146
|
+
"""
|
|
440
1147
|
pass
|
|
441
1148
|
|
|
1149
|
+
|
|
442
1150
|
@typing.final
|
|
443
1151
|
class Element:
|
|
444
1152
|
"""
|
|
@@ -450,10 +1158,13 @@ class Element:
|
|
|
450
1158
|
- an index of product $\displaystyle \prod$ (:obj:`ProdOp`)
|
|
451
1159
|
- a bound variable of the universal quantifier $\forall$ (:obj:`Forall`)
|
|
452
1160
|
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
1161
|
+
Elements specify a set to which they belong. The set can be:
|
|
1162
|
+
1. A half-open range, where the lower bound is included and the upper bound is excluded.
|
|
1163
|
+
2. A `Placeholder`, `Element`, or `Subscript` object with `ndim` >= 1.
|
|
1164
|
+
|
|
1165
|
+
Ranges are generally specified with tuples as `(start, end)`. For
|
|
1166
|
+
convenience, passing a single number or scalar object as the argument is
|
|
1167
|
+
interpreted as the `end` of a range starting from zero.
|
|
457
1168
|
|
|
458
1169
|
The index operator (`[]`) of an element with `ndim >= 1` returns a :obj:`Subscript` object.
|
|
459
1170
|
|
|
@@ -471,58 +1182,179 @@ class Element:
|
|
|
471
1182
|
description (str, optional): A description of the element.
|
|
472
1183
|
|
|
473
1184
|
Examples:
|
|
1185
|
+
Note that `belong_to` is a positional argument, not a keyword
|
|
1186
|
+
argument, and so does not need to be written out. This is done in some
|
|
1187
|
+
of these examples for clarity.
|
|
1188
|
+
|
|
474
1189
|
Create an element that belongs to a half-open range.
|
|
475
1190
|
|
|
476
1191
|
>>> import jijmodeling as jm
|
|
477
1192
|
>>> i = jm.Element("i", belong_to=(0,10))
|
|
478
1193
|
|
|
479
|
-
If you pass
|
|
1194
|
+
If you pass a scalar as the `belong_to` argument, the set that the element belongs to is a range starting at 0 going up to that value.
|
|
480
1195
|
|
|
481
1196
|
>>> import jijmodeling as jm
|
|
482
|
-
>>> i = jm.Element("i",
|
|
1197
|
+
>>> i = jm.Element("i", 10)
|
|
483
1198
|
>>> assert jm.is_same(i, jm.Element("i", belong_to=(0,10)))
|
|
484
1199
|
|
|
1200
|
+
The applies not just to numbers, but certain scalars, like `Placeholder` (with `ndim == 0`).
|
|
1201
|
+
|
|
1202
|
+
>>> import jijmodeling as jm
|
|
1203
|
+
>>> n = jm.Placeholder("N")
|
|
1204
|
+
>>> i = jm.Element("i", n)
|
|
1205
|
+
>>> assert jm.is_same(i, jm.Element("i", belong_to=(0,n)))
|
|
1206
|
+
|
|
485
1207
|
Create an element that belongs to a 1-dimensional placeholder.
|
|
486
1208
|
|
|
487
1209
|
>>> import jijmodeling as jm
|
|
488
1210
|
>>> E = jm.Placeholder("E", ndim=1)
|
|
489
|
-
>>> e = jm.Element("e",
|
|
1211
|
+
>>> e = jm.Element("e", E)
|
|
490
1212
|
|
|
491
1213
|
Create a 1-dimensional element with the index of `123`.
|
|
492
1214
|
|
|
493
1215
|
>>> import jijmodeling as jm
|
|
494
1216
|
>>> a = jm.Placeholder("a", ndim=2)
|
|
495
|
-
>>> e = jm.Element("e",
|
|
1217
|
+
>>> e = jm.Element("e", a)
|
|
496
1218
|
>>> e[123]
|
|
497
1219
|
Element(name='e', belong_to=Placeholder(name='a', ndim=2))[NumberLit(value=123)]
|
|
498
1220
|
"""
|
|
499
|
-
def
|
|
1221
|
+
def __new__(cls, name: str, belong_to, *, latex=None, description=None):
|
|
500
1222
|
pass
|
|
501
1223
|
|
|
502
|
-
def
|
|
1224
|
+
def __add__(self, value, /):
|
|
503
1225
|
"""
|
|
504
|
-
|
|
1226
|
+
Return self+value.
|
|
505
1227
|
"""
|
|
506
1228
|
pass
|
|
507
1229
|
|
|
508
1230
|
|
|
509
|
-
def
|
|
1231
|
+
def __getitem__(self, key, /):
|
|
510
1232
|
"""
|
|
511
|
-
|
|
512
|
-
If the LaTeX representation is not set, the default representation is set.
|
|
513
|
-
|
|
514
|
-
Args:
|
|
515
|
-
latex (str, optional): LaTeX representation of the object. Defaults to None.
|
|
1233
|
+
Return self[key].
|
|
516
1234
|
"""
|
|
517
1235
|
pass
|
|
518
1236
|
|
|
519
1237
|
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
1238
|
+
def __mod__(self, value, /):
|
|
1239
|
+
"""
|
|
1240
|
+
Return self%value.
|
|
1241
|
+
"""
|
|
1242
|
+
pass
|
|
1243
|
+
|
|
1244
|
+
|
|
1245
|
+
def __mul__(self, value, /):
|
|
1246
|
+
"""
|
|
1247
|
+
Return self*value.
|
|
1248
|
+
"""
|
|
1249
|
+
pass
|
|
1250
|
+
|
|
1251
|
+
|
|
1252
|
+
def __neg__(self, /):
|
|
1253
|
+
"""
|
|
1254
|
+
-self
|
|
1255
|
+
"""
|
|
1256
|
+
pass
|
|
1257
|
+
|
|
1258
|
+
|
|
1259
|
+
def __pow__(self, value, mod=None, /):
|
|
1260
|
+
"""
|
|
1261
|
+
Return pow(self, value, mod).
|
|
1262
|
+
"""
|
|
1263
|
+
pass
|
|
1264
|
+
|
|
1265
|
+
|
|
1266
|
+
def __radd__(self, value, /):
|
|
1267
|
+
"""
|
|
1268
|
+
Return value+self.
|
|
1269
|
+
"""
|
|
1270
|
+
pass
|
|
1271
|
+
|
|
1272
|
+
|
|
1273
|
+
def __rmod__(self, value, /):
|
|
1274
|
+
"""
|
|
1275
|
+
Return value%self.
|
|
1276
|
+
"""
|
|
1277
|
+
pass
|
|
1278
|
+
|
|
1279
|
+
|
|
1280
|
+
def __rmul__(self, value, /):
|
|
1281
|
+
"""
|
|
1282
|
+
Return value*self.
|
|
1283
|
+
"""
|
|
1284
|
+
pass
|
|
1285
|
+
|
|
1286
|
+
|
|
1287
|
+
def __rpow__(self, value, mod=None, /):
|
|
1288
|
+
"""
|
|
1289
|
+
Return pow(value, self, mod).
|
|
1290
|
+
"""
|
|
1291
|
+
pass
|
|
1292
|
+
|
|
1293
|
+
|
|
1294
|
+
def __rsub__(self, value, /):
|
|
1295
|
+
"""
|
|
1296
|
+
Return value-self.
|
|
1297
|
+
"""
|
|
1298
|
+
pass
|
|
1299
|
+
|
|
1300
|
+
|
|
1301
|
+
def __rtruediv__(self, value, /):
|
|
1302
|
+
"""
|
|
1303
|
+
Return value/self.
|
|
1304
|
+
"""
|
|
1305
|
+
pass
|
|
1306
|
+
|
|
1307
|
+
|
|
1308
|
+
def __sub__(self, value, /):
|
|
1309
|
+
"""
|
|
1310
|
+
Return self-value.
|
|
1311
|
+
"""
|
|
1312
|
+
pass
|
|
1313
|
+
|
|
1314
|
+
|
|
1315
|
+
def __truediv__(self, value, /):
|
|
1316
|
+
"""
|
|
1317
|
+
Return self/value.
|
|
1318
|
+
"""
|
|
1319
|
+
pass
|
|
1320
|
+
|
|
1321
|
+
|
|
1322
|
+
def _repr_latex_(self, /):
|
|
1323
|
+
"""
|
|
1324
|
+
|
|
1325
|
+
"""
|
|
1326
|
+
pass
|
|
1327
|
+
|
|
1328
|
+
|
|
1329
|
+
belong_to: typing.Any
|
|
1330
|
+
description: str
|
|
1331
|
+
def len_at(self, /, axis, *, latex=None, description=None):
|
|
1332
|
+
"""
|
|
1333
|
+
|
|
1334
|
+
"""
|
|
1335
|
+
pass
|
|
1336
|
+
|
|
1337
|
+
|
|
1338
|
+
name: str
|
|
1339
|
+
ndim: int
|
|
1340
|
+
def set_latex(self, /, latex=None):
|
|
1341
|
+
"""
|
|
1342
|
+
Set the LaTeX representation of the object.
|
|
1343
|
+
If the LaTeX representation is not set, the default representation is set.
|
|
1344
|
+
|
|
1345
|
+
Args:
|
|
1346
|
+
latex (str, optional): LaTeX representation of the object. Defaults to None.
|
|
1347
|
+
"""
|
|
1348
|
+
pass
|
|
1349
|
+
|
|
1350
|
+
|
|
1351
|
+
shape: tuple
|
|
1352
|
+
@typing.final
|
|
1353
|
+
class EqualOp:
|
|
1354
|
+
"""
|
|
1355
|
+
A class for representing the equal operator
|
|
1356
|
+
|
|
1357
|
+
The EqualOp class is used to represent the equal operator (`==`).
|
|
526
1358
|
The number of dimensions of each operand is zero.
|
|
527
1359
|
|
|
528
1360
|
Attributes:
|
|
@@ -532,9 +1364,60 @@ class EqualOp:
|
|
|
532
1364
|
Note:
|
|
533
1365
|
The EqualOp class does not have a constructor.
|
|
534
1366
|
"""
|
|
535
|
-
def
|
|
1367
|
+
def __new__(cls):
|
|
1368
|
+
pass
|
|
1369
|
+
|
|
1370
|
+
def __and__(self, value, /):
|
|
1371
|
+
"""
|
|
1372
|
+
Return self&value.
|
|
1373
|
+
"""
|
|
1374
|
+
pass
|
|
1375
|
+
|
|
1376
|
+
|
|
1377
|
+
def __or__(self, value, /):
|
|
1378
|
+
"""
|
|
1379
|
+
Return self|value.
|
|
1380
|
+
"""
|
|
1381
|
+
pass
|
|
1382
|
+
|
|
1383
|
+
|
|
1384
|
+
def __rand__(self, value, /):
|
|
1385
|
+
"""
|
|
1386
|
+
Return value&self.
|
|
1387
|
+
"""
|
|
1388
|
+
pass
|
|
1389
|
+
|
|
1390
|
+
|
|
1391
|
+
def __ror__(self, value, /):
|
|
1392
|
+
"""
|
|
1393
|
+
Return value|self.
|
|
1394
|
+
"""
|
|
1395
|
+
pass
|
|
1396
|
+
|
|
1397
|
+
|
|
1398
|
+
def __rxor__(self, value, /):
|
|
1399
|
+
"""
|
|
1400
|
+
Return value^self.
|
|
1401
|
+
"""
|
|
1402
|
+
pass
|
|
1403
|
+
|
|
1404
|
+
|
|
1405
|
+
def __xor__(self, value, /):
|
|
1406
|
+
"""
|
|
1407
|
+
Return self^value.
|
|
1408
|
+
"""
|
|
1409
|
+
pass
|
|
1410
|
+
|
|
1411
|
+
|
|
1412
|
+
def _repr_latex_(self, /):
|
|
1413
|
+
"""
|
|
1414
|
+
|
|
1415
|
+
"""
|
|
536
1416
|
pass
|
|
537
1417
|
|
|
1418
|
+
|
|
1419
|
+
left: typing.Any
|
|
1420
|
+
right: typing.Any
|
|
538
1421
|
def set_latex(self, /, latex=None):
|
|
539
1422
|
"""
|
|
540
1423
|
Set the LaTeX representation of the object.
|
|
@@ -561,9 +1444,15 @@ class Evaluation:
|
|
|
561
1444
|
constraint_values (numpy.ndarray): The constraint value of each sample.
|
|
562
1445
|
penalty (dict[str, numpy.ndarray]): The penalty of each sample.
|
|
563
1446
|
"""
|
|
564
|
-
def
|
|
1447
|
+
def __new__(cls, energy=None, objective=None, constraint_violations=None, constraint_forall=None, constraint_values=None, penalty=None):
|
|
565
1448
|
pass
|
|
566
1449
|
|
|
1450
|
+
constraint_expr_values: typing.Any
|
|
1451
|
+
constraint_forall: typing.Any
|
|
1452
|
+
constraint_values: typing.Any
|
|
1453
|
+
constraint_violations: typing.Any
|
|
1454
|
+
energy: typing.Any
|
|
1455
|
+
@staticmethod
|
|
567
1456
|
def from_dict(dict):
|
|
568
1457
|
"""
|
|
569
1458
|
Create a Evaluation object from the given dict.
|
|
@@ -576,6 +1465,7 @@ class Evaluation:
|
|
|
576
1465
|
pass
|
|
577
1466
|
|
|
578
1467
|
|
|
1468
|
+
@staticmethod
|
|
579
1469
|
def from_json(json):
|
|
580
1470
|
"""
|
|
581
1471
|
Create a Evaluation object from the JSON string.
|
|
@@ -589,6 +1479,8 @@ class Evaluation:
|
|
|
589
1479
|
pass
|
|
590
1480
|
|
|
591
1481
|
|
|
1482
|
+
objective: typing.Any
|
|
1483
|
+
penalty: typing.Any
|
|
592
1484
|
def to_dict(self, /):
|
|
593
1485
|
"""
|
|
594
1486
|
Convert into a dict.
|
|
@@ -636,9 +1528,108 @@ class FloorOp:
|
|
|
636
1528
|
Note:
|
|
637
1529
|
The FloorOp class does not have a constructor.
|
|
638
1530
|
"""
|
|
639
|
-
def
|
|
1531
|
+
def __new__(cls):
|
|
1532
|
+
pass
|
|
1533
|
+
|
|
1534
|
+
def __add__(self, value, /):
|
|
1535
|
+
"""
|
|
1536
|
+
Return self+value.
|
|
1537
|
+
"""
|
|
1538
|
+
pass
|
|
1539
|
+
|
|
1540
|
+
|
|
1541
|
+
def __mod__(self, value, /):
|
|
1542
|
+
"""
|
|
1543
|
+
Return self%value.
|
|
1544
|
+
"""
|
|
1545
|
+
pass
|
|
1546
|
+
|
|
1547
|
+
|
|
1548
|
+
def __mul__(self, value, /):
|
|
1549
|
+
"""
|
|
1550
|
+
Return self*value.
|
|
1551
|
+
"""
|
|
1552
|
+
pass
|
|
1553
|
+
|
|
1554
|
+
|
|
1555
|
+
def __neg__(self, /):
|
|
1556
|
+
"""
|
|
1557
|
+
-self
|
|
1558
|
+
"""
|
|
1559
|
+
pass
|
|
1560
|
+
|
|
1561
|
+
|
|
1562
|
+
def __pow__(self, value, mod=None, /):
|
|
1563
|
+
"""
|
|
1564
|
+
Return pow(self, value, mod).
|
|
1565
|
+
"""
|
|
1566
|
+
pass
|
|
1567
|
+
|
|
1568
|
+
|
|
1569
|
+
def __radd__(self, value, /):
|
|
1570
|
+
"""
|
|
1571
|
+
Return value+self.
|
|
1572
|
+
"""
|
|
1573
|
+
pass
|
|
1574
|
+
|
|
1575
|
+
|
|
1576
|
+
def __rmod__(self, value, /):
|
|
1577
|
+
"""
|
|
1578
|
+
Return value%self.
|
|
1579
|
+
"""
|
|
1580
|
+
pass
|
|
1581
|
+
|
|
1582
|
+
|
|
1583
|
+
def __rmul__(self, value, /):
|
|
1584
|
+
"""
|
|
1585
|
+
Return value*self.
|
|
1586
|
+
"""
|
|
1587
|
+
pass
|
|
1588
|
+
|
|
1589
|
+
|
|
1590
|
+
def __rpow__(self, value, mod=None, /):
|
|
1591
|
+
"""
|
|
1592
|
+
Return pow(value, self, mod).
|
|
1593
|
+
"""
|
|
1594
|
+
pass
|
|
1595
|
+
|
|
1596
|
+
|
|
1597
|
+
def __rsub__(self, value, /):
|
|
1598
|
+
"""
|
|
1599
|
+
Return value-self.
|
|
1600
|
+
"""
|
|
1601
|
+
pass
|
|
1602
|
+
|
|
1603
|
+
|
|
1604
|
+
def __rtruediv__(self, value, /):
|
|
1605
|
+
"""
|
|
1606
|
+
Return value/self.
|
|
1607
|
+
"""
|
|
1608
|
+
pass
|
|
1609
|
+
|
|
1610
|
+
|
|
1611
|
+
def __sub__(self, value, /):
|
|
1612
|
+
"""
|
|
1613
|
+
Return self-value.
|
|
1614
|
+
"""
|
|
1615
|
+
pass
|
|
1616
|
+
|
|
1617
|
+
|
|
1618
|
+
def __truediv__(self, value, /):
|
|
1619
|
+
"""
|
|
1620
|
+
Return self/value.
|
|
1621
|
+
"""
|
|
1622
|
+
pass
|
|
1623
|
+
|
|
1624
|
+
|
|
1625
|
+
def _repr_latex_(self, /):
|
|
1626
|
+
"""
|
|
1627
|
+
|
|
1628
|
+
"""
|
|
640
1629
|
pass
|
|
641
1630
|
|
|
1631
|
+
|
|
1632
|
+
operand: typing.Any
|
|
642
1633
|
def set_latex(self, /, latex=None):
|
|
643
1634
|
"""
|
|
644
1635
|
Set the LaTeX representation of the object.
|
|
@@ -665,9 +1656,60 @@ class GreaterThanEqualOp:
|
|
|
665
1656
|
Note:
|
|
666
1657
|
The GreaterThanEqualOp class does not have a constructor.
|
|
667
1658
|
"""
|
|
668
|
-
def
|
|
1659
|
+
def __new__(cls):
|
|
1660
|
+
pass
|
|
1661
|
+
|
|
1662
|
+
def __and__(self, value, /):
|
|
1663
|
+
"""
|
|
1664
|
+
Return self&value.
|
|
1665
|
+
"""
|
|
1666
|
+
pass
|
|
1667
|
+
|
|
1668
|
+
|
|
1669
|
+
def __or__(self, value, /):
|
|
1670
|
+
"""
|
|
1671
|
+
Return self|value.
|
|
1672
|
+
"""
|
|
1673
|
+
pass
|
|
1674
|
+
|
|
1675
|
+
|
|
1676
|
+
def __rand__(self, value, /):
|
|
1677
|
+
"""
|
|
1678
|
+
Return value&self.
|
|
1679
|
+
"""
|
|
1680
|
+
pass
|
|
1681
|
+
|
|
1682
|
+
|
|
1683
|
+
def __ror__(self, value, /):
|
|
1684
|
+
"""
|
|
1685
|
+
Return value|self.
|
|
1686
|
+
"""
|
|
1687
|
+
pass
|
|
1688
|
+
|
|
1689
|
+
|
|
1690
|
+
def __rxor__(self, value, /):
|
|
1691
|
+
"""
|
|
1692
|
+
Return value^self.
|
|
1693
|
+
"""
|
|
1694
|
+
pass
|
|
1695
|
+
|
|
1696
|
+
|
|
1697
|
+
def __xor__(self, value, /):
|
|
1698
|
+
"""
|
|
1699
|
+
Return self^value.
|
|
1700
|
+
"""
|
|
1701
|
+
pass
|
|
1702
|
+
|
|
1703
|
+
|
|
1704
|
+
def _repr_latex_(self, /):
|
|
1705
|
+
"""
|
|
1706
|
+
|
|
1707
|
+
"""
|
|
669
1708
|
pass
|
|
670
1709
|
|
|
1710
|
+
|
|
1711
|
+
left: typing.Any
|
|
1712
|
+
right: typing.Any
|
|
671
1713
|
def set_latex(self, /, latex=None):
|
|
672
1714
|
"""
|
|
673
1715
|
Set the LaTeX representation of the object.
|
|
@@ -694,37 +1736,88 @@ class GreaterThanOp:
|
|
|
694
1736
|
Note:
|
|
695
1737
|
The GreaterThanOp class does not have a constructor.
|
|
696
1738
|
"""
|
|
697
|
-
def
|
|
1739
|
+
def __new__(cls):
|
|
698
1740
|
pass
|
|
699
1741
|
|
|
700
|
-
def
|
|
1742
|
+
def __and__(self, value, /):
|
|
701
1743
|
"""
|
|
702
|
-
|
|
703
|
-
If the LaTeX representation is not set, the default representation is set.
|
|
704
|
-
|
|
705
|
-
Args:
|
|
706
|
-
latex (str, optional): LaTeX representation of the object. Defaults to None.
|
|
1744
|
+
Return self&value.
|
|
707
1745
|
"""
|
|
708
1746
|
pass
|
|
709
1747
|
|
|
710
1748
|
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
1749
|
+
def __or__(self, value, /):
|
|
1750
|
+
"""
|
|
1751
|
+
Return self|value.
|
|
1752
|
+
"""
|
|
1753
|
+
pass
|
|
1754
|
+
|
|
1755
|
+
|
|
1756
|
+
def __rand__(self, value, /):
|
|
1757
|
+
"""
|
|
1758
|
+
Return value&self.
|
|
1759
|
+
"""
|
|
1760
|
+
pass
|
|
1761
|
+
|
|
1762
|
+
|
|
1763
|
+
def __ror__(self, value, /):
|
|
1764
|
+
"""
|
|
1765
|
+
Return value|self.
|
|
1766
|
+
"""
|
|
1767
|
+
pass
|
|
1768
|
+
|
|
1769
|
+
|
|
1770
|
+
def __rxor__(self, value, /):
|
|
1771
|
+
"""
|
|
1772
|
+
Return value^self.
|
|
1773
|
+
"""
|
|
1774
|
+
pass
|
|
1775
|
+
|
|
1776
|
+
|
|
1777
|
+
def __xor__(self, value, /):
|
|
1778
|
+
"""
|
|
1779
|
+
Return self^value.
|
|
1780
|
+
"""
|
|
1781
|
+
pass
|
|
1782
|
+
|
|
1783
|
+
|
|
1784
|
+
def _repr_latex_(self, /):
|
|
1785
|
+
"""
|
|
1786
|
+
|
|
1787
|
+
"""
|
|
1788
|
+
pass
|
|
1789
|
+
|
|
1790
|
+
|
|
1791
|
+
left: typing.Any
|
|
1792
|
+
right: typing.Any
|
|
1793
|
+
def set_latex(self, /, latex=None):
|
|
1794
|
+
"""
|
|
1795
|
+
Set the LaTeX representation of the object.
|
|
1796
|
+
If the LaTeX representation is not set, the default representation is set.
|
|
1797
|
+
|
|
1798
|
+
Args:
|
|
1799
|
+
latex (str, optional): LaTeX representation of the object. Defaults to None.
|
|
1800
|
+
"""
|
|
1801
|
+
pass
|
|
1802
|
+
|
|
1803
|
+
|
|
1804
|
+
@typing.final
|
|
1805
|
+
class IntegerVar:
|
|
1806
|
+
"""
|
|
1807
|
+
A class for creating an integer variable
|
|
1808
|
+
|
|
1809
|
+
The IntegerVar class is used to create an integer variable.
|
|
1810
|
+
The lower and upper bounds of the variable can be specified by:
|
|
1811
|
+
- an integer value
|
|
1812
|
+
- a float value
|
|
1813
|
+
- a scalar expression that does not contains any decision variable
|
|
1814
|
+
- a Placeholder object whose dimensionality is equal to that of this variable.
|
|
1815
|
+
- a subscripted variable whose dimensionality is equal to that of this variable.
|
|
1816
|
+
|
|
1817
|
+
The index operator (`[]`) of a variable with `ndim >= 1` returns a :obj:`Subscript` object.
|
|
1818
|
+
|
|
1819
|
+
Attributes:
|
|
1820
|
+
name (str): A name of the integer variable.
|
|
728
1821
|
shape (tuple): A tuple with the size of each dimension of the integer variable. Empty if the variable is not multi-dimensional.
|
|
729
1822
|
lower_bound: The lower bound of the variable.
|
|
730
1823
|
upper_bound: The upper bound of the variable.
|
|
@@ -764,9 +1857,90 @@ class IntegerVar:
|
|
|
764
1857
|
>>> x[123]
|
|
765
1858
|
IntegerVar(name='x', shape=[NumberLit(value=124)], lower_bound=NumberLit(value=0), upper_bound=NumberLit(value=2))[NumberLit(value=123)]
|
|
766
1859
|
"""
|
|
767
|
-
def
|
|
1860
|
+
def __new__(cls, name: str, *, shape=None, lower_bound, upper_bound, latex=None, description=None):
|
|
1861
|
+
pass
|
|
1862
|
+
|
|
1863
|
+
def __add__(self, value, /):
|
|
1864
|
+
"""
|
|
1865
|
+
Return self+value.
|
|
1866
|
+
"""
|
|
1867
|
+
pass
|
|
1868
|
+
|
|
1869
|
+
|
|
1870
|
+
def __getitem__(self, key, /):
|
|
1871
|
+
"""
|
|
1872
|
+
Return self[key].
|
|
1873
|
+
"""
|
|
1874
|
+
pass
|
|
1875
|
+
|
|
1876
|
+
|
|
1877
|
+
def __mul__(self, value, /):
|
|
1878
|
+
"""
|
|
1879
|
+
Return self*value.
|
|
1880
|
+
"""
|
|
1881
|
+
pass
|
|
1882
|
+
|
|
1883
|
+
|
|
1884
|
+
def __neg__(self, /):
|
|
1885
|
+
"""
|
|
1886
|
+
-self
|
|
1887
|
+
"""
|
|
1888
|
+
pass
|
|
1889
|
+
|
|
1890
|
+
|
|
1891
|
+
def __pow__(self, value, mod=None, /):
|
|
1892
|
+
"""
|
|
1893
|
+
Return pow(self, value, mod).
|
|
1894
|
+
"""
|
|
1895
|
+
pass
|
|
1896
|
+
|
|
1897
|
+
|
|
1898
|
+
def __radd__(self, value, /):
|
|
1899
|
+
"""
|
|
1900
|
+
Return value+self.
|
|
1901
|
+
"""
|
|
1902
|
+
pass
|
|
1903
|
+
|
|
1904
|
+
|
|
1905
|
+
def __rmul__(self, value, /):
|
|
1906
|
+
"""
|
|
1907
|
+
Return value*self.
|
|
1908
|
+
"""
|
|
1909
|
+
pass
|
|
1910
|
+
|
|
1911
|
+
|
|
1912
|
+
def __rpow__(self, value, mod=None, /):
|
|
1913
|
+
"""
|
|
1914
|
+
Return pow(value, self, mod).
|
|
1915
|
+
"""
|
|
1916
|
+
pass
|
|
1917
|
+
|
|
1918
|
+
|
|
1919
|
+
def __rsub__(self, value, /):
|
|
1920
|
+
"""
|
|
1921
|
+
Return value-self.
|
|
1922
|
+
"""
|
|
1923
|
+
pass
|
|
1924
|
+
|
|
1925
|
+
|
|
1926
|
+
def __sub__(self, value, /):
|
|
1927
|
+
"""
|
|
1928
|
+
Return self-value.
|
|
1929
|
+
"""
|
|
768
1930
|
pass
|
|
769
1931
|
|
|
1932
|
+
|
|
1933
|
+
def _repr_latex_(self, /):
|
|
1934
|
+
"""
|
|
1935
|
+
|
|
1936
|
+
"""
|
|
1937
|
+
pass
|
|
1938
|
+
|
|
1939
|
+
|
|
1940
|
+
description: str
|
|
1941
|
+
lower_bound: typing.Any
|
|
1942
|
+
name: str
|
|
1943
|
+
ndim: int
|
|
770
1944
|
def set_latex(self, /, latex=None):
|
|
771
1945
|
"""
|
|
772
1946
|
Set the LaTeX representation of the object.
|
|
@@ -778,6 +1952,8 @@ class IntegerVar:
|
|
|
778
1952
|
pass
|
|
779
1953
|
|
|
780
1954
|
|
|
1955
|
+
shape: tuple
|
|
1956
|
+
upper_bound: typing.Any
|
|
781
1957
|
@typing.final
|
|
782
1958
|
class LessThanEqualOp:
|
|
783
1959
|
"""
|
|
@@ -793,9 +1969,60 @@ class LessThanEqualOp:
|
|
|
793
1969
|
Note:
|
|
794
1970
|
The LessThanEqualOp class does not have a constructor.
|
|
795
1971
|
"""
|
|
796
|
-
def
|
|
1972
|
+
def __new__(cls):
|
|
1973
|
+
pass
|
|
1974
|
+
|
|
1975
|
+
def __and__(self, value, /):
|
|
1976
|
+
"""
|
|
1977
|
+
Return self&value.
|
|
1978
|
+
"""
|
|
1979
|
+
pass
|
|
1980
|
+
|
|
1981
|
+
|
|
1982
|
+
def __or__(self, value, /):
|
|
1983
|
+
"""
|
|
1984
|
+
Return self|value.
|
|
1985
|
+
"""
|
|
1986
|
+
pass
|
|
1987
|
+
|
|
1988
|
+
|
|
1989
|
+
def __rand__(self, value, /):
|
|
1990
|
+
"""
|
|
1991
|
+
Return value&self.
|
|
1992
|
+
"""
|
|
1993
|
+
pass
|
|
1994
|
+
|
|
1995
|
+
|
|
1996
|
+
def __ror__(self, value, /):
|
|
1997
|
+
"""
|
|
1998
|
+
Return value|self.
|
|
1999
|
+
"""
|
|
2000
|
+
pass
|
|
2001
|
+
|
|
2002
|
+
|
|
2003
|
+
def __rxor__(self, value, /):
|
|
2004
|
+
"""
|
|
2005
|
+
Return value^self.
|
|
2006
|
+
"""
|
|
2007
|
+
pass
|
|
2008
|
+
|
|
2009
|
+
|
|
2010
|
+
def __xor__(self, value, /):
|
|
2011
|
+
"""
|
|
2012
|
+
Return self^value.
|
|
2013
|
+
"""
|
|
797
2014
|
pass
|
|
798
2015
|
|
|
2016
|
+
|
|
2017
|
+
def _repr_latex_(self, /):
|
|
2018
|
+
"""
|
|
2019
|
+
|
|
2020
|
+
"""
|
|
2021
|
+
pass
|
|
2022
|
+
|
|
2023
|
+
|
|
2024
|
+
left: typing.Any
|
|
2025
|
+
right: typing.Any
|
|
799
2026
|
def set_latex(self, /, latex=None):
|
|
800
2027
|
"""
|
|
801
2028
|
Set the LaTeX representation of the object.
|
|
@@ -822,9 +2049,60 @@ class LessThanOp:
|
|
|
822
2049
|
Note:
|
|
823
2050
|
The LessThanOp class does not have a constructor.
|
|
824
2051
|
"""
|
|
825
|
-
def
|
|
2052
|
+
def __new__(cls):
|
|
2053
|
+
pass
|
|
2054
|
+
|
|
2055
|
+
def __and__(self, value, /):
|
|
2056
|
+
"""
|
|
2057
|
+
Return self&value.
|
|
2058
|
+
"""
|
|
2059
|
+
pass
|
|
2060
|
+
|
|
2061
|
+
|
|
2062
|
+
def __or__(self, value, /):
|
|
2063
|
+
"""
|
|
2064
|
+
Return self|value.
|
|
2065
|
+
"""
|
|
2066
|
+
pass
|
|
2067
|
+
|
|
2068
|
+
|
|
2069
|
+
def __rand__(self, value, /):
|
|
2070
|
+
"""
|
|
2071
|
+
Return value&self.
|
|
2072
|
+
"""
|
|
2073
|
+
pass
|
|
2074
|
+
|
|
2075
|
+
|
|
2076
|
+
def __ror__(self, value, /):
|
|
2077
|
+
"""
|
|
2078
|
+
Return value|self.
|
|
2079
|
+
"""
|
|
826
2080
|
pass
|
|
827
2081
|
|
|
2082
|
+
|
|
2083
|
+
def __rxor__(self, value, /):
|
|
2084
|
+
"""
|
|
2085
|
+
Return value^self.
|
|
2086
|
+
"""
|
|
2087
|
+
pass
|
|
2088
|
+
|
|
2089
|
+
|
|
2090
|
+
def __xor__(self, value, /):
|
|
2091
|
+
"""
|
|
2092
|
+
Return self^value.
|
|
2093
|
+
"""
|
|
2094
|
+
pass
|
|
2095
|
+
|
|
2096
|
+
|
|
2097
|
+
def _repr_latex_(self, /):
|
|
2098
|
+
"""
|
|
2099
|
+
|
|
2100
|
+
"""
|
|
2101
|
+
pass
|
|
2102
|
+
|
|
2103
|
+
|
|
2104
|
+
left: typing.Any
|
|
2105
|
+
right: typing.Any
|
|
828
2106
|
def set_latex(self, /, latex=None):
|
|
829
2107
|
"""
|
|
830
2108
|
Set the LaTeX representation of the object.
|
|
@@ -850,65 +2128,362 @@ class LnOp:
|
|
|
850
2128
|
Note:
|
|
851
2129
|
The LnOp class does not have a constructor.
|
|
852
2130
|
"""
|
|
853
|
-
def
|
|
2131
|
+
def __new__(cls):
|
|
2132
|
+
pass
|
|
2133
|
+
|
|
2134
|
+
def __add__(self, value, /):
|
|
2135
|
+
"""
|
|
2136
|
+
Return self+value.
|
|
2137
|
+
"""
|
|
2138
|
+
pass
|
|
2139
|
+
|
|
2140
|
+
|
|
2141
|
+
def __mod__(self, value, /):
|
|
2142
|
+
"""
|
|
2143
|
+
Return self%value.
|
|
2144
|
+
"""
|
|
2145
|
+
pass
|
|
2146
|
+
|
|
2147
|
+
|
|
2148
|
+
def __mul__(self, value, /):
|
|
2149
|
+
"""
|
|
2150
|
+
Return self*value.
|
|
2151
|
+
"""
|
|
2152
|
+
pass
|
|
2153
|
+
|
|
2154
|
+
|
|
2155
|
+
def __neg__(self, /):
|
|
2156
|
+
"""
|
|
2157
|
+
-self
|
|
2158
|
+
"""
|
|
2159
|
+
pass
|
|
2160
|
+
|
|
2161
|
+
|
|
2162
|
+
def __pow__(self, value, mod=None, /):
|
|
2163
|
+
"""
|
|
2164
|
+
Return pow(self, value, mod).
|
|
2165
|
+
"""
|
|
2166
|
+
pass
|
|
2167
|
+
|
|
2168
|
+
|
|
2169
|
+
def __radd__(self, value, /):
|
|
2170
|
+
"""
|
|
2171
|
+
Return value+self.
|
|
2172
|
+
"""
|
|
2173
|
+
pass
|
|
2174
|
+
|
|
2175
|
+
|
|
2176
|
+
def __rmod__(self, value, /):
|
|
2177
|
+
"""
|
|
2178
|
+
Return value%self.
|
|
2179
|
+
"""
|
|
2180
|
+
pass
|
|
2181
|
+
|
|
2182
|
+
|
|
2183
|
+
def __rmul__(self, value, /):
|
|
2184
|
+
"""
|
|
2185
|
+
Return value*self.
|
|
2186
|
+
"""
|
|
2187
|
+
pass
|
|
2188
|
+
|
|
2189
|
+
|
|
2190
|
+
def __rpow__(self, value, mod=None, /):
|
|
2191
|
+
"""
|
|
2192
|
+
Return pow(value, self, mod).
|
|
2193
|
+
"""
|
|
2194
|
+
pass
|
|
2195
|
+
|
|
2196
|
+
|
|
2197
|
+
def __rsub__(self, value, /):
|
|
2198
|
+
"""
|
|
2199
|
+
Return value-self.
|
|
2200
|
+
"""
|
|
2201
|
+
pass
|
|
2202
|
+
|
|
2203
|
+
|
|
2204
|
+
def __rtruediv__(self, value, /):
|
|
2205
|
+
"""
|
|
2206
|
+
Return value/self.
|
|
2207
|
+
"""
|
|
2208
|
+
pass
|
|
2209
|
+
|
|
2210
|
+
|
|
2211
|
+
def __sub__(self, value, /):
|
|
2212
|
+
"""
|
|
2213
|
+
Return self-value.
|
|
2214
|
+
"""
|
|
2215
|
+
pass
|
|
2216
|
+
|
|
2217
|
+
|
|
2218
|
+
def __truediv__(self, value, /):
|
|
2219
|
+
"""
|
|
2220
|
+
Return self/value.
|
|
2221
|
+
"""
|
|
2222
|
+
pass
|
|
2223
|
+
|
|
2224
|
+
|
|
2225
|
+
def _repr_latex_(self, /):
|
|
2226
|
+
"""
|
|
2227
|
+
|
|
2228
|
+
"""
|
|
2229
|
+
pass
|
|
2230
|
+
|
|
2231
|
+
|
|
2232
|
+
operand: typing.Any
|
|
2233
|
+
def set_latex(self, /, latex=None):
|
|
2234
|
+
"""
|
|
2235
|
+
Set the LaTeX representation of the object.
|
|
2236
|
+
If the LaTeX representation is not set, the default representation is set.
|
|
2237
|
+
|
|
2238
|
+
Args:
|
|
2239
|
+
latex (str, optional): LaTeX representation of the object. Defaults to None.
|
|
2240
|
+
"""
|
|
2241
|
+
pass
|
|
2242
|
+
|
|
2243
|
+
|
|
2244
|
+
@typing.final
|
|
2245
|
+
class Log10Op:
|
|
2246
|
+
"""
|
|
2247
|
+
A class for representing the base 10 logarithm
|
|
2248
|
+
|
|
2249
|
+
The Log10Op class is used to represent the base 10 logarithm.
|
|
2250
|
+
The number of dimensions of the operand is zero.
|
|
2251
|
+
|
|
2252
|
+
Attributes:
|
|
2253
|
+
operand: The operand.
|
|
2254
|
+
|
|
2255
|
+
Note:
|
|
2256
|
+
The Log10Op class does not have a constructor.
|
|
2257
|
+
"""
|
|
2258
|
+
def __new__(cls):
|
|
2259
|
+
pass
|
|
2260
|
+
|
|
2261
|
+
def __add__(self, value, /):
|
|
2262
|
+
"""
|
|
2263
|
+
Return self+value.
|
|
2264
|
+
"""
|
|
2265
|
+
pass
|
|
2266
|
+
|
|
2267
|
+
|
|
2268
|
+
def __mod__(self, value, /):
|
|
2269
|
+
"""
|
|
2270
|
+
Return self%value.
|
|
2271
|
+
"""
|
|
2272
|
+
pass
|
|
2273
|
+
|
|
2274
|
+
|
|
2275
|
+
def __mul__(self, value, /):
|
|
2276
|
+
"""
|
|
2277
|
+
Return self*value.
|
|
2278
|
+
"""
|
|
2279
|
+
pass
|
|
2280
|
+
|
|
2281
|
+
|
|
2282
|
+
def __neg__(self, /):
|
|
2283
|
+
"""
|
|
2284
|
+
-self
|
|
2285
|
+
"""
|
|
2286
|
+
pass
|
|
2287
|
+
|
|
2288
|
+
|
|
2289
|
+
def __pow__(self, value, mod=None, /):
|
|
2290
|
+
"""
|
|
2291
|
+
Return pow(self, value, mod).
|
|
2292
|
+
"""
|
|
2293
|
+
pass
|
|
2294
|
+
|
|
2295
|
+
|
|
2296
|
+
def __radd__(self, value, /):
|
|
2297
|
+
"""
|
|
2298
|
+
Return value+self.
|
|
2299
|
+
"""
|
|
2300
|
+
pass
|
|
2301
|
+
|
|
2302
|
+
|
|
2303
|
+
def __rmod__(self, value, /):
|
|
2304
|
+
"""
|
|
2305
|
+
Return value%self.
|
|
2306
|
+
"""
|
|
2307
|
+
pass
|
|
2308
|
+
|
|
2309
|
+
|
|
2310
|
+
def __rmul__(self, value, /):
|
|
2311
|
+
"""
|
|
2312
|
+
Return value*self.
|
|
2313
|
+
"""
|
|
2314
|
+
pass
|
|
2315
|
+
|
|
2316
|
+
|
|
2317
|
+
def __rpow__(self, value, mod=None, /):
|
|
2318
|
+
"""
|
|
2319
|
+
Return pow(value, self, mod).
|
|
2320
|
+
"""
|
|
2321
|
+
pass
|
|
2322
|
+
|
|
2323
|
+
|
|
2324
|
+
def __rsub__(self, value, /):
|
|
2325
|
+
"""
|
|
2326
|
+
Return value-self.
|
|
2327
|
+
"""
|
|
2328
|
+
pass
|
|
2329
|
+
|
|
2330
|
+
|
|
2331
|
+
def __rtruediv__(self, value, /):
|
|
2332
|
+
"""
|
|
2333
|
+
Return value/self.
|
|
2334
|
+
"""
|
|
2335
|
+
pass
|
|
2336
|
+
|
|
2337
|
+
|
|
2338
|
+
def __sub__(self, value, /):
|
|
2339
|
+
"""
|
|
2340
|
+
Return self-value.
|
|
2341
|
+
"""
|
|
2342
|
+
pass
|
|
2343
|
+
|
|
2344
|
+
|
|
2345
|
+
def __truediv__(self, value, /):
|
|
2346
|
+
"""
|
|
2347
|
+
Return self/value.
|
|
2348
|
+
"""
|
|
2349
|
+
pass
|
|
2350
|
+
|
|
2351
|
+
|
|
2352
|
+
def _repr_latex_(self, /):
|
|
2353
|
+
"""
|
|
2354
|
+
|
|
2355
|
+
"""
|
|
2356
|
+
pass
|
|
2357
|
+
|
|
2358
|
+
|
|
2359
|
+
operand: typing.Any
|
|
2360
|
+
def set_latex(self, /, latex=None):
|
|
2361
|
+
"""
|
|
2362
|
+
Set the LaTeX representation of the object.
|
|
2363
|
+
If the LaTeX representation is not set, the default representation is set.
|
|
2364
|
+
|
|
2365
|
+
Args:
|
|
2366
|
+
latex (str, optional): LaTeX representation of the object. Defaults to None.
|
|
2367
|
+
"""
|
|
2368
|
+
pass
|
|
2369
|
+
|
|
2370
|
+
|
|
2371
|
+
@typing.final
|
|
2372
|
+
class Log2Op:
|
|
2373
|
+
"""
|
|
2374
|
+
A class for representing the base 2 logarithm
|
|
2375
|
+
|
|
2376
|
+
The Log2Op class is used to represent the base 2 logarithm.
|
|
2377
|
+
The number of dimensions of the operand is zero.
|
|
2378
|
+
|
|
2379
|
+
Attributes:
|
|
2380
|
+
operand: The operand.
|
|
2381
|
+
|
|
2382
|
+
Note:
|
|
2383
|
+
The Log2Op class does not have a constructor.
|
|
2384
|
+
"""
|
|
2385
|
+
def __new__(cls):
|
|
2386
|
+
pass
|
|
2387
|
+
|
|
2388
|
+
def __add__(self, value, /):
|
|
2389
|
+
"""
|
|
2390
|
+
Return self+value.
|
|
2391
|
+
"""
|
|
2392
|
+
pass
|
|
2393
|
+
|
|
2394
|
+
|
|
2395
|
+
def __mod__(self, value, /):
|
|
2396
|
+
"""
|
|
2397
|
+
Return self%value.
|
|
2398
|
+
"""
|
|
2399
|
+
pass
|
|
2400
|
+
|
|
2401
|
+
|
|
2402
|
+
def __mul__(self, value, /):
|
|
2403
|
+
"""
|
|
2404
|
+
Return self*value.
|
|
2405
|
+
"""
|
|
2406
|
+
pass
|
|
2407
|
+
|
|
2408
|
+
|
|
2409
|
+
def __neg__(self, /):
|
|
2410
|
+
"""
|
|
2411
|
+
-self
|
|
2412
|
+
"""
|
|
2413
|
+
pass
|
|
2414
|
+
|
|
2415
|
+
|
|
2416
|
+
def __pow__(self, value, mod=None, /):
|
|
2417
|
+
"""
|
|
2418
|
+
Return pow(self, value, mod).
|
|
2419
|
+
"""
|
|
2420
|
+
pass
|
|
2421
|
+
|
|
2422
|
+
|
|
2423
|
+
def __radd__(self, value, /):
|
|
2424
|
+
"""
|
|
2425
|
+
Return value+self.
|
|
2426
|
+
"""
|
|
2427
|
+
pass
|
|
2428
|
+
|
|
2429
|
+
|
|
2430
|
+
def __rmod__(self, value, /):
|
|
2431
|
+
"""
|
|
2432
|
+
Return value%self.
|
|
2433
|
+
"""
|
|
2434
|
+
pass
|
|
2435
|
+
|
|
2436
|
+
|
|
2437
|
+
def __rmul__(self, value, /):
|
|
2438
|
+
"""
|
|
2439
|
+
Return value*self.
|
|
2440
|
+
"""
|
|
2441
|
+
pass
|
|
2442
|
+
|
|
2443
|
+
|
|
2444
|
+
def __rpow__(self, value, mod=None, /):
|
|
2445
|
+
"""
|
|
2446
|
+
Return pow(value, self, mod).
|
|
2447
|
+
"""
|
|
2448
|
+
pass
|
|
2449
|
+
|
|
2450
|
+
|
|
2451
|
+
def __rsub__(self, value, /):
|
|
2452
|
+
"""
|
|
2453
|
+
Return value-self.
|
|
2454
|
+
"""
|
|
854
2455
|
pass
|
|
855
2456
|
|
|
856
|
-
|
|
2457
|
+
|
|
2458
|
+
def __rtruediv__(self, value, /):
|
|
857
2459
|
"""
|
|
858
|
-
|
|
859
|
-
If the LaTeX representation is not set, the default representation is set.
|
|
860
|
-
|
|
861
|
-
Args:
|
|
862
|
-
latex (str, optional): LaTeX representation of the object. Defaults to None.
|
|
2460
|
+
Return value/self.
|
|
863
2461
|
"""
|
|
864
2462
|
pass
|
|
865
2463
|
|
|
866
2464
|
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
The Log10Op class is used to represent the base 10 logarithm.
|
|
873
|
-
The number of dimensions of the operand is zero.
|
|
874
|
-
|
|
875
|
-
Attributes:
|
|
876
|
-
operand: The operand.
|
|
877
|
-
|
|
878
|
-
Note:
|
|
879
|
-
The Log10Op class does not have a constructor.
|
|
880
|
-
"""
|
|
881
|
-
def __init__():
|
|
2465
|
+
def __sub__(self, value, /):
|
|
2466
|
+
"""
|
|
2467
|
+
Return self-value.
|
|
2468
|
+
"""
|
|
882
2469
|
pass
|
|
883
2470
|
|
|
884
|
-
|
|
2471
|
+
|
|
2472
|
+
def __truediv__(self, value, /):
|
|
885
2473
|
"""
|
|
886
|
-
|
|
887
|
-
If the LaTeX representation is not set, the default representation is set.
|
|
888
|
-
|
|
889
|
-
Args:
|
|
890
|
-
latex (str, optional): LaTeX representation of the object. Defaults to None.
|
|
2474
|
+
Return self/value.
|
|
891
2475
|
"""
|
|
892
2476
|
pass
|
|
893
2477
|
|
|
894
2478
|
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
The Log2Op class is used to represent the base 2 logarithm.
|
|
901
|
-
The number of dimensions of the operand is zero.
|
|
902
|
-
|
|
903
|
-
Attributes:
|
|
904
|
-
operand: The operand.
|
|
905
|
-
|
|
906
|
-
Note:
|
|
907
|
-
The Log2Op class does not have a constructor.
|
|
908
|
-
"""
|
|
909
|
-
def __init__():
|
|
2479
|
+
def _repr_latex_(self, /):
|
|
2480
|
+
"""
|
|
2481
|
+
|
|
2482
|
+
"""
|
|
910
2483
|
pass
|
|
911
2484
|
|
|
2485
|
+
|
|
2486
|
+
operand: typing.Any
|
|
912
2487
|
def set_latex(self, /, latex=None):
|
|
913
2488
|
"""
|
|
914
2489
|
Set the LaTeX representation of the object.
|
|
@@ -935,9 +2510,107 @@ class MaxOp:
|
|
|
935
2510
|
The MaxOp class does not have a constructor. Its intended
|
|
936
2511
|
instantiation method is by calling the `max` function.
|
|
937
2512
|
"""
|
|
938
|
-
def
|
|
2513
|
+
def __new__(cls):
|
|
2514
|
+
pass
|
|
2515
|
+
|
|
2516
|
+
def __add__(self, value, /):
|
|
2517
|
+
"""
|
|
2518
|
+
Return self+value.
|
|
2519
|
+
"""
|
|
2520
|
+
pass
|
|
2521
|
+
|
|
2522
|
+
|
|
2523
|
+
def __mod__(self, value, /):
|
|
2524
|
+
"""
|
|
2525
|
+
Return self%value.
|
|
2526
|
+
"""
|
|
2527
|
+
pass
|
|
2528
|
+
|
|
2529
|
+
|
|
2530
|
+
def __mul__(self, value, /):
|
|
2531
|
+
"""
|
|
2532
|
+
Return self*value.
|
|
2533
|
+
"""
|
|
2534
|
+
pass
|
|
2535
|
+
|
|
2536
|
+
|
|
2537
|
+
def __neg__(self, /):
|
|
2538
|
+
"""
|
|
2539
|
+
-self
|
|
2540
|
+
"""
|
|
2541
|
+
pass
|
|
2542
|
+
|
|
2543
|
+
|
|
2544
|
+
def __pow__(self, value, mod=None, /):
|
|
2545
|
+
"""
|
|
2546
|
+
Return pow(self, value, mod).
|
|
2547
|
+
"""
|
|
2548
|
+
pass
|
|
2549
|
+
|
|
2550
|
+
|
|
2551
|
+
def __radd__(self, value, /):
|
|
2552
|
+
"""
|
|
2553
|
+
Return value+self.
|
|
2554
|
+
"""
|
|
2555
|
+
pass
|
|
2556
|
+
|
|
2557
|
+
|
|
2558
|
+
def __rmod__(self, value, /):
|
|
2559
|
+
"""
|
|
2560
|
+
Return value%self.
|
|
2561
|
+
"""
|
|
2562
|
+
pass
|
|
2563
|
+
|
|
2564
|
+
|
|
2565
|
+
def __rmul__(self, value, /):
|
|
2566
|
+
"""
|
|
2567
|
+
Return value*self.
|
|
2568
|
+
"""
|
|
2569
|
+
pass
|
|
2570
|
+
|
|
2571
|
+
|
|
2572
|
+
def __rpow__(self, value, mod=None, /):
|
|
2573
|
+
"""
|
|
2574
|
+
Return pow(value, self, mod).
|
|
2575
|
+
"""
|
|
2576
|
+
pass
|
|
2577
|
+
|
|
2578
|
+
|
|
2579
|
+
def __rsub__(self, value, /):
|
|
2580
|
+
"""
|
|
2581
|
+
Return value-self.
|
|
2582
|
+
"""
|
|
2583
|
+
pass
|
|
2584
|
+
|
|
2585
|
+
|
|
2586
|
+
def __rtruediv__(self, value, /):
|
|
2587
|
+
"""
|
|
2588
|
+
Return value/self.
|
|
2589
|
+
"""
|
|
2590
|
+
pass
|
|
2591
|
+
|
|
2592
|
+
|
|
2593
|
+
def __sub__(self, value, /):
|
|
2594
|
+
"""
|
|
2595
|
+
Return self-value.
|
|
2596
|
+
"""
|
|
2597
|
+
pass
|
|
2598
|
+
|
|
2599
|
+
|
|
2600
|
+
def __truediv__(self, value, /):
|
|
2601
|
+
"""
|
|
2602
|
+
Return self/value.
|
|
2603
|
+
"""
|
|
2604
|
+
pass
|
|
2605
|
+
|
|
2606
|
+
|
|
2607
|
+
def _repr_latex_(self, /):
|
|
2608
|
+
"""
|
|
2609
|
+
|
|
2610
|
+
"""
|
|
939
2611
|
pass
|
|
940
2612
|
|
|
2613
|
+
|
|
941
2614
|
def set_latex(self, /, latex=None):
|
|
942
2615
|
"""
|
|
943
2616
|
Set the LaTeX representation of the object.
|
|
@@ -949,6 +2622,7 @@ class MaxOp:
|
|
|
949
2622
|
pass
|
|
950
2623
|
|
|
951
2624
|
|
|
2625
|
+
terms: typing.Any
|
|
952
2626
|
@typing.final
|
|
953
2627
|
class MeasuringTime:
|
|
954
2628
|
"""
|
|
@@ -959,9 +2633,10 @@ class MeasuringTime:
|
|
|
959
2633
|
system (SystemTime): Time to measure system time.
|
|
960
2634
|
total (float, optional): Total time to solve the problem. Defaults to None.
|
|
961
2635
|
"""
|
|
962
|
-
def
|
|
2636
|
+
def __new__(cls, solve=None, system=None, total=None):
|
|
963
2637
|
pass
|
|
964
2638
|
|
|
2639
|
+
@staticmethod
|
|
965
2640
|
def from_dict(dict):
|
|
966
2641
|
"""
|
|
967
2642
|
Create a MeasuringTime object from the given dict.
|
|
@@ -977,6 +2652,7 @@ class MeasuringTime:
|
|
|
977
2652
|
pass
|
|
978
2653
|
|
|
979
2654
|
|
|
2655
|
+
@staticmethod
|
|
980
2656
|
def from_json(json):
|
|
981
2657
|
"""
|
|
982
2658
|
Create a MeasuringTime object from the JSON string.
|
|
@@ -990,6 +2666,8 @@ class MeasuringTime:
|
|
|
990
2666
|
pass
|
|
991
2667
|
|
|
992
2668
|
|
|
2669
|
+
solve: typing.Any
|
|
2670
|
+
system: typing.Any
|
|
993
2671
|
def to_dict(self, /):
|
|
994
2672
|
"""
|
|
995
2673
|
Convert into a dict.
|
|
@@ -1013,6 +2691,7 @@ class MeasuringTime:
|
|
|
1013
2691
|
pass
|
|
1014
2692
|
|
|
1015
2693
|
|
|
2694
|
+
total: typing.Any
|
|
1016
2695
|
@typing.final
|
|
1017
2696
|
class MinOp:
|
|
1018
2697
|
"""
|
|
@@ -1028,9 +2707,107 @@ class MinOp:
|
|
|
1028
2707
|
The MinOp class does not have a constructor. Its intended
|
|
1029
2708
|
instantiation method is by calling the `min` function.
|
|
1030
2709
|
"""
|
|
1031
|
-
def
|
|
2710
|
+
def __new__(cls):
|
|
2711
|
+
pass
|
|
2712
|
+
|
|
2713
|
+
def __add__(self, value, /):
|
|
2714
|
+
"""
|
|
2715
|
+
Return self+value.
|
|
2716
|
+
"""
|
|
2717
|
+
pass
|
|
2718
|
+
|
|
2719
|
+
|
|
2720
|
+
def __mod__(self, value, /):
|
|
2721
|
+
"""
|
|
2722
|
+
Return self%value.
|
|
2723
|
+
"""
|
|
2724
|
+
pass
|
|
2725
|
+
|
|
2726
|
+
|
|
2727
|
+
def __mul__(self, value, /):
|
|
2728
|
+
"""
|
|
2729
|
+
Return self*value.
|
|
2730
|
+
"""
|
|
2731
|
+
pass
|
|
2732
|
+
|
|
2733
|
+
|
|
2734
|
+
def __neg__(self, /):
|
|
2735
|
+
"""
|
|
2736
|
+
-self
|
|
2737
|
+
"""
|
|
2738
|
+
pass
|
|
2739
|
+
|
|
2740
|
+
|
|
2741
|
+
def __pow__(self, value, mod=None, /):
|
|
2742
|
+
"""
|
|
2743
|
+
Return pow(self, value, mod).
|
|
2744
|
+
"""
|
|
2745
|
+
pass
|
|
2746
|
+
|
|
2747
|
+
|
|
2748
|
+
def __radd__(self, value, /):
|
|
2749
|
+
"""
|
|
2750
|
+
Return value+self.
|
|
2751
|
+
"""
|
|
2752
|
+
pass
|
|
2753
|
+
|
|
2754
|
+
|
|
2755
|
+
def __rmod__(self, value, /):
|
|
2756
|
+
"""
|
|
2757
|
+
Return value%self.
|
|
2758
|
+
"""
|
|
2759
|
+
pass
|
|
2760
|
+
|
|
2761
|
+
|
|
2762
|
+
def __rmul__(self, value, /):
|
|
2763
|
+
"""
|
|
2764
|
+
Return value*self.
|
|
2765
|
+
"""
|
|
2766
|
+
pass
|
|
2767
|
+
|
|
2768
|
+
|
|
2769
|
+
def __rpow__(self, value, mod=None, /):
|
|
2770
|
+
"""
|
|
2771
|
+
Return pow(value, self, mod).
|
|
2772
|
+
"""
|
|
2773
|
+
pass
|
|
2774
|
+
|
|
2775
|
+
|
|
2776
|
+
def __rsub__(self, value, /):
|
|
2777
|
+
"""
|
|
2778
|
+
Return value-self.
|
|
2779
|
+
"""
|
|
2780
|
+
pass
|
|
2781
|
+
|
|
2782
|
+
|
|
2783
|
+
def __rtruediv__(self, value, /):
|
|
2784
|
+
"""
|
|
2785
|
+
Return value/self.
|
|
2786
|
+
"""
|
|
2787
|
+
pass
|
|
2788
|
+
|
|
2789
|
+
|
|
2790
|
+
def __sub__(self, value, /):
|
|
2791
|
+
"""
|
|
2792
|
+
Return self-value.
|
|
2793
|
+
"""
|
|
2794
|
+
pass
|
|
2795
|
+
|
|
2796
|
+
|
|
2797
|
+
def __truediv__(self, value, /):
|
|
2798
|
+
"""
|
|
2799
|
+
Return self/value.
|
|
2800
|
+
"""
|
|
1032
2801
|
pass
|
|
1033
2802
|
|
|
2803
|
+
|
|
2804
|
+
def _repr_latex_(self, /):
|
|
2805
|
+
"""
|
|
2806
|
+
|
|
2807
|
+
"""
|
|
2808
|
+
pass
|
|
2809
|
+
|
|
2810
|
+
|
|
1034
2811
|
def set_latex(self, /, latex=None):
|
|
1035
2812
|
"""
|
|
1036
2813
|
Set the LaTeX representation of the object.
|
|
@@ -1042,6 +2819,7 @@ class MinOp:
|
|
|
1042
2819
|
pass
|
|
1043
2820
|
|
|
1044
2821
|
|
|
2822
|
+
terms: typing.Any
|
|
1045
2823
|
@typing.final
|
|
1046
2824
|
class ModOp:
|
|
1047
2825
|
"""
|
|
@@ -1057,9 +2835,109 @@ class ModOp:
|
|
|
1057
2835
|
Note:
|
|
1058
2836
|
The ModOp class does not have a constructor.
|
|
1059
2837
|
"""
|
|
1060
|
-
def
|
|
2838
|
+
def __new__(cls):
|
|
2839
|
+
pass
|
|
2840
|
+
|
|
2841
|
+
def __add__(self, value, /):
|
|
2842
|
+
"""
|
|
2843
|
+
Return self+value.
|
|
2844
|
+
"""
|
|
2845
|
+
pass
|
|
2846
|
+
|
|
2847
|
+
|
|
2848
|
+
def __mod__(self, value, /):
|
|
2849
|
+
"""
|
|
2850
|
+
Return self%value.
|
|
2851
|
+
"""
|
|
2852
|
+
pass
|
|
2853
|
+
|
|
2854
|
+
|
|
2855
|
+
def __mul__(self, value, /):
|
|
2856
|
+
"""
|
|
2857
|
+
Return self*value.
|
|
2858
|
+
"""
|
|
2859
|
+
pass
|
|
2860
|
+
|
|
2861
|
+
|
|
2862
|
+
def __neg__(self, /):
|
|
2863
|
+
"""
|
|
2864
|
+
-self
|
|
2865
|
+
"""
|
|
2866
|
+
pass
|
|
2867
|
+
|
|
2868
|
+
|
|
2869
|
+
def __pow__(self, value, mod=None, /):
|
|
2870
|
+
"""
|
|
2871
|
+
Return pow(self, value, mod).
|
|
2872
|
+
"""
|
|
2873
|
+
pass
|
|
2874
|
+
|
|
2875
|
+
|
|
2876
|
+
def __radd__(self, value, /):
|
|
2877
|
+
"""
|
|
2878
|
+
Return value+self.
|
|
2879
|
+
"""
|
|
2880
|
+
pass
|
|
2881
|
+
|
|
2882
|
+
|
|
2883
|
+
def __rmod__(self, value, /):
|
|
2884
|
+
"""
|
|
2885
|
+
Return value%self.
|
|
2886
|
+
"""
|
|
2887
|
+
pass
|
|
2888
|
+
|
|
2889
|
+
|
|
2890
|
+
def __rmul__(self, value, /):
|
|
2891
|
+
"""
|
|
2892
|
+
Return value*self.
|
|
2893
|
+
"""
|
|
2894
|
+
pass
|
|
2895
|
+
|
|
2896
|
+
|
|
2897
|
+
def __rpow__(self, value, mod=None, /):
|
|
2898
|
+
"""
|
|
2899
|
+
Return pow(value, self, mod).
|
|
2900
|
+
"""
|
|
2901
|
+
pass
|
|
2902
|
+
|
|
2903
|
+
|
|
2904
|
+
def __rsub__(self, value, /):
|
|
2905
|
+
"""
|
|
2906
|
+
Return value-self.
|
|
2907
|
+
"""
|
|
2908
|
+
pass
|
|
2909
|
+
|
|
2910
|
+
|
|
2911
|
+
def __rtruediv__(self, value, /):
|
|
2912
|
+
"""
|
|
2913
|
+
Return value/self.
|
|
2914
|
+
"""
|
|
2915
|
+
pass
|
|
2916
|
+
|
|
2917
|
+
|
|
2918
|
+
def __sub__(self, value, /):
|
|
2919
|
+
"""
|
|
2920
|
+
Return self-value.
|
|
2921
|
+
"""
|
|
2922
|
+
pass
|
|
2923
|
+
|
|
2924
|
+
|
|
2925
|
+
def __truediv__(self, value, /):
|
|
2926
|
+
"""
|
|
2927
|
+
Return self/value.
|
|
2928
|
+
"""
|
|
2929
|
+
pass
|
|
2930
|
+
|
|
2931
|
+
|
|
2932
|
+
def _repr_latex_(self, /):
|
|
2933
|
+
"""
|
|
2934
|
+
|
|
2935
|
+
"""
|
|
1061
2936
|
pass
|
|
1062
2937
|
|
|
2938
|
+
|
|
2939
|
+
left: typing.Any
|
|
2940
|
+
right: typing.Any
|
|
1063
2941
|
def set_latex(self, /, latex=None):
|
|
1064
2942
|
"""
|
|
1065
2943
|
Set the LaTeX representation of the object.
|
|
@@ -1072,13 +2950,14 @@ class ModOp:
|
|
|
1072
2950
|
|
|
1073
2951
|
|
|
1074
2952
|
@typing.final
|
|
1075
|
-
class ModelingError:
|
|
2953
|
+
class ModelingError(BaseException):
|
|
1076
2954
|
"""
|
|
1077
2955
|
Common base class for all non-exit exceptions.
|
|
1078
2956
|
"""
|
|
1079
|
-
def
|
|
2957
|
+
def __new__(cls):
|
|
1080
2958
|
pass
|
|
1081
2959
|
|
|
2960
|
+
args: typing.Any
|
|
1082
2961
|
def with_traceback():
|
|
1083
2962
|
"""
|
|
1084
2963
|
Exception.with_traceback(tb) --
|
|
@@ -1104,9 +2983,107 @@ class MulOp:
|
|
|
1104
2983
|
instantiation method is by calling the multiplication operation on other
|
|
1105
2984
|
expressions.
|
|
1106
2985
|
"""
|
|
1107
|
-
def
|
|
2986
|
+
def __new__(cls):
|
|
2987
|
+
pass
|
|
2988
|
+
|
|
2989
|
+
def __add__(self, value, /):
|
|
2990
|
+
"""
|
|
2991
|
+
Return self+value.
|
|
2992
|
+
"""
|
|
2993
|
+
pass
|
|
2994
|
+
|
|
2995
|
+
|
|
2996
|
+
def __mod__(self, value, /):
|
|
2997
|
+
"""
|
|
2998
|
+
Return self%value.
|
|
2999
|
+
"""
|
|
3000
|
+
pass
|
|
3001
|
+
|
|
3002
|
+
|
|
3003
|
+
def __mul__(self, value, /):
|
|
3004
|
+
"""
|
|
3005
|
+
Return self*value.
|
|
3006
|
+
"""
|
|
3007
|
+
pass
|
|
3008
|
+
|
|
3009
|
+
|
|
3010
|
+
def __neg__(self, /):
|
|
3011
|
+
"""
|
|
3012
|
+
-self
|
|
3013
|
+
"""
|
|
3014
|
+
pass
|
|
3015
|
+
|
|
3016
|
+
|
|
3017
|
+
def __pow__(self, value, mod=None, /):
|
|
3018
|
+
"""
|
|
3019
|
+
Return pow(self, value, mod).
|
|
3020
|
+
"""
|
|
3021
|
+
pass
|
|
3022
|
+
|
|
3023
|
+
|
|
3024
|
+
def __radd__(self, value, /):
|
|
3025
|
+
"""
|
|
3026
|
+
Return value+self.
|
|
3027
|
+
"""
|
|
3028
|
+
pass
|
|
3029
|
+
|
|
3030
|
+
|
|
3031
|
+
def __rmod__(self, value, /):
|
|
3032
|
+
"""
|
|
3033
|
+
Return value%self.
|
|
3034
|
+
"""
|
|
3035
|
+
pass
|
|
3036
|
+
|
|
3037
|
+
|
|
3038
|
+
def __rmul__(self, value, /):
|
|
3039
|
+
"""
|
|
3040
|
+
Return value*self.
|
|
3041
|
+
"""
|
|
3042
|
+
pass
|
|
3043
|
+
|
|
3044
|
+
|
|
3045
|
+
def __rpow__(self, value, mod=None, /):
|
|
3046
|
+
"""
|
|
3047
|
+
Return pow(value, self, mod).
|
|
3048
|
+
"""
|
|
3049
|
+
pass
|
|
3050
|
+
|
|
3051
|
+
|
|
3052
|
+
def __rsub__(self, value, /):
|
|
3053
|
+
"""
|
|
3054
|
+
Return value-self.
|
|
3055
|
+
"""
|
|
3056
|
+
pass
|
|
3057
|
+
|
|
3058
|
+
|
|
3059
|
+
def __rtruediv__(self, value, /):
|
|
3060
|
+
"""
|
|
3061
|
+
Return value/self.
|
|
3062
|
+
"""
|
|
3063
|
+
pass
|
|
3064
|
+
|
|
3065
|
+
|
|
3066
|
+
def __sub__(self, value, /):
|
|
3067
|
+
"""
|
|
3068
|
+
Return self-value.
|
|
3069
|
+
"""
|
|
3070
|
+
pass
|
|
3071
|
+
|
|
3072
|
+
|
|
3073
|
+
def __truediv__(self, value, /):
|
|
3074
|
+
"""
|
|
3075
|
+
Return self/value.
|
|
3076
|
+
"""
|
|
3077
|
+
pass
|
|
3078
|
+
|
|
3079
|
+
|
|
3080
|
+
def _repr_latex_(self, /):
|
|
3081
|
+
"""
|
|
3082
|
+
|
|
3083
|
+
"""
|
|
1108
3084
|
pass
|
|
1109
3085
|
|
|
3086
|
+
|
|
1110
3087
|
def set_latex(self, /, latex=None):
|
|
1111
3088
|
"""
|
|
1112
3089
|
Set the LaTeX representation of the object.
|
|
@@ -1118,6 +3095,7 @@ class MulOp:
|
|
|
1118
3095
|
pass
|
|
1119
3096
|
|
|
1120
3097
|
|
|
3098
|
+
terms: typing.Any
|
|
1121
3099
|
@typing.final
|
|
1122
3100
|
class NotEqualOp:
|
|
1123
3101
|
"""
|
|
@@ -1133,9 +3111,60 @@ class NotEqualOp:
|
|
|
1133
3111
|
Note:
|
|
1134
3112
|
The NotEqualOp class does not have a constructor.
|
|
1135
3113
|
"""
|
|
1136
|
-
def
|
|
3114
|
+
def __new__(cls):
|
|
3115
|
+
pass
|
|
3116
|
+
|
|
3117
|
+
def __and__(self, value, /):
|
|
3118
|
+
"""
|
|
3119
|
+
Return self&value.
|
|
3120
|
+
"""
|
|
3121
|
+
pass
|
|
3122
|
+
|
|
3123
|
+
|
|
3124
|
+
def __or__(self, value, /):
|
|
3125
|
+
"""
|
|
3126
|
+
Return self|value.
|
|
3127
|
+
"""
|
|
3128
|
+
pass
|
|
3129
|
+
|
|
3130
|
+
|
|
3131
|
+
def __rand__(self, value, /):
|
|
3132
|
+
"""
|
|
3133
|
+
Return value&self.
|
|
3134
|
+
"""
|
|
3135
|
+
pass
|
|
3136
|
+
|
|
3137
|
+
|
|
3138
|
+
def __ror__(self, value, /):
|
|
3139
|
+
"""
|
|
3140
|
+
Return value|self.
|
|
3141
|
+
"""
|
|
1137
3142
|
pass
|
|
1138
3143
|
|
|
3144
|
+
|
|
3145
|
+
def __rxor__(self, value, /):
|
|
3146
|
+
"""
|
|
3147
|
+
Return value^self.
|
|
3148
|
+
"""
|
|
3149
|
+
pass
|
|
3150
|
+
|
|
3151
|
+
|
|
3152
|
+
def __xor__(self, value, /):
|
|
3153
|
+
"""
|
|
3154
|
+
Return self^value.
|
|
3155
|
+
"""
|
|
3156
|
+
pass
|
|
3157
|
+
|
|
3158
|
+
|
|
3159
|
+
def _repr_latex_(self, /):
|
|
3160
|
+
"""
|
|
3161
|
+
|
|
3162
|
+
"""
|
|
3163
|
+
pass
|
|
3164
|
+
|
|
3165
|
+
|
|
3166
|
+
left: typing.Any
|
|
3167
|
+
right: typing.Any
|
|
1139
3168
|
def set_latex(self, /, latex=None):
|
|
1140
3169
|
"""
|
|
1141
3170
|
Set the LaTeX representation of the object.
|
|
@@ -1180,9 +3209,109 @@ class NumberLit:
|
|
|
1180
3209
|
>>> assert v.value == 1.23
|
|
1181
3210
|
>>> assert v.dtype == jm.DataType.FLOAT
|
|
1182
3211
|
"""
|
|
1183
|
-
def
|
|
3212
|
+
def __new__(cls, value):
|
|
3213
|
+
pass
|
|
3214
|
+
|
|
3215
|
+
def __add__(self, value, /):
|
|
3216
|
+
"""
|
|
3217
|
+
Return self+value.
|
|
3218
|
+
"""
|
|
3219
|
+
pass
|
|
3220
|
+
|
|
3221
|
+
|
|
3222
|
+
def __mod__(self, value, /):
|
|
3223
|
+
"""
|
|
3224
|
+
Return self%value.
|
|
3225
|
+
"""
|
|
3226
|
+
pass
|
|
3227
|
+
|
|
3228
|
+
|
|
3229
|
+
def __mul__(self, value, /):
|
|
3230
|
+
"""
|
|
3231
|
+
Return self*value.
|
|
3232
|
+
"""
|
|
3233
|
+
pass
|
|
3234
|
+
|
|
3235
|
+
|
|
3236
|
+
def __neg__(self, /):
|
|
3237
|
+
"""
|
|
3238
|
+
-self
|
|
3239
|
+
"""
|
|
3240
|
+
pass
|
|
3241
|
+
|
|
3242
|
+
|
|
3243
|
+
def __pow__(self, value, mod=None, /):
|
|
3244
|
+
"""
|
|
3245
|
+
Return pow(self, value, mod).
|
|
3246
|
+
"""
|
|
3247
|
+
pass
|
|
3248
|
+
|
|
3249
|
+
|
|
3250
|
+
def __radd__(self, value, /):
|
|
3251
|
+
"""
|
|
3252
|
+
Return value+self.
|
|
3253
|
+
"""
|
|
3254
|
+
pass
|
|
3255
|
+
|
|
3256
|
+
|
|
3257
|
+
def __rmod__(self, value, /):
|
|
3258
|
+
"""
|
|
3259
|
+
Return value%self.
|
|
3260
|
+
"""
|
|
3261
|
+
pass
|
|
3262
|
+
|
|
3263
|
+
|
|
3264
|
+
def __rmul__(self, value, /):
|
|
3265
|
+
"""
|
|
3266
|
+
Return value*self.
|
|
3267
|
+
"""
|
|
3268
|
+
pass
|
|
3269
|
+
|
|
3270
|
+
|
|
3271
|
+
def __rpow__(self, value, mod=None, /):
|
|
3272
|
+
"""
|
|
3273
|
+
Return pow(value, self, mod).
|
|
3274
|
+
"""
|
|
3275
|
+
pass
|
|
3276
|
+
|
|
3277
|
+
|
|
3278
|
+
def __rsub__(self, value, /):
|
|
3279
|
+
"""
|
|
3280
|
+
Return value-self.
|
|
3281
|
+
"""
|
|
3282
|
+
pass
|
|
3283
|
+
|
|
3284
|
+
|
|
3285
|
+
def __rtruediv__(self, value, /):
|
|
3286
|
+
"""
|
|
3287
|
+
Return value/self.
|
|
3288
|
+
"""
|
|
3289
|
+
pass
|
|
3290
|
+
|
|
3291
|
+
|
|
3292
|
+
def __sub__(self, value, /):
|
|
3293
|
+
"""
|
|
3294
|
+
Return self-value.
|
|
3295
|
+
"""
|
|
3296
|
+
pass
|
|
3297
|
+
|
|
3298
|
+
|
|
3299
|
+
def __truediv__(self, value, /):
|
|
3300
|
+
"""
|
|
3301
|
+
Return self/value.
|
|
3302
|
+
"""
|
|
3303
|
+
pass
|
|
3304
|
+
|
|
3305
|
+
|
|
3306
|
+
def _repr_latex_(self, /):
|
|
3307
|
+
"""
|
|
3308
|
+
|
|
3309
|
+
"""
|
|
1184
3310
|
pass
|
|
1185
3311
|
|
|
3312
|
+
|
|
3313
|
+
dtype: typing.Any
|
|
3314
|
+
value: typing.Any
|
|
1186
3315
|
@typing.final
|
|
1187
3316
|
class OrOp:
|
|
1188
3317
|
"""
|
|
@@ -1198,9 +3327,58 @@ class OrOp:
|
|
|
1198
3327
|
Note:
|
|
1199
3328
|
The OrOp class does not have a constructor.
|
|
1200
3329
|
"""
|
|
1201
|
-
def
|
|
3330
|
+
def __new__(cls):
|
|
3331
|
+
pass
|
|
3332
|
+
|
|
3333
|
+
def __and__(self, value, /):
|
|
3334
|
+
"""
|
|
3335
|
+
Return self&value.
|
|
3336
|
+
"""
|
|
3337
|
+
pass
|
|
3338
|
+
|
|
3339
|
+
|
|
3340
|
+
def __or__(self, value, /):
|
|
3341
|
+
"""
|
|
3342
|
+
Return self|value.
|
|
3343
|
+
"""
|
|
3344
|
+
pass
|
|
3345
|
+
|
|
3346
|
+
|
|
3347
|
+
def __rand__(self, value, /):
|
|
3348
|
+
"""
|
|
3349
|
+
Return value&self.
|
|
3350
|
+
"""
|
|
3351
|
+
pass
|
|
3352
|
+
|
|
3353
|
+
|
|
3354
|
+
def __ror__(self, value, /):
|
|
3355
|
+
"""
|
|
3356
|
+
Return value|self.
|
|
3357
|
+
"""
|
|
3358
|
+
pass
|
|
3359
|
+
|
|
3360
|
+
|
|
3361
|
+
def __rxor__(self, value, /):
|
|
3362
|
+
"""
|
|
3363
|
+
Return value^self.
|
|
3364
|
+
"""
|
|
1202
3365
|
pass
|
|
1203
3366
|
|
|
3367
|
+
|
|
3368
|
+
def __xor__(self, value, /):
|
|
3369
|
+
"""
|
|
3370
|
+
Return self^value.
|
|
3371
|
+
"""
|
|
3372
|
+
pass
|
|
3373
|
+
|
|
3374
|
+
|
|
3375
|
+
def _repr_latex_(self, /):
|
|
3376
|
+
"""
|
|
3377
|
+
|
|
3378
|
+
"""
|
|
3379
|
+
pass
|
|
3380
|
+
|
|
3381
|
+
|
|
1204
3382
|
def set_latex(self, /, latex=None):
|
|
1205
3383
|
"""
|
|
1206
3384
|
Set the LaTeX representation of the object.
|
|
@@ -1212,6 +3390,7 @@ class OrOp:
|
|
|
1212
3390
|
pass
|
|
1213
3391
|
|
|
1214
3392
|
|
|
3393
|
+
terms: typing.Any
|
|
1215
3394
|
@typing.final
|
|
1216
3395
|
class Placeholder:
|
|
1217
3396
|
"""
|
|
@@ -1257,9 +3436,115 @@ class Placeholder:
|
|
|
1257
3436
|
>>> a[123]
|
|
1258
3437
|
Placeholder(name='a', ndim=2)[NumberLit(value=123)]
|
|
1259
3438
|
"""
|
|
1260
|
-
def
|
|
3439
|
+
def __new__(cls, name: str, *, ndim=0, latex=None, description=None):
|
|
3440
|
+
pass
|
|
3441
|
+
|
|
3442
|
+
def __add__(self, value, /):
|
|
3443
|
+
"""
|
|
3444
|
+
Return self+value.
|
|
3445
|
+
"""
|
|
3446
|
+
pass
|
|
3447
|
+
|
|
3448
|
+
|
|
3449
|
+
def __getitem__(self, key, /):
|
|
3450
|
+
"""
|
|
3451
|
+
Return self[key].
|
|
3452
|
+
"""
|
|
3453
|
+
pass
|
|
3454
|
+
|
|
3455
|
+
|
|
3456
|
+
def __mod__(self, value, /):
|
|
3457
|
+
"""
|
|
3458
|
+
Return self%value.
|
|
3459
|
+
"""
|
|
3460
|
+
pass
|
|
3461
|
+
|
|
3462
|
+
|
|
3463
|
+
def __mul__(self, value, /):
|
|
3464
|
+
"""
|
|
3465
|
+
Return self*value.
|
|
3466
|
+
"""
|
|
3467
|
+
pass
|
|
3468
|
+
|
|
3469
|
+
|
|
3470
|
+
def __neg__(self, /):
|
|
3471
|
+
"""
|
|
3472
|
+
-self
|
|
3473
|
+
"""
|
|
3474
|
+
pass
|
|
3475
|
+
|
|
3476
|
+
|
|
3477
|
+
def __pow__(self, value, mod=None, /):
|
|
3478
|
+
"""
|
|
3479
|
+
Return pow(self, value, mod).
|
|
3480
|
+
"""
|
|
3481
|
+
pass
|
|
3482
|
+
|
|
3483
|
+
|
|
3484
|
+
def __radd__(self, value, /):
|
|
3485
|
+
"""
|
|
3486
|
+
Return value+self.
|
|
3487
|
+
"""
|
|
3488
|
+
pass
|
|
3489
|
+
|
|
3490
|
+
|
|
3491
|
+
def __rmod__(self, value, /):
|
|
3492
|
+
"""
|
|
3493
|
+
Return value%self.
|
|
3494
|
+
"""
|
|
3495
|
+
pass
|
|
3496
|
+
|
|
3497
|
+
|
|
3498
|
+
def __rmul__(self, value, /):
|
|
3499
|
+
"""
|
|
3500
|
+
Return value*self.
|
|
3501
|
+
"""
|
|
3502
|
+
pass
|
|
3503
|
+
|
|
3504
|
+
|
|
3505
|
+
def __rpow__(self, value, mod=None, /):
|
|
3506
|
+
"""
|
|
3507
|
+
Return pow(value, self, mod).
|
|
3508
|
+
"""
|
|
3509
|
+
pass
|
|
3510
|
+
|
|
3511
|
+
|
|
3512
|
+
def __rsub__(self, value, /):
|
|
3513
|
+
"""
|
|
3514
|
+
Return value-self.
|
|
3515
|
+
"""
|
|
3516
|
+
pass
|
|
3517
|
+
|
|
3518
|
+
|
|
3519
|
+
def __rtruediv__(self, value, /):
|
|
3520
|
+
"""
|
|
3521
|
+
Return value/self.
|
|
3522
|
+
"""
|
|
3523
|
+
pass
|
|
3524
|
+
|
|
3525
|
+
|
|
3526
|
+
def __sub__(self, value, /):
|
|
3527
|
+
"""
|
|
3528
|
+
Return self-value.
|
|
3529
|
+
"""
|
|
3530
|
+
pass
|
|
3531
|
+
|
|
3532
|
+
|
|
3533
|
+
def __truediv__(self, value, /):
|
|
3534
|
+
"""
|
|
3535
|
+
Return self/value.
|
|
3536
|
+
"""
|
|
3537
|
+
pass
|
|
3538
|
+
|
|
3539
|
+
|
|
3540
|
+
def _repr_latex_(self, /):
|
|
3541
|
+
"""
|
|
3542
|
+
|
|
3543
|
+
"""
|
|
1261
3544
|
pass
|
|
1262
3545
|
|
|
3546
|
+
|
|
3547
|
+
description: str
|
|
1263
3548
|
def len_at(self, /, axis, *, latex=None, description=None):
|
|
1264
3549
|
"""
|
|
1265
3550
|
|
|
@@ -1267,6 +3552,8 @@ class Placeholder:
|
|
|
1267
3552
|
pass
|
|
1268
3553
|
|
|
1269
3554
|
|
|
3555
|
+
name: str
|
|
3556
|
+
ndim: int
|
|
1270
3557
|
def set_latex(self, /, latex=None):
|
|
1271
3558
|
"""
|
|
1272
3559
|
Set the LaTeX representation of the object.
|
|
@@ -1278,6 +3565,7 @@ class Placeholder:
|
|
|
1278
3565
|
pass
|
|
1279
3566
|
|
|
1280
3567
|
|
|
3568
|
+
shape: tuple
|
|
1281
3569
|
@typing.final
|
|
1282
3570
|
class PowOp:
|
|
1283
3571
|
"""
|
|
@@ -1293,9 +3581,109 @@ class PowOp:
|
|
|
1293
3581
|
Note:
|
|
1294
3582
|
The PowOp class does not have a constructor.
|
|
1295
3583
|
"""
|
|
1296
|
-
def
|
|
3584
|
+
def __new__(cls):
|
|
3585
|
+
pass
|
|
3586
|
+
|
|
3587
|
+
def __add__(self, value, /):
|
|
3588
|
+
"""
|
|
3589
|
+
Return self+value.
|
|
3590
|
+
"""
|
|
3591
|
+
pass
|
|
3592
|
+
|
|
3593
|
+
|
|
3594
|
+
def __mod__(self, value, /):
|
|
3595
|
+
"""
|
|
3596
|
+
Return self%value.
|
|
3597
|
+
"""
|
|
3598
|
+
pass
|
|
3599
|
+
|
|
3600
|
+
|
|
3601
|
+
def __mul__(self, value, /):
|
|
3602
|
+
"""
|
|
3603
|
+
Return self*value.
|
|
3604
|
+
"""
|
|
3605
|
+
pass
|
|
3606
|
+
|
|
3607
|
+
|
|
3608
|
+
def __neg__(self, /):
|
|
3609
|
+
"""
|
|
3610
|
+
-self
|
|
3611
|
+
"""
|
|
3612
|
+
pass
|
|
3613
|
+
|
|
3614
|
+
|
|
3615
|
+
def __pow__(self, value, mod=None, /):
|
|
3616
|
+
"""
|
|
3617
|
+
Return pow(self, value, mod).
|
|
3618
|
+
"""
|
|
1297
3619
|
pass
|
|
1298
3620
|
|
|
3621
|
+
|
|
3622
|
+
def __radd__(self, value, /):
|
|
3623
|
+
"""
|
|
3624
|
+
Return value+self.
|
|
3625
|
+
"""
|
|
3626
|
+
pass
|
|
3627
|
+
|
|
3628
|
+
|
|
3629
|
+
def __rmod__(self, value, /):
|
|
3630
|
+
"""
|
|
3631
|
+
Return value%self.
|
|
3632
|
+
"""
|
|
3633
|
+
pass
|
|
3634
|
+
|
|
3635
|
+
|
|
3636
|
+
def __rmul__(self, value, /):
|
|
3637
|
+
"""
|
|
3638
|
+
Return value*self.
|
|
3639
|
+
"""
|
|
3640
|
+
pass
|
|
3641
|
+
|
|
3642
|
+
|
|
3643
|
+
def __rpow__(self, value, mod=None, /):
|
|
3644
|
+
"""
|
|
3645
|
+
Return pow(value, self, mod).
|
|
3646
|
+
"""
|
|
3647
|
+
pass
|
|
3648
|
+
|
|
3649
|
+
|
|
3650
|
+
def __rsub__(self, value, /):
|
|
3651
|
+
"""
|
|
3652
|
+
Return value-self.
|
|
3653
|
+
"""
|
|
3654
|
+
pass
|
|
3655
|
+
|
|
3656
|
+
|
|
3657
|
+
def __rtruediv__(self, value, /):
|
|
3658
|
+
"""
|
|
3659
|
+
Return value/self.
|
|
3660
|
+
"""
|
|
3661
|
+
pass
|
|
3662
|
+
|
|
3663
|
+
|
|
3664
|
+
def __sub__(self, value, /):
|
|
3665
|
+
"""
|
|
3666
|
+
Return self-value.
|
|
3667
|
+
"""
|
|
3668
|
+
pass
|
|
3669
|
+
|
|
3670
|
+
|
|
3671
|
+
def __truediv__(self, value, /):
|
|
3672
|
+
"""
|
|
3673
|
+
Return self/value.
|
|
3674
|
+
"""
|
|
3675
|
+
pass
|
|
3676
|
+
|
|
3677
|
+
|
|
3678
|
+
def _repr_latex_(self, /):
|
|
3679
|
+
"""
|
|
3680
|
+
|
|
3681
|
+
"""
|
|
3682
|
+
pass
|
|
3683
|
+
|
|
3684
|
+
|
|
3685
|
+
base: typing.Any
|
|
3686
|
+
exponent: typing.Any
|
|
1299
3687
|
def set_latex(self, /, latex=None):
|
|
1300
3688
|
"""
|
|
1301
3689
|
Set the LaTeX representation of the object.
|
|
@@ -1327,17 +3715,31 @@ class Problem:
|
|
|
1327
3715
|
name (str): A name of the optimization problem.
|
|
1328
3716
|
sense (optional): Sense of the optimization problem. Defaults to :obj:`ProblemSense.MINIMIZE`.
|
|
1329
3717
|
"""
|
|
1330
|
-
def
|
|
3718
|
+
def __new__(cls, name: str, *, sense=Ellipsis):
|
|
3719
|
+
pass
|
|
3720
|
+
|
|
3721
|
+
def _repr_latex_(self, /):
|
|
3722
|
+
"""
|
|
3723
|
+
|
|
3724
|
+
"""
|
|
1331
3725
|
pass
|
|
1332
3726
|
|
|
3727
|
+
|
|
3728
|
+
constraints: typing.Any
|
|
3729
|
+
custom_penalty_terms: typing.Any
|
|
3730
|
+
name: str
|
|
3731
|
+
objective: typing.Any
|
|
3732
|
+
sense: typing.Any
|
|
1333
3733
|
@typing.final
|
|
1334
3734
|
class ProblemSense:
|
|
1335
3735
|
"""
|
|
1336
3736
|
An optimization sense
|
|
1337
3737
|
"""
|
|
1338
|
-
def
|
|
3738
|
+
def __new__(cls):
|
|
1339
3739
|
pass
|
|
1340
3740
|
|
|
3741
|
+
MAXIMIZE: ProblemSense
|
|
3742
|
+
MINIMIZE: ProblemSense
|
|
1341
3743
|
@typing.final
|
|
1342
3744
|
class ProdOp:
|
|
1343
3745
|
"""
|
|
@@ -1354,9 +3756,110 @@ class ProdOp:
|
|
|
1354
3756
|
Note:
|
|
1355
3757
|
The ProdOp class does not have a constructor.
|
|
1356
3758
|
"""
|
|
1357
|
-
def
|
|
3759
|
+
def __new__(cls):
|
|
3760
|
+
pass
|
|
3761
|
+
|
|
3762
|
+
def __add__(self, value, /):
|
|
3763
|
+
"""
|
|
3764
|
+
Return self+value.
|
|
3765
|
+
"""
|
|
3766
|
+
pass
|
|
3767
|
+
|
|
3768
|
+
|
|
3769
|
+
def __mod__(self, value, /):
|
|
3770
|
+
"""
|
|
3771
|
+
Return self%value.
|
|
3772
|
+
"""
|
|
3773
|
+
pass
|
|
3774
|
+
|
|
3775
|
+
|
|
3776
|
+
def __mul__(self, value, /):
|
|
3777
|
+
"""
|
|
3778
|
+
Return self*value.
|
|
3779
|
+
"""
|
|
3780
|
+
pass
|
|
3781
|
+
|
|
3782
|
+
|
|
3783
|
+
def __neg__(self, /):
|
|
3784
|
+
"""
|
|
3785
|
+
-self
|
|
3786
|
+
"""
|
|
3787
|
+
pass
|
|
3788
|
+
|
|
3789
|
+
|
|
3790
|
+
def __pow__(self, value, mod=None, /):
|
|
3791
|
+
"""
|
|
3792
|
+
Return pow(self, value, mod).
|
|
3793
|
+
"""
|
|
3794
|
+
pass
|
|
3795
|
+
|
|
3796
|
+
|
|
3797
|
+
def __radd__(self, value, /):
|
|
3798
|
+
"""
|
|
3799
|
+
Return value+self.
|
|
3800
|
+
"""
|
|
3801
|
+
pass
|
|
3802
|
+
|
|
3803
|
+
|
|
3804
|
+
def __rmod__(self, value, /):
|
|
3805
|
+
"""
|
|
3806
|
+
Return value%self.
|
|
3807
|
+
"""
|
|
3808
|
+
pass
|
|
3809
|
+
|
|
3810
|
+
|
|
3811
|
+
def __rmul__(self, value, /):
|
|
3812
|
+
"""
|
|
3813
|
+
Return value*self.
|
|
3814
|
+
"""
|
|
3815
|
+
pass
|
|
3816
|
+
|
|
3817
|
+
|
|
3818
|
+
def __rpow__(self, value, mod=None, /):
|
|
3819
|
+
"""
|
|
3820
|
+
Return pow(value, self, mod).
|
|
3821
|
+
"""
|
|
3822
|
+
pass
|
|
3823
|
+
|
|
3824
|
+
|
|
3825
|
+
def __rsub__(self, value, /):
|
|
3826
|
+
"""
|
|
3827
|
+
Return value-self.
|
|
3828
|
+
"""
|
|
3829
|
+
pass
|
|
3830
|
+
|
|
3831
|
+
|
|
3832
|
+
def __rtruediv__(self, value, /):
|
|
3833
|
+
"""
|
|
3834
|
+
Return value/self.
|
|
3835
|
+
"""
|
|
3836
|
+
pass
|
|
3837
|
+
|
|
3838
|
+
|
|
3839
|
+
def __sub__(self, value, /):
|
|
3840
|
+
"""
|
|
3841
|
+
Return self-value.
|
|
3842
|
+
"""
|
|
1358
3843
|
pass
|
|
1359
3844
|
|
|
3845
|
+
|
|
3846
|
+
def __truediv__(self, value, /):
|
|
3847
|
+
"""
|
|
3848
|
+
Return self/value.
|
|
3849
|
+
"""
|
|
3850
|
+
pass
|
|
3851
|
+
|
|
3852
|
+
|
|
3853
|
+
def _repr_latex_(self, /):
|
|
3854
|
+
"""
|
|
3855
|
+
|
|
3856
|
+
"""
|
|
3857
|
+
pass
|
|
3858
|
+
|
|
3859
|
+
|
|
3860
|
+
condition: typing.Any
|
|
3861
|
+
index: typing.Any
|
|
3862
|
+
operand: typing.Any
|
|
1360
3863
|
def set_latex(self, /, latex=None):
|
|
1361
3864
|
"""
|
|
1362
3865
|
Set the LaTeX representation of the object.
|
|
@@ -1369,13 +3872,14 @@ class ProdOp:
|
|
|
1369
3872
|
|
|
1370
3873
|
|
|
1371
3874
|
@typing.final
|
|
1372
|
-
class ProtobufDeserializationError:
|
|
3875
|
+
class ProtobufDeserializationError(BaseException):
|
|
1373
3876
|
"""
|
|
1374
3877
|
Common base class for all non-exit exceptions.
|
|
1375
3878
|
"""
|
|
1376
|
-
def
|
|
3879
|
+
def __new__(cls):
|
|
1377
3880
|
pass
|
|
1378
3881
|
|
|
3882
|
+
args: typing.Any
|
|
1379
3883
|
def with_traceback():
|
|
1380
3884
|
"""
|
|
1381
3885
|
Exception.with_traceback(tb) --
|
|
@@ -1385,13 +3889,14 @@ class ProtobufDeserializationError:
|
|
|
1385
3889
|
|
|
1386
3890
|
|
|
1387
3891
|
@typing.final
|
|
1388
|
-
class ProtobufSerializationError:
|
|
3892
|
+
class ProtobufSerializationError(BaseException):
|
|
1389
3893
|
"""
|
|
1390
3894
|
Common base class for all non-exit exceptions.
|
|
1391
3895
|
"""
|
|
1392
|
-
def
|
|
3896
|
+
def __new__(cls):
|
|
1393
3897
|
pass
|
|
1394
3898
|
|
|
3899
|
+
args: typing.Any
|
|
1395
3900
|
def with_traceback():
|
|
1396
3901
|
"""
|
|
1397
3902
|
Exception.with_traceback(tb) --
|
|
@@ -1415,9 +3920,11 @@ class Range:
|
|
|
1415
3920
|
Note:
|
|
1416
3921
|
This class does not contain any decision variable.
|
|
1417
3922
|
"""
|
|
1418
|
-
def
|
|
3923
|
+
def __new__(cls):
|
|
1419
3924
|
pass
|
|
1420
3925
|
|
|
3926
|
+
end: typing.Any
|
|
3927
|
+
start: typing.Any
|
|
1421
3928
|
@typing.final
|
|
1422
3929
|
class Record:
|
|
1423
3930
|
"""
|
|
@@ -1432,7 +3939,7 @@ class Record:
|
|
|
1432
3939
|
|
|
1433
3940
|
As an example, consider the following solutions:
|
|
1434
3941
|
|
|
1435
|
-
```
|
|
3942
|
+
```
|
|
1436
3943
|
{
|
|
1437
3944
|
"x": [np.array([[0.0, 1.0, 0.0], [2.0, 0.0, 3.0]]), np.array([[1.0, 0.0, 0.0], [2.0, 3.0, 4.0]])],
|
|
1438
3945
|
"y": [np.array([0.0, 0.0, 1.0]), np.array([0.0, 1.0, 0.0])]
|
|
@@ -1441,7 +3948,7 @@ class Record:
|
|
|
1441
3948
|
|
|
1442
3949
|
This is a dense solution. The corresponding sparse solution is as follows:
|
|
1443
3950
|
|
|
1444
|
-
```
|
|
3951
|
+
```
|
|
1445
3952
|
{
|
|
1446
3953
|
"x": [(([0, 1, 1], [1, 0, 2]), [1.0, 2.0, 3.0], (2, 3)), (([0, 1, 1, 1], [0, 0, 1, 2]), [1.0, 2.0, 3.0, 4.0], (2, 3))],
|
|
1447
3954
|
"y": [(([2],), [1.0], (3,)), (([1],), [1.0], (3,))]
|
|
@@ -1452,9 +3959,10 @@ class Record:
|
|
|
1452
3959
|
solution (Union[Dict[str, List[numpy.ndarray]], Dict[str, List[Tuple[List[int], List[float], Tuple[int, ...]]]]]): A solution.
|
|
1453
3960
|
num_occurrences (List[int]): A list of the number of occurrences in which the solution is observed.
|
|
1454
3961
|
"""
|
|
1455
|
-
def
|
|
3962
|
+
def __new__(cls, solution, num_occurrences):
|
|
1456
3963
|
pass
|
|
1457
3964
|
|
|
3965
|
+
@staticmethod
|
|
1458
3966
|
def from_dict(dict):
|
|
1459
3967
|
"""
|
|
1460
3968
|
Create a Record object from the given dict.
|
|
@@ -1470,6 +3978,7 @@ class Record:
|
|
|
1470
3978
|
pass
|
|
1471
3979
|
|
|
1472
3980
|
|
|
3981
|
+
@staticmethod
|
|
1473
3982
|
def from_json(json):
|
|
1474
3983
|
"""
|
|
1475
3984
|
Create a Record object from the JSON string.
|
|
@@ -1503,6 +4012,8 @@ class Record:
|
|
|
1503
4012
|
pass
|
|
1504
4013
|
|
|
1505
4014
|
|
|
4015
|
+
num_occurrences: typing.Any
|
|
4016
|
+
solution: typing.Any
|
|
1506
4017
|
def to_dense(self, /):
|
|
1507
4018
|
"""
|
|
1508
4019
|
Return a Record object whose solution is dense.
|
|
@@ -1572,9 +4083,10 @@ class SampleSet:
|
|
|
1572
4083
|
fetch_result (float, optional): Time to fetch result. Defaults to None.
|
|
1573
4084
|
deserialize_solution (float, optional): Time to deserialize json object. Defaults to None.
|
|
1574
4085
|
"""
|
|
1575
|
-
def
|
|
4086
|
+
def __new__(cls, record, evaluation, measuring_time, metadata=None):
|
|
1576
4087
|
pass
|
|
1577
4088
|
|
|
4089
|
+
evaluation: typing.Any
|
|
1578
4090
|
def feasible(self, /, rtol=1e-05, atol=1e-08):
|
|
1579
4091
|
"""
|
|
1580
4092
|
Return a Sampleset with only feasible solutions.
|
|
@@ -1594,6 +4106,7 @@ class SampleSet:
|
|
|
1594
4106
|
pass
|
|
1595
4107
|
|
|
1596
4108
|
|
|
4109
|
+
@staticmethod
|
|
1597
4110
|
def from_dict(dict):
|
|
1598
4111
|
"""
|
|
1599
4112
|
Create a SampleSet object from the given dict.
|
|
@@ -1609,6 +4122,7 @@ class SampleSet:
|
|
|
1609
4122
|
pass
|
|
1610
4123
|
|
|
1611
4124
|
|
|
4125
|
+
@staticmethod
|
|
1612
4126
|
def from_json(json):
|
|
1613
4127
|
"""
|
|
1614
4128
|
Create a SampleSet object from the JSON string.
|
|
@@ -1690,6 +4204,9 @@ class SampleSet:
|
|
|
1690
4204
|
pass
|
|
1691
4205
|
|
|
1692
4206
|
|
|
4207
|
+
measuring_time: typing.Any
|
|
4208
|
+
metadata: typing.Any
|
|
4209
|
+
record: typing.Any
|
|
1693
4210
|
def to_dense(self, /):
|
|
1694
4211
|
"""
|
|
1695
4212
|
Return a Sampleset whose record is converted into a dense solution format.
|
|
@@ -1790,9 +4307,90 @@ class SemiContinuousVar:
|
|
|
1790
4307
|
>>> x[123]
|
|
1791
4308
|
SemiContinuousVar(name='x', shape=[NumberLit(value=124)], lower_bound=NumberLit(value=0), upper_bound=NumberLit(value=2))[NumberLit(value=123)]
|
|
1792
4309
|
"""
|
|
1793
|
-
def
|
|
4310
|
+
def __new__(cls, name: str, *, shape=None, lower_bound, upper_bound, latex=None, description=None):
|
|
4311
|
+
pass
|
|
4312
|
+
|
|
4313
|
+
def __add__(self, value, /):
|
|
4314
|
+
"""
|
|
4315
|
+
Return self+value.
|
|
4316
|
+
"""
|
|
4317
|
+
pass
|
|
4318
|
+
|
|
4319
|
+
|
|
4320
|
+
def __getitem__(self, key, /):
|
|
4321
|
+
"""
|
|
4322
|
+
Return self[key].
|
|
4323
|
+
"""
|
|
4324
|
+
pass
|
|
4325
|
+
|
|
4326
|
+
|
|
4327
|
+
def __mul__(self, value, /):
|
|
4328
|
+
"""
|
|
4329
|
+
Return self*value.
|
|
4330
|
+
"""
|
|
4331
|
+
pass
|
|
4332
|
+
|
|
4333
|
+
|
|
4334
|
+
def __neg__(self, /):
|
|
4335
|
+
"""
|
|
4336
|
+
-self
|
|
4337
|
+
"""
|
|
4338
|
+
pass
|
|
4339
|
+
|
|
4340
|
+
|
|
4341
|
+
def __pow__(self, value, mod=None, /):
|
|
4342
|
+
"""
|
|
4343
|
+
Return pow(self, value, mod).
|
|
4344
|
+
"""
|
|
4345
|
+
pass
|
|
4346
|
+
|
|
4347
|
+
|
|
4348
|
+
def __radd__(self, value, /):
|
|
4349
|
+
"""
|
|
4350
|
+
Return value+self.
|
|
4351
|
+
"""
|
|
4352
|
+
pass
|
|
4353
|
+
|
|
4354
|
+
|
|
4355
|
+
def __rmul__(self, value, /):
|
|
4356
|
+
"""
|
|
4357
|
+
Return value*self.
|
|
4358
|
+
"""
|
|
1794
4359
|
pass
|
|
1795
4360
|
|
|
4361
|
+
|
|
4362
|
+
def __rpow__(self, value, mod=None, /):
|
|
4363
|
+
"""
|
|
4364
|
+
Return pow(value, self, mod).
|
|
4365
|
+
"""
|
|
4366
|
+
pass
|
|
4367
|
+
|
|
4368
|
+
|
|
4369
|
+
def __rsub__(self, value, /):
|
|
4370
|
+
"""
|
|
4371
|
+
Return value-self.
|
|
4372
|
+
"""
|
|
4373
|
+
pass
|
|
4374
|
+
|
|
4375
|
+
|
|
4376
|
+
def __sub__(self, value, /):
|
|
4377
|
+
"""
|
|
4378
|
+
Return self-value.
|
|
4379
|
+
"""
|
|
4380
|
+
pass
|
|
4381
|
+
|
|
4382
|
+
|
|
4383
|
+
def _repr_latex_(self, /):
|
|
4384
|
+
"""
|
|
4385
|
+
|
|
4386
|
+
"""
|
|
4387
|
+
pass
|
|
4388
|
+
|
|
4389
|
+
|
|
4390
|
+
description: str
|
|
4391
|
+
lower_bound: typing.Any
|
|
4392
|
+
name: str
|
|
4393
|
+
ndim: int
|
|
1796
4394
|
def set_latex(self, /, latex=None):
|
|
1797
4395
|
"""
|
|
1798
4396
|
Set the LaTeX representation of the object.
|
|
@@ -1804,6 +4402,8 @@ class SemiContinuousVar:
|
|
|
1804
4402
|
pass
|
|
1805
4403
|
|
|
1806
4404
|
|
|
4405
|
+
shape: tuple
|
|
4406
|
+
upper_bound: typing.Any
|
|
1807
4407
|
@typing.final
|
|
1808
4408
|
class SemiIntegerVar:
|
|
1809
4409
|
"""
|
|
@@ -1860,9 +4460,90 @@ class SemiIntegerVar:
|
|
|
1860
4460
|
>>> x[123]
|
|
1861
4461
|
SemiIntegerVar(name='x', shape=[NumberLit(value=124)], lower_bound=NumberLit(value=0), upper_bound=NumberLit(value=2))[NumberLit(value=123)]
|
|
1862
4462
|
"""
|
|
1863
|
-
def
|
|
4463
|
+
def __new__(cls, name: str, *, shape=None, lower_bound, upper_bound, latex=None, description=None):
|
|
4464
|
+
pass
|
|
4465
|
+
|
|
4466
|
+
def __add__(self, value, /):
|
|
4467
|
+
"""
|
|
4468
|
+
Return self+value.
|
|
4469
|
+
"""
|
|
4470
|
+
pass
|
|
4471
|
+
|
|
4472
|
+
|
|
4473
|
+
def __getitem__(self, key, /):
|
|
4474
|
+
"""
|
|
4475
|
+
Return self[key].
|
|
4476
|
+
"""
|
|
4477
|
+
pass
|
|
4478
|
+
|
|
4479
|
+
|
|
4480
|
+
def __mul__(self, value, /):
|
|
4481
|
+
"""
|
|
4482
|
+
Return self*value.
|
|
4483
|
+
"""
|
|
4484
|
+
pass
|
|
4485
|
+
|
|
4486
|
+
|
|
4487
|
+
def __neg__(self, /):
|
|
4488
|
+
"""
|
|
4489
|
+
-self
|
|
4490
|
+
"""
|
|
4491
|
+
pass
|
|
4492
|
+
|
|
4493
|
+
|
|
4494
|
+
def __pow__(self, value, mod=None, /):
|
|
4495
|
+
"""
|
|
4496
|
+
Return pow(self, value, mod).
|
|
4497
|
+
"""
|
|
4498
|
+
pass
|
|
4499
|
+
|
|
4500
|
+
|
|
4501
|
+
def __radd__(self, value, /):
|
|
4502
|
+
"""
|
|
4503
|
+
Return value+self.
|
|
4504
|
+
"""
|
|
4505
|
+
pass
|
|
4506
|
+
|
|
4507
|
+
|
|
4508
|
+
def __rmul__(self, value, /):
|
|
4509
|
+
"""
|
|
4510
|
+
Return value*self.
|
|
4511
|
+
"""
|
|
4512
|
+
pass
|
|
4513
|
+
|
|
4514
|
+
|
|
4515
|
+
def __rpow__(self, value, mod=None, /):
|
|
4516
|
+
"""
|
|
4517
|
+
Return pow(value, self, mod).
|
|
4518
|
+
"""
|
|
4519
|
+
pass
|
|
4520
|
+
|
|
4521
|
+
|
|
4522
|
+
def __rsub__(self, value, /):
|
|
4523
|
+
"""
|
|
4524
|
+
Return value-self.
|
|
4525
|
+
"""
|
|
4526
|
+
pass
|
|
4527
|
+
|
|
4528
|
+
|
|
4529
|
+
def __sub__(self, value, /):
|
|
4530
|
+
"""
|
|
4531
|
+
Return self-value.
|
|
4532
|
+
"""
|
|
4533
|
+
pass
|
|
4534
|
+
|
|
4535
|
+
|
|
4536
|
+
def _repr_latex_(self, /):
|
|
4537
|
+
"""
|
|
4538
|
+
|
|
4539
|
+
"""
|
|
1864
4540
|
pass
|
|
1865
4541
|
|
|
4542
|
+
|
|
4543
|
+
description: str
|
|
4544
|
+
lower_bound: typing.Any
|
|
4545
|
+
name: str
|
|
4546
|
+
ndim: int
|
|
1866
4547
|
def set_latex(self, /, latex=None):
|
|
1867
4548
|
"""
|
|
1868
4549
|
Set the LaTeX representation of the object.
|
|
@@ -1874,6 +4555,8 @@ class SemiIntegerVar:
|
|
|
1874
4555
|
pass
|
|
1875
4556
|
|
|
1876
4557
|
|
|
4558
|
+
shape: tuple
|
|
4559
|
+
upper_bound: typing.Any
|
|
1877
4560
|
@typing.final
|
|
1878
4561
|
class SolvingTime:
|
|
1879
4562
|
"""
|
|
@@ -1884,9 +4567,10 @@ class SolvingTime:
|
|
|
1884
4567
|
solve (float, optional): Time to solve the problem. Defaults to None.
|
|
1885
4568
|
postprocess (float, optional): Time to postprocess the problem. Defaults to None.
|
|
1886
4569
|
"""
|
|
1887
|
-
def
|
|
4570
|
+
def __new__(cls, preprocess=None, solve=None, postprocess=None):
|
|
1888
4571
|
pass
|
|
1889
4572
|
|
|
4573
|
+
@staticmethod
|
|
1890
4574
|
def from_dict(dict):
|
|
1891
4575
|
"""
|
|
1892
4576
|
Create a SolvingTime object from the given dict.
|
|
@@ -1902,6 +4586,7 @@ class SolvingTime:
|
|
|
1902
4586
|
pass
|
|
1903
4587
|
|
|
1904
4588
|
|
|
4589
|
+
@staticmethod
|
|
1905
4590
|
def from_json(json):
|
|
1906
4591
|
"""
|
|
1907
4592
|
Create a SolvingTime object from the JSON string.
|
|
@@ -1915,6 +4600,9 @@ class SolvingTime:
|
|
|
1915
4600
|
pass
|
|
1916
4601
|
|
|
1917
4602
|
|
|
4603
|
+
postprocess: typing.Any
|
|
4604
|
+
preprocess: typing.Any
|
|
4605
|
+
solve: typing.Any
|
|
1918
4606
|
def to_dict(self, /):
|
|
1919
4607
|
"""
|
|
1920
4608
|
Convert into a dict.
|
|
@@ -1953,9 +4641,114 @@ class Subscript:
|
|
|
1953
4641
|
Note:
|
|
1954
4642
|
The Subscript class does not have a constructor.
|
|
1955
4643
|
"""
|
|
1956
|
-
def
|
|
4644
|
+
def __new__(cls):
|
|
4645
|
+
pass
|
|
4646
|
+
|
|
4647
|
+
def __add__(self, value, /):
|
|
4648
|
+
"""
|
|
4649
|
+
Return self+value.
|
|
4650
|
+
"""
|
|
4651
|
+
pass
|
|
4652
|
+
|
|
4653
|
+
|
|
4654
|
+
def __getitem__(self, key, /):
|
|
4655
|
+
"""
|
|
4656
|
+
Return self[key].
|
|
4657
|
+
"""
|
|
4658
|
+
pass
|
|
4659
|
+
|
|
4660
|
+
|
|
4661
|
+
def __mod__(self, value, /):
|
|
4662
|
+
"""
|
|
4663
|
+
Return self%value.
|
|
4664
|
+
"""
|
|
4665
|
+
pass
|
|
4666
|
+
|
|
4667
|
+
|
|
4668
|
+
def __mul__(self, value, /):
|
|
4669
|
+
"""
|
|
4670
|
+
Return self*value.
|
|
4671
|
+
"""
|
|
4672
|
+
pass
|
|
4673
|
+
|
|
4674
|
+
|
|
4675
|
+
def __neg__(self, /):
|
|
4676
|
+
"""
|
|
4677
|
+
-self
|
|
4678
|
+
"""
|
|
4679
|
+
pass
|
|
4680
|
+
|
|
4681
|
+
|
|
4682
|
+
def __pow__(self, value, mod=None, /):
|
|
4683
|
+
"""
|
|
4684
|
+
Return pow(self, value, mod).
|
|
4685
|
+
"""
|
|
4686
|
+
pass
|
|
4687
|
+
|
|
4688
|
+
|
|
4689
|
+
def __radd__(self, value, /):
|
|
4690
|
+
"""
|
|
4691
|
+
Return value+self.
|
|
4692
|
+
"""
|
|
4693
|
+
pass
|
|
4694
|
+
|
|
4695
|
+
|
|
4696
|
+
def __rmod__(self, value, /):
|
|
4697
|
+
"""
|
|
4698
|
+
Return value%self.
|
|
4699
|
+
"""
|
|
4700
|
+
pass
|
|
4701
|
+
|
|
4702
|
+
|
|
4703
|
+
def __rmul__(self, value, /):
|
|
4704
|
+
"""
|
|
4705
|
+
Return value*self.
|
|
4706
|
+
"""
|
|
4707
|
+
pass
|
|
4708
|
+
|
|
4709
|
+
|
|
4710
|
+
def __rpow__(self, value, mod=None, /):
|
|
4711
|
+
"""
|
|
4712
|
+
Return pow(value, self, mod).
|
|
4713
|
+
"""
|
|
4714
|
+
pass
|
|
4715
|
+
|
|
4716
|
+
|
|
4717
|
+
def __rsub__(self, value, /):
|
|
4718
|
+
"""
|
|
4719
|
+
Return value-self.
|
|
4720
|
+
"""
|
|
4721
|
+
pass
|
|
4722
|
+
|
|
4723
|
+
|
|
4724
|
+
def __rtruediv__(self, value, /):
|
|
4725
|
+
"""
|
|
4726
|
+
Return value/self.
|
|
4727
|
+
"""
|
|
4728
|
+
pass
|
|
4729
|
+
|
|
4730
|
+
|
|
4731
|
+
def __sub__(self, value, /):
|
|
4732
|
+
"""
|
|
4733
|
+
Return self-value.
|
|
4734
|
+
"""
|
|
4735
|
+
pass
|
|
4736
|
+
|
|
4737
|
+
|
|
4738
|
+
def __truediv__(self, value, /):
|
|
4739
|
+
"""
|
|
4740
|
+
Return self/value.
|
|
4741
|
+
"""
|
|
4742
|
+
pass
|
|
4743
|
+
|
|
4744
|
+
|
|
4745
|
+
def _repr_latex_(self, /):
|
|
4746
|
+
"""
|
|
4747
|
+
|
|
4748
|
+
"""
|
|
1957
4749
|
pass
|
|
1958
4750
|
|
|
4751
|
+
|
|
1959
4752
|
def len_at(self, /, axis, *, latex=None, description=None):
|
|
1960
4753
|
"""
|
|
1961
4754
|
|
|
@@ -1963,6 +4756,10 @@ class Subscript:
|
|
|
1963
4756
|
pass
|
|
1964
4757
|
|
|
1965
4758
|
|
|
4759
|
+
ndim: int
|
|
4760
|
+
shape: tuple
|
|
4761
|
+
subscripts: typing.Any
|
|
4762
|
+
variable: typing.Any
|
|
1966
4763
|
@typing.final
|
|
1967
4764
|
class SumOp:
|
|
1968
4765
|
"""
|
|
@@ -1979,9 +4776,110 @@ class SumOp:
|
|
|
1979
4776
|
Note:
|
|
1980
4777
|
The SumOp class does not have a constructor.
|
|
1981
4778
|
"""
|
|
1982
|
-
def
|
|
4779
|
+
def __new__(cls):
|
|
4780
|
+
pass
|
|
4781
|
+
|
|
4782
|
+
def __add__(self, value, /):
|
|
4783
|
+
"""
|
|
4784
|
+
Return self+value.
|
|
4785
|
+
"""
|
|
4786
|
+
pass
|
|
4787
|
+
|
|
4788
|
+
|
|
4789
|
+
def __mod__(self, value, /):
|
|
4790
|
+
"""
|
|
4791
|
+
Return self%value.
|
|
4792
|
+
"""
|
|
4793
|
+
pass
|
|
4794
|
+
|
|
4795
|
+
|
|
4796
|
+
def __mul__(self, value, /):
|
|
4797
|
+
"""
|
|
4798
|
+
Return self*value.
|
|
4799
|
+
"""
|
|
4800
|
+
pass
|
|
4801
|
+
|
|
4802
|
+
|
|
4803
|
+
def __neg__(self, /):
|
|
4804
|
+
"""
|
|
4805
|
+
-self
|
|
4806
|
+
"""
|
|
4807
|
+
pass
|
|
4808
|
+
|
|
4809
|
+
|
|
4810
|
+
def __pow__(self, value, mod=None, /):
|
|
4811
|
+
"""
|
|
4812
|
+
Return pow(self, value, mod).
|
|
4813
|
+
"""
|
|
4814
|
+
pass
|
|
4815
|
+
|
|
4816
|
+
|
|
4817
|
+
def __radd__(self, value, /):
|
|
4818
|
+
"""
|
|
4819
|
+
Return value+self.
|
|
4820
|
+
"""
|
|
4821
|
+
pass
|
|
4822
|
+
|
|
4823
|
+
|
|
4824
|
+
def __rmod__(self, value, /):
|
|
4825
|
+
"""
|
|
4826
|
+
Return value%self.
|
|
4827
|
+
"""
|
|
4828
|
+
pass
|
|
4829
|
+
|
|
4830
|
+
|
|
4831
|
+
def __rmul__(self, value, /):
|
|
4832
|
+
"""
|
|
4833
|
+
Return value*self.
|
|
4834
|
+
"""
|
|
4835
|
+
pass
|
|
4836
|
+
|
|
4837
|
+
|
|
4838
|
+
def __rpow__(self, value, mod=None, /):
|
|
4839
|
+
"""
|
|
4840
|
+
Return pow(value, self, mod).
|
|
4841
|
+
"""
|
|
4842
|
+
pass
|
|
4843
|
+
|
|
4844
|
+
|
|
4845
|
+
def __rsub__(self, value, /):
|
|
4846
|
+
"""
|
|
4847
|
+
Return value-self.
|
|
4848
|
+
"""
|
|
4849
|
+
pass
|
|
4850
|
+
|
|
4851
|
+
|
|
4852
|
+
def __rtruediv__(self, value, /):
|
|
4853
|
+
"""
|
|
4854
|
+
Return value/self.
|
|
4855
|
+
"""
|
|
4856
|
+
pass
|
|
4857
|
+
|
|
4858
|
+
|
|
4859
|
+
def __sub__(self, value, /):
|
|
4860
|
+
"""
|
|
4861
|
+
Return self-value.
|
|
4862
|
+
"""
|
|
4863
|
+
pass
|
|
4864
|
+
|
|
4865
|
+
|
|
4866
|
+
def __truediv__(self, value, /):
|
|
4867
|
+
"""
|
|
4868
|
+
Return self/value.
|
|
4869
|
+
"""
|
|
4870
|
+
pass
|
|
4871
|
+
|
|
4872
|
+
|
|
4873
|
+
def _repr_latex_(self, /):
|
|
4874
|
+
"""
|
|
4875
|
+
|
|
4876
|
+
"""
|
|
1983
4877
|
pass
|
|
1984
4878
|
|
|
4879
|
+
|
|
4880
|
+
condition: typing.Any
|
|
4881
|
+
index: typing.Any
|
|
4882
|
+
operand: typing.Any
|
|
1985
4883
|
def set_latex(self, /, latex=None):
|
|
1986
4884
|
"""
|
|
1987
4885
|
Set the LaTeX representation of the object.
|
|
@@ -2005,9 +4903,13 @@ class SystemTime:
|
|
|
2005
4903
|
fetch_result (float, optional): Time to fetch result. Defaults to None.
|
|
2006
4904
|
deserialize_solution (float, optional): Time to deserialize json object. Defaults to None.
|
|
2007
4905
|
"""
|
|
2008
|
-
def
|
|
4906
|
+
def __new__(cls, post_problem_and_instance_data=None, request_queue=None, fetch_problem_and_instance_data=None, fetch_result=None, deserialize_solution=None):
|
|
2009
4907
|
pass
|
|
2010
4908
|
|
|
4909
|
+
deserialize_solution: typing.Any
|
|
4910
|
+
fetch_problem_and_instance_data: typing.Any
|
|
4911
|
+
fetch_result: typing.Any
|
|
4912
|
+
@staticmethod
|
|
2011
4913
|
def from_dict(dict):
|
|
2012
4914
|
"""
|
|
2013
4915
|
Create a SystemTime object from the given dict.
|
|
@@ -2023,6 +4925,7 @@ class SystemTime:
|
|
|
2023
4925
|
pass
|
|
2024
4926
|
|
|
2025
4927
|
|
|
4928
|
+
@staticmethod
|
|
2026
4929
|
def from_json(json):
|
|
2027
4930
|
"""
|
|
2028
4931
|
Create a SystemTime object from the JSON string.
|
|
@@ -2036,6 +4939,8 @@ class SystemTime:
|
|
|
2036
4939
|
pass
|
|
2037
4940
|
|
|
2038
4941
|
|
|
4942
|
+
post_problem_and_instance_data: typing.Any
|
|
4943
|
+
request_queue: typing.Any
|
|
2039
4944
|
def to_dict(self, /):
|
|
2040
4945
|
"""
|
|
2041
4946
|
Convert into a dict.
|
|
@@ -2074,9 +4979,58 @@ class XorOp:
|
|
|
2074
4979
|
Note:
|
|
2075
4980
|
The XorOp class does not have a constructor.
|
|
2076
4981
|
"""
|
|
2077
|
-
def
|
|
4982
|
+
def __new__(cls):
|
|
4983
|
+
pass
|
|
4984
|
+
|
|
4985
|
+
def __and__(self, value, /):
|
|
4986
|
+
"""
|
|
4987
|
+
Return self&value.
|
|
4988
|
+
"""
|
|
4989
|
+
pass
|
|
4990
|
+
|
|
4991
|
+
|
|
4992
|
+
def __or__(self, value, /):
|
|
4993
|
+
"""
|
|
4994
|
+
Return self|value.
|
|
4995
|
+
"""
|
|
4996
|
+
pass
|
|
4997
|
+
|
|
4998
|
+
|
|
4999
|
+
def __rand__(self, value, /):
|
|
5000
|
+
"""
|
|
5001
|
+
Return value&self.
|
|
5002
|
+
"""
|
|
5003
|
+
pass
|
|
5004
|
+
|
|
5005
|
+
|
|
5006
|
+
def __ror__(self, value, /):
|
|
5007
|
+
"""
|
|
5008
|
+
Return value|self.
|
|
5009
|
+
"""
|
|
5010
|
+
pass
|
|
5011
|
+
|
|
5012
|
+
|
|
5013
|
+
def __rxor__(self, value, /):
|
|
5014
|
+
"""
|
|
5015
|
+
Return value^self.
|
|
5016
|
+
"""
|
|
5017
|
+
pass
|
|
5018
|
+
|
|
5019
|
+
|
|
5020
|
+
def __xor__(self, value, /):
|
|
5021
|
+
"""
|
|
5022
|
+
Return self^value.
|
|
5023
|
+
"""
|
|
5024
|
+
pass
|
|
5025
|
+
|
|
5026
|
+
|
|
5027
|
+
def _repr_latex_(self, /):
|
|
5028
|
+
"""
|
|
5029
|
+
|
|
5030
|
+
"""
|
|
2078
5031
|
pass
|
|
2079
5032
|
|
|
5033
|
+
|
|
2080
5034
|
def set_latex(self, /, latex=None):
|
|
2081
5035
|
"""
|
|
2082
5036
|
Set the LaTeX representation of the object.
|
|
@@ -2088,6 +5042,7 @@ class XorOp:
|
|
|
2088
5042
|
pass
|
|
2089
5043
|
|
|
2090
5044
|
|
|
5045
|
+
terms: typing.Any
|
|
2091
5046
|
def abs(operand):
|
|
2092
5047
|
"""
|
|
2093
5048
|
Create the `AbsOp` object from the expression.
|
|
@@ -2134,13 +5089,29 @@ def ceil(operand):
|
|
|
2134
5089
|
pass
|
|
2135
5090
|
|
|
2136
5091
|
|
|
2137
|
-
def
|
|
5092
|
+
def concatenate(sample_sets):
|
|
5093
|
+
"""
|
|
5094
|
+
Concatenate some SampleSet objects into a single SampleSet object.
|
|
5095
|
+
|
|
5096
|
+
Args:
|
|
5097
|
+
sample_sets (list[SampleSet]): A list of SampleSet objects.
|
|
5098
|
+
|
|
5099
|
+
Returns:
|
|
5100
|
+
SampleSet: A SampleSet object which is concatenated from the given SampleSet objects.
|
|
5101
|
+
|
|
5102
|
+
Note:
|
|
5103
|
+
This function will be deprecated in v1.1.0.
|
|
5104
|
+
"""
|
|
5105
|
+
pass
|
|
5106
|
+
|
|
5107
|
+
|
|
5108
|
+
def extract_nodes(obj, class_or_tuple):
|
|
2138
5109
|
"""
|
|
2139
5110
|
Extract all nodes from the given object.
|
|
2140
5111
|
|
|
2141
5112
|
Args:
|
|
2142
5113
|
obj: An expression defined by JijModeling's module, or a `Problem`, `Constraint`, `CustomPenaltyTerm`, or a list of forall object.
|
|
2143
|
-
|
|
5114
|
+
class_or_tuple: A type or tuple of types of nodes to be extracted.
|
|
2144
5115
|
|
|
2145
5116
|
Returns:
|
|
2146
5117
|
list: A list of nodes whose type is `type`.
|
|
@@ -2148,7 +5119,7 @@ def extract_nodes(obj, type):
|
|
|
2148
5119
|
Examples:
|
|
2149
5120
|
Extract all placeholders from the given expression.
|
|
2150
5121
|
|
|
2151
|
-
```
|
|
5122
|
+
```
|
|
2152
5123
|
>>> from itertools import zip_longest
|
|
2153
5124
|
>>> import jijmodeling as jm
|
|
2154
5125
|
>>> a = jm.Placeholder("a")
|
|
@@ -2157,6 +5128,22 @@ def extract_nodes(obj, type):
|
|
|
2157
5128
|
>>> for actual, expect in zip_longest(jm.extract_nodes(expr, jm.Placeholder), [a, b]):
|
|
2158
5129
|
>>> assert jm.is_same(actual, expect)
|
|
2159
5130
|
```
|
|
5131
|
+
|
|
5132
|
+
Extract all BinaryVar objects and Placeholder objects from the given expression.
|
|
5133
|
+
|
|
5134
|
+
```
|
|
5135
|
+
>>> from itertools import zip_longest
|
|
5136
|
+
>>> import jijmodeling as jm
|
|
5137
|
+
>>> a = jm.Placeholder("a")
|
|
5138
|
+
>>> b = jm.Placeholder("b")
|
|
5139
|
+
>>> x = jm.BinaryVar("x")
|
|
5140
|
+
>>> y = jm.ContinuousVar("y", lower_bound=0, upper_bound=1)
|
|
5141
|
+
>>> expr = a * x + b * y + 123
|
|
5142
|
+
>>> actual = jm.extract_nodes(expr, (jm.BinaryVar, jm.Placeholder))
|
|
5143
|
+
>>> expect = [a, x, b, y]
|
|
5144
|
+
>>> for actual, expect in zip_longest(actual, expect):
|
|
5145
|
+
>>> assert jm.is_same(actual, expect)
|
|
5146
|
+
```
|
|
2160
5147
|
"""
|
|
2161
5148
|
pass
|
|
2162
5149
|
|
|
@@ -2179,7 +5166,7 @@ def extract_variables(obj):
|
|
|
2179
5166
|
Examples:
|
|
2180
5167
|
Extract all variables from a problem without duplication.
|
|
2181
5168
|
|
|
2182
|
-
```
|
|
5169
|
+
```
|
|
2183
5170
|
>>> n = jm.Placeholder("n")
|
|
2184
5171
|
>>> i = jm.Element("i", belong_to=n)
|
|
2185
5172
|
>>> x = jm.BinaryVar("x", shape=[10])
|
|
@@ -2242,7 +5229,7 @@ def is_dynamic_degree(expr):
|
|
|
2242
5229
|
Examples:
|
|
2243
5230
|
Check if the degree of the following expression is determined dynamically.
|
|
2244
5231
|
|
|
2245
|
-
```
|
|
5232
|
+
```
|
|
2246
5233
|
a = jm.Placeholder("a", ndim=1)
|
|
2247
5234
|
i = jm.Element("i", belong_to=a)
|
|
2248
5235
|
x = jm.BinaryVar("x", shape=(a.len_at(0),))
|
|
@@ -2416,7 +5403,7 @@ def max(*operands):
|
|
|
2416
5403
|
Examples:
|
|
2417
5404
|
Create the `MaxOp` object whose operands are three placeholders.
|
|
2418
5405
|
|
|
2419
|
-
```
|
|
5406
|
+
```
|
|
2420
5407
|
>>> import jijmodeling as jm
|
|
2421
5408
|
>>> a = jm.Placeholder("a")
|
|
2422
5409
|
>>> b = jm.Placeholder("b")
|
|
@@ -2443,7 +5430,7 @@ def min(*operands):
|
|
|
2443
5430
|
Examples:
|
|
2444
5431
|
Create the `MinOp` object whose operands are three placeholders.
|
|
2445
5432
|
|
|
2446
|
-
```
|
|
5433
|
+
```
|
|
2447
5434
|
>>> import jijmodeling as jm
|
|
2448
5435
|
>>> a = jm.Placeholder("a")
|
|
2449
5436
|
>>> b = jm.Placeholder("b")
|
|
@@ -2509,7 +5496,7 @@ def replace(expr, replacer):
|
|
|
2509
5496
|
Examples:
|
|
2510
5497
|
Replace a placeholder with a binary variable.
|
|
2511
5498
|
|
|
2512
|
-
```
|
|
5499
|
+
```
|
|
2513
5500
|
>>> import jijmodeling as jm
|
|
2514
5501
|
>>> ph = jm.Placeholder("placeholder")
|
|
2515
5502
|
>>> var = jm.BinaryVar("x")
|
|
@@ -2519,7 +5506,7 @@ def replace(expr, replacer):
|
|
|
2519
5506
|
|
|
2520
5507
|
Replace a subscripted variable with a binary variable if it is a placeholder.
|
|
2521
5508
|
|
|
2522
|
-
```
|
|
5509
|
+
```
|
|
2523
5510
|
>>> import jijmodeling as jm
|
|
2524
5511
|
>>> ph = jm.Placeholder("ph", ndim=2)
|
|
2525
5512
|
>>> x = jm.BinaryVar("x", shape=(1000, 1000))
|