Determining the distribution of voltages in a given rectangular grid

Click For Summary
SUMMARY

This discussion focuses on calculating voltage distribution in an n by m grid using MATLAB. The problem involves applying Kirchhoff's Current Law (KCL) to set up simultaneous equations based on the resistors R1 and R2, which represent horizontal and vertical connections, respectively. The user seeks assistance in automating the solution for varying grid sizes and displaying the results as a matrix. The primary challenge is generating MATLAB code that efficiently computes the voltage at each node given the boundary conditions at points A and B.

PREREQUISITES
  • Understanding of Kirchhoff's Current Law (KCL)
  • Familiarity with resistor networks and voltage drop calculations
  • Basic knowledge of MATLAB programming
  • Ability to formulate and solve simultaneous equations
NEXT STEPS
  • Learn MATLAB matrix operations for solving systems of equations
  • Research how to implement Kirchhoff's laws in MATLAB
  • Explore MATLAB functions for generating matrices dynamically based on input dimensions
  • Study examples of voltage distribution problems in electrical engineering contexts
USEFUL FOR

Electrical engineering students, MATLAB users, and anyone involved in circuit analysis and voltage distribution modeling.

blandonfrank
Messages
2
Reaction score
0

Homework Statement


Hi,
I need to calculate the voltage drop in an n by m grid. There are resistors 4 resistors connected to a square; R1 for horizontals and R2 for verticals. There's a voltage applied at point B and point A is grounded.

11-12-20084-34-05PM.jpg


I need to create a MATLAB function that will solve for the voltage and display it in a matrix.

Homework Equations


Kirchhoff Law
V= IR

The Attempt at a Solution



I1R1 - I2R2 - I3R1 + I1R2 =0 (That's the equation for one of the squares), using this logic to solve for one, I can solve for all. But, how can I automate it for a n x m grid?
 
Physics news on Phys.org
You know the voltages at B and A, so you need to write the (m X n - 2) simultaneous KCL equations to solve for the voltages at those other nodes. The good news is that you have MATLAB to solve the simultaneous equations (set it up as a matrix equation?). The bad new is I don't know MATLAB, and am not sure what kind of scripting capability you have in it.

Is your question more about whether to use the KCL equations, or do you already know that is the way to go, but are looking for a way to generate general code in MATLAB where you put in different n and m values to see how the voltage maps of the nodes change?
 
berkeman,

Thanks for the response.

I know that KCL would be the way to go to solve this problem. My question is more of how I can do it on MATLAB, I have a bunch of currents I and to solve for voltage, I would have to know those currents to see how the voltage maps out.

Once I solve for the voltage, I need to print out the solution as a matrix.
 

Similar threads

  • · Replies 5 ·
Replies
5
Views
2K
Replies
15
Views
3K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 25 ·
Replies
25
Views
4K
  • · Replies 16 ·
Replies
16
Views
2K
  • · Replies 18 ·
Replies
18
Views
3K
  • · Replies 34 ·
2
Replies
34
Views
6K
  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K