6
\$\begingroup\$

In electrical engineering the parallel operator || gives half the harmonic mean of two values. E.g.:

\$R_1 \parallel R_2 \equiv \frac{1}{1/R_1+1/R_2} \$

But how should you compute

\$kR_1 \parallel R_2 + R_3 = \ ? \$

Is there a commonly accepted order of precedence for the parallel operator?

References would be appreciated.

\$\endgroup\$
7
  • \$\begingroup\$ What is the "k" all about - is it a typo? \$\endgroup\$
    – Andy aka
    Sep 30, 2018 at 18:28
  • 1
    \$\begingroup\$ @Andyaka: k is a scalar constant \$\endgroup\$
    – HKOB
    Sep 30, 2018 at 18:29
  • \$\begingroup\$ But is it needed for this question's clarity? Or does it muddy the water? \$\endgroup\$
    – Andy aka
    Sep 30, 2018 at 18:31
  • \$\begingroup\$ Good question. I have no idea, so it gets a +1... \$\endgroup\$ Sep 30, 2018 at 18:32
  • 1
    \$\begingroup\$ I always interpret the parallel operator as having a higher precedence than + or -, but lower than multiplication or division. That's my own rule, though. I don't think mathematicians consider the parallel operator to be an operator they've cared enough about which to make any rules, assuming they even are aware of it. And in electronics, context usually provides the needed knowledge to know, for sure. \$\endgroup\$
    – jonk
    Sep 30, 2018 at 18:38

3 Answers 3

4
\$\begingroup\$

It looks like the parallel operator is surprisingly common, and there are precedence rules defined by some sources, but not all.

MIT in their courseware suggest using it, and set exam questions on it. They provide no information regarding precedence in their lecture notes. They say the following, with no description of precedence.

This mathematical relationship comes up often enough that it actually has a name: the “parallel operator“,denoted by the symbol \$\parallel\$. When we say \$x‖y\$, it means \$\frac{xy}{x+y}\$

The university of Utah use it to analyse circuits in their course notes, and provide precedence information as follows:

In the absence of parentheses, the parallel operators act before the plus signs, just as multiplies act before the plus signs in a calculator expression. In the parlance of computer science, "the parallel operator binds more tightly than the plus operator."

Finally, this book also defines the operator, and provides precedence rules, in the same way when referring to the equation $$I = \frac{V_{in}}{R_1+R_2 \parallel R_3},$$

the parallel operator has precedence over the addition: \$R_2 \parallel R_3\$ is computed first and then added to \$R_1\$

Note that neither of the references that define precedence of the \$\parallel\$ operator with respect to addition do so with respect to multiplication.

As I have rarely come across this operator, I would make no assumptions regarding precedence, and use brackets to clear up any ambiguity. E.g.: $$I = \frac{V_{in}}{R_1+(R_2 \parallel R_3)}$$

\$\endgroup\$
3
  • \$\begingroup\$ Thanks for a good answer with somewhat useful references. Though the references might not be the best sources, I'm accepting it for now, I am still hopeful that such an everyday operator has been or will be given a more full treatise elsewhere. PS: The Utah course note link did not work for me. \$\endgroup\$
    – HKOB
    Dec 29, 2018 at 11:13
  • 1
    \$\begingroup\$ @HKOB, was really disappointed with amount of information regarding the parallel operator. There is a little more out there, but not as informative or reputable as the ones I listed. \$\endgroup\$
    – rob
    Dec 29, 2018 at 21:31
  • \$\begingroup\$ @HKOB, Regarding the Utah link, if you paste the URL into the wayback machine, it should work (I saved that link to the wayback machine). Or try this link tinyurl.com/ydf29keo (A shortened version for this comment). If it works, let me know and I'll edit the answer to use the wayback machine version. \$\endgroup\$
    – rob
    Dec 29, 2018 at 21:57
2
\$\begingroup\$

There is no question of operator precedence here. \$R2\$ cannot be in series with \$kR1\$ and also in parallel with \$R3\$. There is some information missing from the equation and the only way to clarify the problem is to look at the schematic.

\$\endgroup\$
4
  • \$\begingroup\$ Agreed - the parallel operator is a description of the circuit rather than a mathematical operator. \$\endgroup\$ Sep 30, 2018 at 21:03
  • \$\begingroup\$ "the only way to clarify the problem is to look at the schematic.", or use parenthesis. \$\endgroup\$ Dec 28, 2018 at 10:10
  • \$\begingroup\$ @HarrySvensson I should have clarified my statement. Without looking at the schematic we can't be sure where the parentheses should be placed, whether R3 is in series with R2 alone or in series with the parallel combination of R1 and R2. \$\endgroup\$ Dec 28, 2018 at 13:07
  • \$\begingroup\$ Did you mean "R2 cannot be in parallel with kR1 and also in series with R3"? \$\endgroup\$
    – nijoakim
    Apr 16, 2020 at 21:45
2
\$\begingroup\$

To start: \$R_1||R_2 = \frac{1}{\frac{1}{R_1} + \frac{1}{R_2}} = \frac{R_1 R_2}{R_1 + R_2}\$

Then: \$(kR_1)||R_2 = \frac{1}{\frac{1}{k R_1} + \frac{1}{R_2}} = \frac{1}{\frac{kR_1 + R_2}{kR_1R_2}} = \frac{kR_1R_2}{kR_1 + R_2}\$

Which is not equal to: \$k(R_1||R_2) = k\frac{R_1R_2}{R_1 + R_2}\$

So order definitely matters, but as mentioned in the comments \$||\$ is not really an operator per se. I'd recommend sticking with parentheses to indicate order of operations and avoid ambiguity.

Likewise with addition:

\$R_1 || (R_2 + R_3) = \frac{R_1(R_2 + R_3)}{R_1 + R_2 + R_3} \neq (R_1 || R_2) + R_3 = \frac{R_1R_2}{R_1 + R_2} + R_3\$

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.