eeng:topics:kirchhoff_s_circuit_laws:start
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
eeng:topics:kirchhoff_s_circuit_laws:start [2022/10/23 15:12] – [Example 1: YouTube Channel NunezPhysics] rolf | eeng:topics:kirchhoff_s_circuit_laws:start [2023/12/06 18:49] – [Book Chapter] rolf | ||
---|---|---|---|
Line 2: | Line 2: | ||
====== Kirchhoff' | ====== Kirchhoff' | ||
- | 2022-09-29, RB | + | 2023-12-06, RB |
[[https:// | [[https:// | ||
Line 11: | Line 11: | ||
- Loop Rule (Voltage) | - Loop Rule (Voltage) | ||
+ | ===== Book Chapter ===== | ||
+ | * [[https:// | ||
===== Kirchhoffs' | ===== Kirchhoffs' | ||
Line 53: | Line 55: | ||
| [[https:// | | [[https:// | ||
- | | | + | | {{: |
- | | | + | | Fig.: Kirchhoff' |
To solve the above problem we need three independent equations for three unknowns $I_1$, $I_2$, and $I_3$. | To solve the above problem we need three independent equations for three unknowns $I_1$, $I_2$, and $I_3$. | ||
Line 107: | Line 109: | ||
# kirchhoff_exercise_01.m | # kirchhoff_exercise_01.m | ||
- | # This is a script | + | # This script |
- | # Extended | + | # Example from NunezPhysics |
# R. Becker, 2015-04-12 | # R. Becker, 2015-04-12 | ||
Line 128: | Line 130: | ||
- | ===== Example 2: Wikipedia ===== | + | ==== Solution in Python |
- | * [[https:// | + | This code block shows the solution of the LES in Python (numpy). Klick on the block title to download. |
- | ===== Example | + | <file python kirchhoff_exercise_01.py> |
+ | |||
+ | # kirchhoff_exercise_01.py | ||
+ | # This script solves a simple LES resulting from Kirchhoff' | ||
+ | # Example from NunezPhysics video tutorial: https:// | ||
+ | # R. Becker, 2021-10-23 | ||
+ | |||
+ | import numpy as np | ||
+ | |||
+ | # A matrix is an array of rows, which are arrays. Thus a matrix is a two dimensional array. | ||
+ | # The numpy.array() function is used to create 2D array (aka matrix) from a list of row lists. | ||
+ | R = np.array( | ||
+ | [ | ||
+ | [-1.0, -1.0, 1.0], | ||
+ | [-6.0, | ||
+ | [ 0.0, -3.0, -6.0] | ||
+ | ]) | ||
+ | |||
+ | V = np.array([0.0, | ||
+ | |||
+ | # Inverse matrix | ||
+ | Rinv = np.linalg.inv(R) | ||
+ | |||
+ | # Matrix vector multiplication, | ||
+ | I = Rinv.dot(V) | ||
+ | |||
+ | # Print currents | ||
+ | print(I) | ||
+ | |||
+ | </ | ||
+ | |||
+ | |||
+ | ===== Example | ||
+ | |||
+ | | {{youtube> | ||
+ | | Excellent explanation of Kirchhoff' | ||
* [[https:// | * [[https:// | ||
+ | ===== Example 3: Wikipedia ===== | ||
+ | |||
+ | /* | ||
+ | * [[https:// | ||
+ | */ | ||
+ | | {{https:// | ||
+ | | Source: [[https:// |
eeng/topics/kirchhoff_s_circuit_laws/start.txt · Last modified: 2023/12/06 18:50 by rolf