This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sympy as sym | |
import control as ctrl | |
import numpy as np | |
import matplotlib.pyplot as plt | |
m, ell, x3, x4, M, g, F, m = sym.symbols('m, ell, x3, x4, M, g, F, m') | |
# φ(F, x3, x4) | |
phi = 4*m*ell*x4**2*sym.sin(x3) + 4*F - 3*m*g*sym.sin(x3)*sym.cos(x3) | |
phi /= 4*(M+m) - 3*m*sym.cos(x3)**2 | |
dphi_x3 = phi.diff(x3) | |
dphi_x4 = phi.diff(x4) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sympy as sym | |
import numpy as np | |
import control as ctrl | |
import matplotlib.pyplot as p | |
m, ell, x3, x4, M, g, F, m = sym.symbols('m, ell, x3, x4, M, g, F, m') | |
phi = 4*m*ell*x4**2*sym.sin(x3) + 4*F - 3*m*g*sym.sin(x3)*sym.cos(x3) | |
phi /= 4*(M+m) - 3*m*sym.cos(x3)**2 | |
dphi_x3 = phi.diff(x3) | |
dphi_x4 = phi.diff(x4) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sympy as sym | |
m, ell, x1, x2, x3, x4, M, g, F = sym.symbols('m, ell, x1, x2, x3, x4, M, g, F') | |
# φ(F, x3, x4) | |
phi = 4*m*ell*x4**2*sym.sin(x3) + 4*F - 3*m*g*sym.sin(x3)*sym.cos(x3) | |
phi /= 4*(M+m) - 3*m*sym.cos(x3)**2 | |
dphi_x3 = phi.diff(x3) | |
dphi_x4 = phi.diff(x4) | |
dphi_F = phi.diff(F) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sympy as sym | |
m, ell, x1, x2, x3, x4, M, g, F, m = sym.symbols('m, ell, x1, x2, x3, x4, M, g, F, m') | |
# φ(F, x3, x4) | |
phi = 4*m*ell*x4**2*sym.sin(x3) + 4*F - 3*m*g*sym.sin(x3)*sym.cos(x3) | |
phi /= 4*(M+m) - 3*m*sym.cos(x3)**2 | |
dphi_x3 = phi.diff(x3) | |
dphi_x4 = phi.diff(x4) | |
dphi_F = phi.diff(F) | |
psi = -3*(m*ell*x4**2*sym.sin(x3)*sym.cos(x3) + F*sym.cos(x3) - (M+m)*g*sym.sin(x3)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sympy as sym | |
m, ell, x3, x4, M, g, F, m = sym.symbols('m, ell, x3, x4, M, g, F, m') | |
# φ(F, x3, x4) | |
phi = 4*m*ell*x4**2*sym.sin(x3) + 4*F - 3*m*g*sym.sin(x3)*sym.cos(x3) | |
phi /= 4*(M+m) - 3*m*sym.cos(x3)**2 | |
dphi_x3 = phi.diff(x3) | |
dphi_x4 = phi.diff(x4) | |
dphi_F = phi.diff(F) | |
psi = -3*(m*ell*x4**2*sym.sin(x3)*sym.cos(x3) + F*sym.cos(x3) - (M+m)*g*sym.sin(x3)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
from scipy.integrate import solve_ivp | |
import matplotlib.pyplot as plt | |
class Car: | |
def __init__(self, length=2.3, velocity=5., disturbance=0, x=0., y=0., pose=0.): | |
""" | |
:param length: The length between the two axles of the car |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
from scipy.integrate import solve_ivp | |
import matplotlib.pyplot as plt | |
class Car: | |
def __init__(self, length=2.3, velocity=5., disturbance=0, x=0., y=0., pose=0.): | |
""" | |
:param length: The length between the two axles of the car |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
from scipy.integrate import solve_ivp | |
import matplotlib.pyplot as plt | |
class Car: | |
def __init__(self, length=2.3, velocity=1, x=0, y=0, pose_init=0, disturbance= 0): | |
self.__length = length |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
from scipy.integrate import solve_ivp | |
import matplotlib.pyplot as plt | |
class Car: | |
def __init__(self, length=2.3, velocity=1, x=0, y=0, pose_init=0, disturbance= 0): | |
self.__length = length |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
from scipy.integrate import solve_ivp | |
import matplotlib.pyplot as plt | |
class PidController: | |
"""PidController | |
Documentation goes here | |
""" |
NewerOlder