Circuit Cracker

Circuit Cracker solves Complex Circuits with Resistors with Logical Reasoning. It uses a Component Tree structure with Recursive Solving to determine the voltages, currents, and resistances for any complex circuit.

Learn to Use:

Introduction

In the current version (v1), circuits are represented in circuit code commands. An simple series circuit is shown below:

              
              R1 1000_O
              R2 1000_O
              LT S 0.01_A R1,R2,
              PASS LT
            
            
These files are compiled line by line by a custom compiler to create a Component Tree structure. The Component Tree is then recursively solved to determine the voltages, currents, and resistances for any complex circuit.

For more information, please visit the Github project page below.

Writing Circuit Code

The "R" command is used to define a resistor in a circuit and needs a name/label as the first parameter. The next three parameters are for voltage, current, and resistance and at least one of them must be provided. The parameters must be followed by their units, i.e. _V for voltage, _A for current, and _O for resistance.

The "L" command is used to define a leg, which acts as a container for resistors and other legs. A leg requires a type (Series or Parallel), a minimum of one subcomponent and additional parameters for voltage and resistance. The subcomponents are listed after the leg type and separated by commas.

The PASS statement signifies the root component of the circuit, which could be either a resistor or a leg. The PASS statement requires only one parameter, the name of the root component.

Future Plans

  • The integration of a GUI into Circuit Code has the potential to greatly enhance the design process for electrical circuits. With a graphical interface, designing circuits may become easier and more intuitive for users, reducing the need for manual coding and allowing for a more user-friendly experience. The automatic definition of legs may also simplify the process of defining and organizing components in a circuit.
  • Furthermore, the expansion of Circuit Code to include other electrical components such as capacitors and inductors may bring more versatility and accuracy to the simulation of electrical circuits. This would allow for the simulation of a wider range of circuits and increase the overall usefulness of Circuit Code. Additionally, the ability to simulate these components may lead to improved circuit design and optimization, resulting in better performance and functionality in real-world applications.