Skip to content

Problem Statement : For a DC resistive circuit with n nodes and b branches, given the values of resistances and voltage sources in each branch, solve for the current through each branch.

Notifications You must be signed in to change notification settings

passeng02/CirSolv

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

CirSolv

Problem Statement : For a DC resistive circuit with n nodes and b branches, given the values of resistances and voltage sources in each branch, solve for the current through each branch.

Data Structures used :

Graph(M) - EleCir - To model the electric circuit Queue(A) - for the modified BFS algorithm Queue - to store node index temporarily Parent - to store node’s parent index temporarily Arrays(M/A) - R - Matrix having data on circuit equations Kv - Array of voltage values Kr - Array of resistance values BFSa,BFSp,BFSd - Arrays to store data on the modified spanning tree Stack(A) - Temp - Temporary stack to generate cycles Vector(M) - FuCy - To store data on fundamental cycles HashMap(A) To store and access the alias nodes of the meshed tree, in O(1) time.

NOTE : M - Main data structure A - Auxiliary data structure

Algorithms used :

modBFS - A modified BFS algorithm genCycle - To generate cycle from modified spanning tree data genEq - To generate KCL and KVL equations from nodes findDet - To find Determinants solveDet - To solve for branch currents from the determinants

Use cases :

Simulating DC resistive circuits for analysis.

About

Problem Statement : For a DC resistive circuit with n nodes and b branches, given the values of resistances and voltage sources in each branch, solve for the current through each branch.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages