ConductorG=℧Conductor Icon

Conductor

Ideal linear electrical conductor relating current and voltage through its conductance.

This component models an ideal electrical conductor where the electrical current flowing through it is directly proportional to the voltage difference across its terminals. The relationship is defined by Ohm's law:

\[i = G v\]

where i is the current, v is the voltage, and G is the conductance. The conductance G is a parameter, representing the ease with which current flows through the material, and is the reciprocal of resistance. This model assumes linear behavior, meaning the conductance G remains constant regardless of the voltage or current. It inherits from TwoPin, implying it has two electrical connection points (pins) where voltage v is measured across and current i flows through.

This component extends from OnePort

Usage

ElectricalComponents.Conductor(G)

Parameters:

NameDescriptionUnitsDefault value
GThe electrical conductance of the material.S

Connectors

  • p - This connector represents an electrical pin with voltage and current as the potential and flow variables, respectively. (Pin)
  • n - This connector represents an electrical pin with voltage and current as the potential and flow variables, respectively. (Pin)

Variables

NameDescriptionUnits
vVoltage across the component (between pin p and pin n).V
iCurrent flowing through the component (from pin p to pin n).A

Behavior

\[ \begin{align} v\left( t \right) &= \mathtt{p.v}\left( t \right) - \mathtt{n.v}\left( t \right) \\ i\left( t \right) &= \mathtt{p.i}\left( t \right) \\ \mathtt{n.i}\left( t \right) + \mathtt{p.i}\left( t \right) &= 0 \\ i\left( t \right) &= G v\left( t \right) \end{align} \]

Source

"""
Ideal linear electrical conductor relating current and voltage through its conductance.

This component models an ideal electrical conductor where the electrical current flowing through it
is directly proportional to the voltage difference across its terminals.
The relationship is defined by Ohm's law:

math i = G v

where `i` is the current, `v` is the voltage, and `G` is the conductance.
The conductance `G` is a parameter, representing the ease with which current
flows through the material, and is the reciprocal of resistance. This model
assumes linear behavior, meaning the conductance `G` remains constant
regardless of the voltage or current. It inherits from `TwoPin`,
implying it has two electrical connection points (pins) where voltage `v` is measured
across and current `i` flows through.
"""</span>
<span class="hljs-keyword">component</span> Conductor
&nbsp;&nbsp;<span class="hljs-keyword">extends</span> <span class="hljs-link"><a href="https://help.juliahub.com/dyad/dev/stdlib/ElectricalComponents/types/OnePort.html">OnePort</a></span>
&nbsp;&nbsp;<span class="hljs-comment">"The electrical conductance of the material."</span>
&nbsp;&nbsp;<span class="hljs-keyword">parameter</span> <span class="hljs-symbol">G</span>::<span class="hljs-link"><a href="https://help.juliahub.com/dyad/dev/stdlib/Dyad/types/Conductance.html">Conductance</a></span>
<span class="hljs-keyword">relations</span>
&nbsp;&nbsp;i = G * v
<span class="hljs-keyword">metadata</span> {
&nbsp;&nbsp;"Dyad": {
&nbsp;&nbsp;&nbsp;&nbsp;"labels": [
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{"label": "$(instance)", "x": 500, "y": 1100, "rot": 0},
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{"label": "G=$(G)℧", "x": 500, "y": 150, "rot": 0}
&nbsp;&nbsp;&nbsp;&nbsp;],
&nbsp;&nbsp;&nbsp;&nbsp;"icons": {"default": "dyad://ElectricalComponents/Conductor.svg"}
&nbsp;&nbsp;}
}
<span class="hljs-keyword">end</span></code></pre>
Flattened Source
"""
Ideal linear electrical conductor relating current and voltage through its conductance.

This component models an ideal electrical conductor where the electrical current flowing through it
is directly proportional to the voltage difference across its terminals.
The relationship is defined by Ohm's law:

math i = G v

where `i` is the current, `v` is the voltage, and `G` is the conductance.
The conductance `G` is a parameter, representing the ease with which current
flows through the material, and is the reciprocal of resistance. This model
assumes linear behavior, meaning the conductance `G` remains constant
regardless of the voltage or current. It inherits from `TwoPin`,
implying it has two electrical connection points (pins) where voltage `v` is measured
across and current `i` flows through.
"""</span>
<span class="hljs-keyword">component</span> Conductor
&nbsp;&nbsp;<span class="hljs-comment">"Positive electrical pin."</span>
&nbsp;&nbsp;<span class="hljs-symbol">p</span> = <span>Pin</span>() {
&nbsp;&nbsp;&nbsp;&nbsp;"Dyad": {
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"placement": {"icon": {"iconName": "pos", "x1": -50, "y1": 450, "x2": 50, "y2": 550}}
&nbsp;&nbsp;&nbsp;&nbsp;}
&nbsp;&nbsp;}
&nbsp;&nbsp;<span class="hljs-comment">"Negative electrical pin."</span>
&nbsp;&nbsp;<span class="hljs-symbol">n</span> = <span>Pin</span>() {
&nbsp;&nbsp;&nbsp;&nbsp;"Dyad": {
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"placement": {"icon": {"iconName": "neg", "x1": 950, "y1": 450, "x2": 1050, "y2": 550}}
&nbsp;&nbsp;&nbsp;&nbsp;}
&nbsp;&nbsp;}
&nbsp;&nbsp;<span class="hljs-comment">"Voltage across the component (between pin p and pin n)."</span>
&nbsp;&nbsp;<span class="hljs-keyword">variable</span> <span class="hljs-symbol">v</span>::<span>Voltage</span>
&nbsp;&nbsp;<span class="hljs-comment">"Current flowing through the component (from pin p to pin n)."</span>
&nbsp;&nbsp;<span class="hljs-keyword">variable</span> <span class="hljs-symbol">i</span>::<span>Current</span>
&nbsp;&nbsp;<span class="hljs-comment">"The electrical conductance of the material."</span>
&nbsp;&nbsp;<span class="hljs-keyword">parameter</span> <span class="hljs-symbol">G</span>::<span>Conductance</span>
<span class="hljs-keyword">relations</span>
&nbsp;&nbsp;v = p.v - n.v
&nbsp;&nbsp;i = p.i
&nbsp;&nbsp;p.i + n.i = 0
&nbsp;&nbsp;i = G * v
<span class="hljs-keyword">metadata</span> {
&nbsp;&nbsp;"Dyad": {
&nbsp;&nbsp;&nbsp;&nbsp;"labels": [
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{"label": "$(instance)", "x": 500, "y": 1100, "rot": 0},
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{"label": "G=$(G)℧", "x": 500, "y": 150, "rot": 0}
&nbsp;&nbsp;&nbsp;&nbsp;],
&nbsp;&nbsp;&nbsp;&nbsp;"icons": {"default": "dyad://ElectricalComponents/Conductor.svg"}
&nbsp;&nbsp;}
}
<span class="hljs-keyword">end</span></code></pre>


Test Cases

No test cases defined.

  • Examples
  • Experiments
  • Analyses