This file contains 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
#include<iostream> | |
#include<vector> | |
#include<fstream> | |
#include<complex> | |
using std::cout; | |
using std::cin; | |
using std::endl; | |
using std::vector; | |
using std::complex; |
This file contains 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
/* | |
=============================================================================== | |
Include statements | |
=============================================================================== | |
*/ | |
#include<complex> | |
#include<vector> | |
#include<string> | |
#include<dft_module.hpp> |
This file contains 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
#!usr/bin/python3 | |
""" | |
Created on Mon Sep 4 15:06:35 2017 | |
@author: Michy | |
""" | |
import os | |
import praw |
This file contains 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
# Imports | |
import os | |
import sys | |
import time | |
import psutil | |
import logging | |
import pyautogui as pgui | |
from datetime import datetime |
This file contains 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
k = -7.0071; | |
s = tf('s'); | |
G = k/s^2; | |
% PD controller | |
R = -(0.38 + 0.5*50/(1+50/s)); | |
% Design a PD controller for the unit feedback loop | |
L = series(R,G); | |
sys = feedback(L, 1); |
This file contains 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
% Motor params | |
R = 5.5; % [Ohm] | |
L = 0.0028; % [H] | |
phi = 0.5; % [Wb] | |
k = 1; % [] | |
J = 0.5; % [kg m^2] | |
Cr = 0.1; % [Nm] Assumed Cr constant. | |
V = 24; % [V] Nominal voltage | |
% Building the system |
This file contains 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 sy | |
import numpy as np | |
from sympy.functions import sin, cos, ln | |
import matplotlib.pyplot as plt | |
plt.style.use("ggplot") | |
# Factorial function | |
def factorial(n): | |
if n <= 0: | |
return 1 |
This file contains 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 sy | |
import numpy as np | |
from sympy.functions import sin, cos, ln | |
import matplotlib.pyplot as plt | |
plt.style.use("ggplot") | |
# Factorial function | |
def factorial(n): | |
if n <= 0: | |
return 1 |
This file contains 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
# Load required libraries | |
require(dplyr) | |
require(raster) | |
require(rasterVis) | |
require(ncdf4) | |
# Clean workspace | |
rm(list = ls()) | |
# Open nc file and get the data |
This file contains 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
# We want more resolution for our data! | |
require(sp) | |
require(ncdf4) | |
require(gstat) | |
require(raster) | |
require(rasterVis) | |
# Clear workspace | |
rm(list=ls()) |