Skip to content

Instantly share code, notes, and snippets.

View CryogenicPlanet's full-sized avatar
⚒️
Building something new

Rahul Tarak CryogenicPlanet

⚒️
Building something new
View GitHub Profile
@CryogenicPlanet
CryogenicPlanet / mediumTutorial.ino
Created July 20, 2019 15:52
The entire code for the AdaFruit Arduino library used to automate electronics
/*****************
Adafruit MQTT Library ESP8266 Example
Must use ESP8266 Arduino from:
https://github.com/esp8266/Arduino
Works great with Adafruit's Huzzah ESP board & Feather
----> https://www.adafruit.com/product/2471
@CryogenicPlanet
CryogenicPlanet / lorrenz.py
Last active March 23, 2020 00:16
Solving the Lorenz System
def lorenz(x0,y0,z0,start_time,time_step):
"""
Returns an array of points, which the lorenz system passes by iteratively perfoming each rk4 timestep
"""
x,y,z = [x0],[y0],[z0] # Start Points
count = 0
t = start_time or 0 # Start Time
dt = time_step or 0.01 # Time Step
while t < 150:
t+= dt
@CryogenicPlanet
CryogenicPlanet / A1_CustomTester.c
Last active May 6, 2020 00:08
CSCA48 A1 Custom Tester
#include "MDB-c.c" // <--- This will import your code so we can
// use your solution to create a linked
// list of movie reviews for testing!
int main()
{
ReviewNode *MDB_head = NULL;
ReviewNode *temp = NULL;
printf("Custom Tester Assuming you have passed all tests in A1_driver \n");
@CryogenicPlanet
CryogenicPlanet / rk4.py
Created February 27, 2020 16:11
Single Time Step for Runge Kutta 4th Order
#Runge-Kutta Method Single Time Step
def rk4(func,t,a,b,c,dt):
"""
Peforms a single time step of the Runge-Kutta 4th Order Method.
The below function finds the ki value for [dx,dy,dz] and return the value to move Yn+1
func is an input of functions, for the Lorenz system this is [dx,dy,dz]
Recall Rk4 Equations :
k1 = h*f(xn,yn)
k2 = h*f(xn+h/2,yn+k1/2)
@CryogenicPlanet
CryogenicPlanet / README.md
Last active March 23, 2020 00:19
Full Code to Solve the Lorenz System
@CryogenicPlanet
CryogenicPlanet / A2_Custom_Tester.c
Last active May 6, 2020 00:08
CSCA48 Assigment 2 Custom Tester
/*
A2 Custom Tester Project
*/
#include <stdbool.h>
#include<string.h>
#include <stdlib.h>
#include"BSTs.c"
double findHarmFreq(double curFreq, int semitones){
@CryogenicPlanet
CryogenicPlanet / A3_custom_checker.c
Created April 2, 2020 13:22
I didn't fully make this checker, infact I only helped build the auto check infrastructure a friend made most of the cases
#include<stdio.h>
#include<stdlib.h>
#include"ingredient_graph.c"
int output_check(intNode *head, intNode *checkAgainst){
// Function aims to autocheck the printed outputs
if(head == NULL){
return 1; // Failed
}
// Functions
let tweetParser = async function (tweetDom) {
let tweetContent = tweetDom.innerText;
let tweet = {
name: "",
username: "",
time: "",
content: "",
interaction: {
reply: "",
@CryogenicPlanet
CryogenicPlanet / spine-gpt3.txt
Created July 26, 2020 22:35
Conversations with GPT-3 to fix the Spine
The following is a conversation with an AI assistant. The assistant is helpful, creative, clever, and very friendly.
Human: Hello, who are you?
AI: I am an AI created by OpenAI. How can I help you today?
Human: Can you help me debug an SSL configuration error?
AI: Sure. What's wrong?
Human: When I open the website, it shows 'ERR_SSL_PROTOCOL_ERROR'
AI: The server's TLS configuration does not support the protocol you are trying to use.
Human: How do I fix that?
AI: Check your server's configuration. Make sure that TLSv1.0 or TLSv1.1 is supported.
@CryogenicPlanet
CryogenicPlanet / shellConfig.sh
Created November 5, 2020 19:56
Default Shell Config
# This file will setup the default config that @CryogenicPlanet uses across machines
yes | sudo apt install zsh
yes | sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
git clone https://github.com/denysdovhan/spaceship-prompt.git "$ZSH_CUSTOM/themes/spaceship-prompt" --depth=1
ln -s "$ZSH_CUSTOM/themes/spaceship-prompt/spaceship.zsh-theme" "$ZSH_CUSTOM/themes/spaceship.zsh-theme"
source ~/.zshrc
echo "Setting Vim config"
wget https://missing.csail.mit.edu/2020/files/vimrc
mv vimrc ~/.vimrc
echo "Manually Set .zshrc theme to spaceship"