Mehrdadghassabi / Gracc

Graph theory approach for Modeling Electrical Circuits

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

What this repository is about?

this repository is about modeling circuits as graphs and analyzing them with graph theory algorithms for more detail read this article, or if you know persian its better to take look at this.

How to solve an Electrical circuit with Gracc?

  • install Gracc with
    pip install Gracc
  • descripe your circuit as a text! to do so see this. after descripting your circuit as a text locate it here

  • run and plot it with:

    import Gracc as grc
    kg6 = grc.circuit_parser('yourdescriptedcircuit.txt')
    grc.plot_kirchoffgraph(kg6)
    grc.plot_kirchoffgraph_after_solving(kg6)

for example for the circuit5 the solution is:

image

  • its wise to run it in google colab instead of your local machine to do so click in the icon
    Open In Colab

Comming soon...

the next goal is to give a picture as an input see this great repository if we do so then you can use Gracc in your online exam :-)

Notes

  • gracc doesn't support RLC circuits yet :)
  • solving differential equations which is a difficult task itself is done thanks to odeintw
  • archive folder is just for making an archive, delete it in your own fork

About

Graph theory approach for Modeling Electrical Circuits

License:GNU General Public License v3.0


Languages

Language:Jupyter Notebook 72.2%Language:Java 21.5%Language:Python 6.2%Language:CSS 0.1%