Skip to content

Instantly share code, notes, and snippets.

View arvsrao's full-sized avatar

Arvind ರಾವ್ arvsrao

View GitHub Profile
@arvsrao
arvsrao / mathImAdvent6.py
Last active December 17, 2023 21:11
Lösung für Mathe im Advent 2023 Aufgabe #6
BretTyp = list[list[str]]
BLAU = "B"
ORANGE = "O"
LEER = "X"
anfangBret: BretTyp = [[BLAU, BLAU, ORANGE, BLAU],
[ORANGE, ORANGE, BLAU, ORANGE],
[BLAU, BLAU, ORANGE, BLAU],
[BLAU, BLAU, BLAU, BLAU]]
@arvsrao
arvsrao / multiple_symp_implicit_plots.py
Created March 2, 2025 16:02
a script for ploting multiple implicitly defined functions on the same plot.
from sympy import plot_implicit, symbols, Eq, And
x, y = symbols('x y')
p1 = plot_implicit(Eq(x - y, 0), (x, -5, 5), (y, -5, 5), show=False, line_color='blue', linewidth=1000)
p2 = plot_implicit(Eq(x + y, 0), (x, -5, 5), (y, -5, 5), show=False, line_color='red', linewidth=55)
p3 = plot_implicit(Eq(y, 1), (x, -5, 5), (y, -5, 5), show=False, line_color='green', linewidth=1000)
#p3 = plot_implicit(Eq(2*x - y, 0), (x, -5, 5), (y, -5, 5), show=False, line_color='green', linewidth=1000)
# script for making initial space paritioning plot
# for blog post on k-d tree project
import numpy as np
from mpl_toolkits.mplot3d import Axes3D
import matplotlib.pyplot as plt
a= = np.array([[ 6.21829 , 0.779546, 1.82988 ],
[ 5.23381 , 4.69416 , 4.74723 ],
[ 9.74655 , 0.191659, 1.20641 ],