PyDiffGame 0.1.0__tar.gz → 0.1.1__tar.gz
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.
- {PyDiffGame-0.1.0/src/PyDiffGame.egg-info → PyDiffGame-0.1.1}/PKG-INFO +24 -24
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/README.md +23 -23
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/pyproject.toml +1 -1
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/setup.py +1 -1
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1/src/PyDiffGame.egg-info}/PKG-INFO +24 -24
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/LICENSE +0 -0
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/setup.cfg +0 -0
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/src/PyDiffGame/ContinuousPyDiffGame.py +0 -0
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/src/PyDiffGame/DiscretePyDiffGame.py +0 -0
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/src/PyDiffGame/LQR.py +0 -0
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/src/PyDiffGame/Objective.py +0 -0
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/src/PyDiffGame/PyDiffGame.py +0 -0
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/src/PyDiffGame/PyDiffGameLQRComparison.py +0 -0
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/src/PyDiffGame/__init__.py +0 -0
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/src/PyDiffGame.egg-info/SOURCES.txt +0 -0
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/src/PyDiffGame.egg-info/dependency_links.txt +0 -0
- {PyDiffGame-0.1.0 → PyDiffGame-0.1.1}/src/PyDiffGame.egg-info/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: PyDiffGame
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.1
|
|
4
4
|
Summary: PyDiffGame is a Python implementation of a Nash Equilibrium solution to Differential Games, based on a reduction of Game Hamilton-Bellman-Jacobi (GHJB) equations to Game Algebraic and Differential Riccati equations, associated with Multi-Objective Dynamical Control Systems
|
|
5
5
|
Home-page: https://shaykricheli.com/PyDiffGame/
|
|
6
6
|
Author: Dr. Aviran Sadon, Joshua Shay Kricheli and Prof. Gera Weiss
|
|
@@ -47,11 +47,11 @@ If you use this work, please cite our paper:
|
|
|
47
47
|
doi={10.1109/MED51440.2021.9480269}}
|
|
48
48
|
```
|
|
49
49
|
|
|
50
|
-
#
|
|
50
|
+
# Installation
|
|
51
51
|
|
|
52
|
-
To
|
|
52
|
+
To install this package run this from the command prompt:
|
|
53
53
|
```
|
|
54
|
-
|
|
54
|
+
pip install PyDiffGame
|
|
55
55
|
```
|
|
56
56
|
|
|
57
57
|
The package was tested for Python >= 3.10, along with the listed packages versions in [`requirments.txt`](https://github.com/krichelj/PyDiffGame/blob/master/requirements.txt)
|
|
@@ -61,34 +61,34 @@ The package was tested for Python >= 3.10, along with the listed packages versio
|
|
|
61
61
|
The package defines an abstract class [`PyDiffGame.py`](https://github.com/krichelj/PyDiffGame/blob/master/src/PyDiffGame/PyDiffGame.py). An object of this class represents an instance of differential game.
|
|
62
62
|
The input parameters to instantiate a `PyDiffGame` object are:
|
|
63
63
|
|
|
64
|
-
* `A` : `np.array` of shape
|
|
64
|
+
* `A` : `np.array` of shape $(n,n)$
|
|
65
65
|
>System dynamics matrix
|
|
66
|
-
* `B` : `np.array` of shape( $n,\sum_{i=}
|
|
66
|
+
* `B` : `np.array` of shape( $n,\sum_{i=1}^N m_i$ ), optional
|
|
67
67
|
>Input matrix for all virtual control objectives
|
|
68
|
-
* `Bs` : `Sequence` of `np.array` objects of len
|
|
68
|
+
* `Bs` : `Sequence` of `np.array` objects of len $(N)$, each array $B_i$ of shape $(n,m_i)$, optional
|
|
69
69
|
>Input matrices for each virtual control objective
|
|
70
|
-
* `Qs` : `Sequence` of `np.array` objects of len
|
|
70
|
+
* `Qs` : `Sequence` of `np.array` objects of len $(N)$, each array $Q_i$ of shape $(n,n)$, optional
|
|
71
71
|
>State weight matrices for each virtual control objective
|
|
72
|
-
* `Rs` : `Sequence` of `np.array` objects of len
|
|
72
|
+
* `Rs` : `Sequence` of `np.array` objects of len $(N)$, each array $R_i$ of shape $(m_i,m_i)$, optional
|
|
73
73
|
>Input weight matrices for each virtual control objective
|
|
74
|
-
* `Ms` : `Sequence` of `np.array` objects of len
|
|
74
|
+
* `Ms` : `Sequence` of `np.array` objects of len $(N)$, each array $M_i$ of shape $(m_i,m)$, optional
|
|
75
75
|
>Decomposition matrices for each virtual control objective
|
|
76
|
-
* `objectives` : `Sequence` of `Objective` objects of len
|
|
76
|
+
* `objectives` : `Sequence` of `Objective` objects of len $(N)$, each $O_i$ specifying $Q_i, R_i$ and $M_i$, optional
|
|
77
77
|
>Desired objectives for the game
|
|
78
|
-
* `x_0` : `np.array` of len
|
|
78
|
+
* `x_0` : `np.array` of len $(n)$, optional
|
|
79
79
|
>Initial state vector
|
|
80
|
-
* `x_T` : `np.array` of len
|
|
80
|
+
* `x_T` : `np.array` of len $(n)$, optional
|
|
81
81
|
>Final state vector, in case of signal tracking
|
|
82
82
|
* `T_f` : positive `float`, optional
|
|
83
83
|
>System dynamics horizon. Should be given in the case of finite horizon
|
|
84
|
-
* `P_f` : `list` of `np.array` objects of len
|
|
84
|
+
* `P_f` : `list` of `np.array` objects of len $(N)$, each array $P_{f_i}$ of shape $(n,n)$, optional, default = uncoupled solution of `scipy's solve_are`
|
|
85
85
|
>
|
|
86
86
|
>Final condition for the Riccati equation array. Should be given in the case of finite horizon
|
|
87
|
-
* `state_variables_names` : `Sequence` of `str` objects of len
|
|
87
|
+
* `state_variables_names` : `Sequence` of `str` objects of len $(N)$, optional
|
|
88
88
|
>The state variables' names to display when plotting
|
|
89
89
|
* `show_legend` : `boolean`, optional
|
|
90
90
|
>Indicates whether to display a legend in the plots
|
|
91
|
-
* `state_variables_names` : `Sequence` of `str` objects of len
|
|
91
|
+
* `state_variables_names` : `Sequence` of `str` objects of len $(n)$, optional
|
|
92
92
|
>The state variables' names to display
|
|
93
93
|
* `epsilon_x` : `float` in the interval $(0,1)$, optional
|
|
94
94
|
>Numerical convergence threshold for the state vector of the system
|
|
@@ -109,7 +109,7 @@ Consider the following system of masses and springs:
|
|
|
109
109
|
|
|
110
110
|
|
|
111
111
|
<p align="center">
|
|
112
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/two_masses_tikz.png" width="797" height="130"/>
|
|
112
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/two_masses_tikz.png" width="797" height="130"/>
|
|
113
113
|
</p>
|
|
114
114
|
|
|
115
115
|
The performance of the system under the use of the suggested method is compared with that of a Linear Quadratic Regulator (LQR). For that purpose, class named [`PyDiffGameLQRComparison`](https://github.com/krichelj/PyDiffGame/blob/master/src/PyDiffGame/PyDiffGameLQRComparison.py) is defined. A comparison of a system should subclass this class.
|
|
@@ -250,8 +250,8 @@ Refer
|
|
|
250
250
|
This will result in the following plot that compares the two systems performance for a differential game vs an LQR:
|
|
251
251
|
|
|
252
252
|
<p align="center">
|
|
253
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/2-players_large_1.png" width="400" height="300"/>
|
|
254
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/LQR_large_1.png" width="400" height="300"/>
|
|
253
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/2-players_large_1.png" width="400" height="300"/>
|
|
254
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/LQR_large_1.png" width="400" height="300"/>
|
|
255
255
|
</p>
|
|
256
256
|
|
|
257
257
|
|
|
@@ -264,8 +264,8 @@ qs = [[500, 5000]]
|
|
|
264
264
|
we have:
|
|
265
265
|
|
|
266
266
|
<p align="center">
|
|
267
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/2-players_large_2.png" width="400" height="300"/>
|
|
268
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/LQR_large_2.png" width="400" height="300"/>
|
|
267
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/2-players_large_2.png" width="400" height="300"/>
|
|
268
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/LQR_large_2.png" width="400" height="300"/>
|
|
269
269
|
</p>
|
|
270
270
|
|
|
271
271
|
|
|
@@ -276,20 +276,20 @@ This research was also supported by The Israeli Smart Transportation Research Ce
|
|
|
276
276
|
|
|
277
277
|
<p align="center">
|
|
278
278
|
<a href="https://istrc.net.technion.ac.il/">
|
|
279
|
-
<img src="images/Logo_ISTRC_Green_English.png" width="180" alt=""/>
|
|
279
|
+
<img src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/images/Logo_ISTRC_Green_English.png" width="180" alt=""/>
|
|
280
280
|
</a>
|
|
281
281
|
 
|
|
282
282
|
 
|
|
283
283
|
 
|
|
284
284
|
 
|
|
285
285
|
<a href="https://in.bgu.ac.il/en/Pages/default.aspx">
|
|
286
|
-
<img src="images/BGU-logo-round.png" width="150" alt=""/>
|
|
286
|
+
<img src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/images/BGU-logo-round.png" width="150" alt=""/>
|
|
287
287
|
</a>
|
|
288
288
|
 
|
|
289
289
|
 
|
|
290
290
|
 
|
|
291
291
|
 
|
|
292
292
|
<a href="https://in.bgu.ac.il/en/robotics/Pages/default.aspx">
|
|
293
|
-
<img src="images/logo_abc.png" width="180" alt=""/>
|
|
293
|
+
<img src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/images/logo_abc.png" width="180" alt=""/>
|
|
294
294
|
</a>
|
|
295
295
|
</p>
|
|
@@ -31,11 +31,11 @@ If you use this work, please cite our paper:
|
|
|
31
31
|
doi={10.1109/MED51440.2021.9480269}}
|
|
32
32
|
```
|
|
33
33
|
|
|
34
|
-
#
|
|
34
|
+
# Installation
|
|
35
35
|
|
|
36
|
-
To
|
|
36
|
+
To install this package run this from the command prompt:
|
|
37
37
|
```
|
|
38
|
-
|
|
38
|
+
pip install PyDiffGame
|
|
39
39
|
```
|
|
40
40
|
|
|
41
41
|
The package was tested for Python >= 3.10, along with the listed packages versions in [`requirments.txt`](https://github.com/krichelj/PyDiffGame/blob/master/requirements.txt)
|
|
@@ -45,34 +45,34 @@ The package was tested for Python >= 3.10, along with the listed packages versio
|
|
|
45
45
|
The package defines an abstract class [`PyDiffGame.py`](https://github.com/krichelj/PyDiffGame/blob/master/src/PyDiffGame/PyDiffGame.py). An object of this class represents an instance of differential game.
|
|
46
46
|
The input parameters to instantiate a `PyDiffGame` object are:
|
|
47
47
|
|
|
48
|
-
* `A` : `np.array` of shape
|
|
48
|
+
* `A` : `np.array` of shape $(n,n)$
|
|
49
49
|
>System dynamics matrix
|
|
50
|
-
* `B` : `np.array` of shape( $n,\sum_{i=}
|
|
50
|
+
* `B` : `np.array` of shape( $n,\sum_{i=1}^N m_i$ ), optional
|
|
51
51
|
>Input matrix for all virtual control objectives
|
|
52
|
-
* `Bs` : `Sequence` of `np.array` objects of len
|
|
52
|
+
* `Bs` : `Sequence` of `np.array` objects of len $(N)$, each array $B_i$ of shape $(n,m_i)$, optional
|
|
53
53
|
>Input matrices for each virtual control objective
|
|
54
|
-
* `Qs` : `Sequence` of `np.array` objects of len
|
|
54
|
+
* `Qs` : `Sequence` of `np.array` objects of len $(N)$, each array $Q_i$ of shape $(n,n)$, optional
|
|
55
55
|
>State weight matrices for each virtual control objective
|
|
56
|
-
* `Rs` : `Sequence` of `np.array` objects of len
|
|
56
|
+
* `Rs` : `Sequence` of `np.array` objects of len $(N)$, each array $R_i$ of shape $(m_i,m_i)$, optional
|
|
57
57
|
>Input weight matrices for each virtual control objective
|
|
58
|
-
* `Ms` : `Sequence` of `np.array` objects of len
|
|
58
|
+
* `Ms` : `Sequence` of `np.array` objects of len $(N)$, each array $M_i$ of shape $(m_i,m)$, optional
|
|
59
59
|
>Decomposition matrices for each virtual control objective
|
|
60
|
-
* `objectives` : `Sequence` of `Objective` objects of len
|
|
60
|
+
* `objectives` : `Sequence` of `Objective` objects of len $(N)$, each $O_i$ specifying $Q_i, R_i$ and $M_i$, optional
|
|
61
61
|
>Desired objectives for the game
|
|
62
|
-
* `x_0` : `np.array` of len
|
|
62
|
+
* `x_0` : `np.array` of len $(n)$, optional
|
|
63
63
|
>Initial state vector
|
|
64
|
-
* `x_T` : `np.array` of len
|
|
64
|
+
* `x_T` : `np.array` of len $(n)$, optional
|
|
65
65
|
>Final state vector, in case of signal tracking
|
|
66
66
|
* `T_f` : positive `float`, optional
|
|
67
67
|
>System dynamics horizon. Should be given in the case of finite horizon
|
|
68
|
-
* `P_f` : `list` of `np.array` objects of len
|
|
68
|
+
* `P_f` : `list` of `np.array` objects of len $(N)$, each array $P_{f_i}$ of shape $(n,n)$, optional, default = uncoupled solution of `scipy's solve_are`
|
|
69
69
|
>
|
|
70
70
|
>Final condition for the Riccati equation array. Should be given in the case of finite horizon
|
|
71
|
-
* `state_variables_names` : `Sequence` of `str` objects of len
|
|
71
|
+
* `state_variables_names` : `Sequence` of `str` objects of len $(N)$, optional
|
|
72
72
|
>The state variables' names to display when plotting
|
|
73
73
|
* `show_legend` : `boolean`, optional
|
|
74
74
|
>Indicates whether to display a legend in the plots
|
|
75
|
-
* `state_variables_names` : `Sequence` of `str` objects of len
|
|
75
|
+
* `state_variables_names` : `Sequence` of `str` objects of len $(n)$, optional
|
|
76
76
|
>The state variables' names to display
|
|
77
77
|
* `epsilon_x` : `float` in the interval $(0,1)$, optional
|
|
78
78
|
>Numerical convergence threshold for the state vector of the system
|
|
@@ -93,7 +93,7 @@ Consider the following system of masses and springs:
|
|
|
93
93
|
|
|
94
94
|
|
|
95
95
|
<p align="center">
|
|
96
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/two_masses_tikz.png" width="797" height="130"/>
|
|
96
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/two_masses_tikz.png" width="797" height="130"/>
|
|
97
97
|
</p>
|
|
98
98
|
|
|
99
99
|
The performance of the system under the use of the suggested method is compared with that of a Linear Quadratic Regulator (LQR). For that purpose, class named [`PyDiffGameLQRComparison`](https://github.com/krichelj/PyDiffGame/blob/master/src/PyDiffGame/PyDiffGameLQRComparison.py) is defined. A comparison of a system should subclass this class.
|
|
@@ -234,8 +234,8 @@ Refer
|
|
|
234
234
|
This will result in the following plot that compares the two systems performance for a differential game vs an LQR:
|
|
235
235
|
|
|
236
236
|
<p align="center">
|
|
237
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/2-players_large_1.png" width="400" height="300"/>
|
|
238
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/LQR_large_1.png" width="400" height="300"/>
|
|
237
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/2-players_large_1.png" width="400" height="300"/>
|
|
238
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/LQR_large_1.png" width="400" height="300"/>
|
|
239
239
|
</p>
|
|
240
240
|
|
|
241
241
|
|
|
@@ -248,8 +248,8 @@ qs = [[500, 5000]]
|
|
|
248
248
|
we have:
|
|
249
249
|
|
|
250
250
|
<p align="center">
|
|
251
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/2-players_large_2.png" width="400" height="300"/>
|
|
252
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/LQR_large_2.png" width="400" height="300"/>
|
|
251
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/2-players_large_2.png" width="400" height="300"/>
|
|
252
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/LQR_large_2.png" width="400" height="300"/>
|
|
253
253
|
</p>
|
|
254
254
|
|
|
255
255
|
|
|
@@ -260,20 +260,20 @@ This research was also supported by The Israeli Smart Transportation Research Ce
|
|
|
260
260
|
|
|
261
261
|
<p align="center">
|
|
262
262
|
<a href="https://istrc.net.technion.ac.il/">
|
|
263
|
-
<img src="images/Logo_ISTRC_Green_English.png" width="180" alt=""/>
|
|
263
|
+
<img src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/images/Logo_ISTRC_Green_English.png" width="180" alt=""/>
|
|
264
264
|
</a>
|
|
265
265
|
 
|
|
266
266
|
 
|
|
267
267
|
 
|
|
268
268
|
 
|
|
269
269
|
<a href="https://in.bgu.ac.il/en/Pages/default.aspx">
|
|
270
|
-
<img src="images/BGU-logo-round.png" width="150" alt=""/>
|
|
270
|
+
<img src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/images/BGU-logo-round.png" width="150" alt=""/>
|
|
271
271
|
</a>
|
|
272
272
|
 
|
|
273
273
|
 
|
|
274
274
|
 
|
|
275
275
|
 
|
|
276
276
|
<a href="https://in.bgu.ac.il/en/robotics/Pages/default.aspx">
|
|
277
|
-
<img src="images/logo_abc.png" width="180" alt=""/>
|
|
277
|
+
<img src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/images/logo_abc.png" width="180" alt=""/>
|
|
278
278
|
</a>
|
|
279
279
|
</p>
|
|
@@ -5,7 +5,7 @@ with open("README.md", "r", encoding="utf-8") as fh:
|
|
|
5
5
|
|
|
6
6
|
setuptools.setup(
|
|
7
7
|
name="PyDiffGame",
|
|
8
|
-
version="0.1.
|
|
8
|
+
version="0.1.1",
|
|
9
9
|
author="Dr. Aviran Sadon, Joshua Shay Kricheli and Prof. Gera Weiss",
|
|
10
10
|
author_email="skricheli2@gmail.com",
|
|
11
11
|
description="PyDiffGame is a Python implementation of a Nash Equilibrium solution to Differential Games, based on a reduction of Game Hamilton-Bellman-Jacobi (GHJB) equations to Game Algebraic and Differential Riccati equations, associated with Multi-Objective Dynamical Control Systems",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: PyDiffGame
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.1
|
|
4
4
|
Summary: PyDiffGame is a Python implementation of a Nash Equilibrium solution to Differential Games, based on a reduction of Game Hamilton-Bellman-Jacobi (GHJB) equations to Game Algebraic and Differential Riccati equations, associated with Multi-Objective Dynamical Control Systems
|
|
5
5
|
Home-page: https://shaykricheli.com/PyDiffGame/
|
|
6
6
|
Author: Dr. Aviran Sadon, Joshua Shay Kricheli and Prof. Gera Weiss
|
|
@@ -47,11 +47,11 @@ If you use this work, please cite our paper:
|
|
|
47
47
|
doi={10.1109/MED51440.2021.9480269}}
|
|
48
48
|
```
|
|
49
49
|
|
|
50
|
-
#
|
|
50
|
+
# Installation
|
|
51
51
|
|
|
52
|
-
To
|
|
52
|
+
To install this package run this from the command prompt:
|
|
53
53
|
```
|
|
54
|
-
|
|
54
|
+
pip install PyDiffGame
|
|
55
55
|
```
|
|
56
56
|
|
|
57
57
|
The package was tested for Python >= 3.10, along with the listed packages versions in [`requirments.txt`](https://github.com/krichelj/PyDiffGame/blob/master/requirements.txt)
|
|
@@ -61,34 +61,34 @@ The package was tested for Python >= 3.10, along with the listed packages versio
|
|
|
61
61
|
The package defines an abstract class [`PyDiffGame.py`](https://github.com/krichelj/PyDiffGame/blob/master/src/PyDiffGame/PyDiffGame.py). An object of this class represents an instance of differential game.
|
|
62
62
|
The input parameters to instantiate a `PyDiffGame` object are:
|
|
63
63
|
|
|
64
|
-
* `A` : `np.array` of shape
|
|
64
|
+
* `A` : `np.array` of shape $(n,n)$
|
|
65
65
|
>System dynamics matrix
|
|
66
|
-
* `B` : `np.array` of shape( $n,\sum_{i=}
|
|
66
|
+
* `B` : `np.array` of shape( $n,\sum_{i=1}^N m_i$ ), optional
|
|
67
67
|
>Input matrix for all virtual control objectives
|
|
68
|
-
* `Bs` : `Sequence` of `np.array` objects of len
|
|
68
|
+
* `Bs` : `Sequence` of `np.array` objects of len $(N)$, each array $B_i$ of shape $(n,m_i)$, optional
|
|
69
69
|
>Input matrices for each virtual control objective
|
|
70
|
-
* `Qs` : `Sequence` of `np.array` objects of len
|
|
70
|
+
* `Qs` : `Sequence` of `np.array` objects of len $(N)$, each array $Q_i$ of shape $(n,n)$, optional
|
|
71
71
|
>State weight matrices for each virtual control objective
|
|
72
|
-
* `Rs` : `Sequence` of `np.array` objects of len
|
|
72
|
+
* `Rs` : `Sequence` of `np.array` objects of len $(N)$, each array $R_i$ of shape $(m_i,m_i)$, optional
|
|
73
73
|
>Input weight matrices for each virtual control objective
|
|
74
|
-
* `Ms` : `Sequence` of `np.array` objects of len
|
|
74
|
+
* `Ms` : `Sequence` of `np.array` objects of len $(N)$, each array $M_i$ of shape $(m_i,m)$, optional
|
|
75
75
|
>Decomposition matrices for each virtual control objective
|
|
76
|
-
* `objectives` : `Sequence` of `Objective` objects of len
|
|
76
|
+
* `objectives` : `Sequence` of `Objective` objects of len $(N)$, each $O_i$ specifying $Q_i, R_i$ and $M_i$, optional
|
|
77
77
|
>Desired objectives for the game
|
|
78
|
-
* `x_0` : `np.array` of len
|
|
78
|
+
* `x_0` : `np.array` of len $(n)$, optional
|
|
79
79
|
>Initial state vector
|
|
80
|
-
* `x_T` : `np.array` of len
|
|
80
|
+
* `x_T` : `np.array` of len $(n)$, optional
|
|
81
81
|
>Final state vector, in case of signal tracking
|
|
82
82
|
* `T_f` : positive `float`, optional
|
|
83
83
|
>System dynamics horizon. Should be given in the case of finite horizon
|
|
84
|
-
* `P_f` : `list` of `np.array` objects of len
|
|
84
|
+
* `P_f` : `list` of `np.array` objects of len $(N)$, each array $P_{f_i}$ of shape $(n,n)$, optional, default = uncoupled solution of `scipy's solve_are`
|
|
85
85
|
>
|
|
86
86
|
>Final condition for the Riccati equation array. Should be given in the case of finite horizon
|
|
87
|
-
* `state_variables_names` : `Sequence` of `str` objects of len
|
|
87
|
+
* `state_variables_names` : `Sequence` of `str` objects of len $(N)$, optional
|
|
88
88
|
>The state variables' names to display when plotting
|
|
89
89
|
* `show_legend` : `boolean`, optional
|
|
90
90
|
>Indicates whether to display a legend in the plots
|
|
91
|
-
* `state_variables_names` : `Sequence` of `str` objects of len
|
|
91
|
+
* `state_variables_names` : `Sequence` of `str` objects of len $(n)$, optional
|
|
92
92
|
>The state variables' names to display
|
|
93
93
|
* `epsilon_x` : `float` in the interval $(0,1)$, optional
|
|
94
94
|
>Numerical convergence threshold for the state vector of the system
|
|
@@ -109,7 +109,7 @@ Consider the following system of masses and springs:
|
|
|
109
109
|
|
|
110
110
|
|
|
111
111
|
<p align="center">
|
|
112
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/two_masses_tikz.png" width="797" height="130"/>
|
|
112
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/two_masses_tikz.png" width="797" height="130"/>
|
|
113
113
|
</p>
|
|
114
114
|
|
|
115
115
|
The performance of the system under the use of the suggested method is compared with that of a Linear Quadratic Regulator (LQR). For that purpose, class named [`PyDiffGameLQRComparison`](https://github.com/krichelj/PyDiffGame/blob/master/src/PyDiffGame/PyDiffGameLQRComparison.py) is defined. A comparison of a system should subclass this class.
|
|
@@ -250,8 +250,8 @@ Refer
|
|
|
250
250
|
This will result in the following plot that compares the two systems performance for a differential game vs an LQR:
|
|
251
251
|
|
|
252
252
|
<p align="center">
|
|
253
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/2-players_large_1.png" width="400" height="300"/>
|
|
254
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/LQR_large_1.png" width="400" height="300"/>
|
|
253
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/2-players_large_1.png" width="400" height="300"/>
|
|
254
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/LQR_large_1.png" width="400" height="300"/>
|
|
255
255
|
</p>
|
|
256
256
|
|
|
257
257
|
|
|
@@ -264,8 +264,8 @@ qs = [[500, 5000]]
|
|
|
264
264
|
we have:
|
|
265
265
|
|
|
266
266
|
<p align="center">
|
|
267
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/2-players_large_2.png" width="400" height="300"/>
|
|
268
|
-
<img align=top src="src/PyDiffGame/examples/figures/2/LQR_large_2.png" width="400" height="300"/>
|
|
267
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/2-players_large_2.png" width="400" height="300"/>
|
|
268
|
+
<img align=top src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/src/PyDiffGame/examples/figures/2/LQR_large_2.png" width="400" height="300"/>
|
|
269
269
|
</p>
|
|
270
270
|
|
|
271
271
|
|
|
@@ -276,20 +276,20 @@ This research was also supported by The Israeli Smart Transportation Research Ce
|
|
|
276
276
|
|
|
277
277
|
<p align="center">
|
|
278
278
|
<a href="https://istrc.net.technion.ac.il/">
|
|
279
|
-
<img src="images/Logo_ISTRC_Green_English.png" width="180" alt=""/>
|
|
279
|
+
<img src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/images/Logo_ISTRC_Green_English.png" width="180" alt=""/>
|
|
280
280
|
</a>
|
|
281
281
|
 
|
|
282
282
|
 
|
|
283
283
|
 
|
|
284
284
|
 
|
|
285
285
|
<a href="https://in.bgu.ac.il/en/Pages/default.aspx">
|
|
286
|
-
<img src="images/BGU-logo-round.png" width="150" alt=""/>
|
|
286
|
+
<img src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/images/BGU-logo-round.png" width="150" alt=""/>
|
|
287
287
|
</a>
|
|
288
288
|
 
|
|
289
289
|
 
|
|
290
290
|
 
|
|
291
291
|
 
|
|
292
292
|
<a href="https://in.bgu.ac.il/en/robotics/Pages/default.aspx">
|
|
293
|
-
<img src="images/logo_abc.png" width="180" alt=""/>
|
|
293
|
+
<img src="https://raw.githubusercontent.com/krichelj/PyDiffGame/master/images/logo_abc.png" width="180" alt=""/>
|
|
294
294
|
</a>
|
|
295
295
|
</p>
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|