# Nodal analysis in s-domain help

I am learning circuit analysis in s-domain from my textbook "Engineering Circuit Analysis by William Hayt, 8th Ed". I am struggling with the mesh and nodal analysis.

In the book at page 583, there is a small practice question which I tried and my answer and the book solution don't really match. Can somebody help me show where I am getting things wrong?

The book solution to the exercise is: $$v_{x}(t)=[5+5.657(e^{-1.707t}-e^{-0.2929t})]u(t)$$

My solution to the exercise is: $$v_{x}(t)=[5+7.07(e^{-1.707t}-e^{-0.293t})]u(t)$$

• The constants in the sources are initial conditions and not part of the step inputs.
– Chu
Commented Dec 29, 2018 at 0:43
• @Chu I know. The constant addends are used to find the capacitor voltage at t=0-. But considering an equivalent circuit at t<0, we find that the voltage across the capacitor terminals is zero. Therefore, the capacitor has NO initial energy stored at t=0+. Then, at t>0, we can consider the voltage source to be vs=5*u(t). This is the method used throughout the book. Commented Dec 29, 2018 at 0:48
• But there is an initial current through the inductor.
– Chu
Commented Dec 29, 2018 at 1:03
• @Chu OH! you're right! I didn't take that into account. I really welcome your methode since I don't know any alternative strategy to solve this problem. Commented Dec 29, 2018 at 1:07
• @Chu You are definitely right. My mistake comes from the fact that I didn't consider the initial current throught the inductor. Thanks a million. Commented Dec 29, 2018 at 13:31

I finally figured out the solution. The key is to firstly find the initial current flowing through the inductor.

For $$\t<0\$$, the equivalent circuit is the following:

From this circuit, we will calculate the capacitor voltage $$\v_c(\infty)\$$ and the inductor current $$\ i_L(\infty)\$$ which will serve as initial stored energy values in the original circuit.

• It is clear that $$\v_c(\infty)=0\text{ Volts}\$$
• Mesh analysis on the two loops will yield $$\i_L(\infty)\$$

From Mesh 1: \begin{align*} \frac{1}{s} &= I - I_L +\frac{2}{s}I\\ \frac{1}{s} &= \left(1+\frac{2}{s}\right)I - I_L \end{align*}

From Mesh 2: \begin{align*} \frac{1}{s} &= I - I_L -\left(4s\right)I_L\\ \frac{1}{s} &= I - \left(1+4s\right)I_L \end{align*}

The linear system is the following:

$$\begin{cases} \left(1+\frac{2}{s}\right)I - I_L &= \frac{1}{s}, &\text{from Mesh 1}\\ I - \left(1+4s\right)I_L &= \frac{1}{s}, &\text{from Mesh 2} \end{cases}$$

Solving the system, we end up with the expression of $$\I_L\$$:

\begin{align*} I_L &=\frac{{}^{-1}{\mskip -5mu/\mskip -3mu}_2}{s\left(s^2+2s+{}^1{\mskip -5mu/\mskip -3mu}_2\right)}\\ I_L &= \frac{{}^{-1}{\mskip -5mu/\mskip -3mu}_2}{s\left(s+1+\frac{\sqrt{2}}{2}\right)\left(s+1-\frac{\sqrt{2}}{2}\right)} \end{align*}

Proceeding with the decomposition of the rational expression:

$$I_L=\frac{-1}{2}\left(\frac{a}{s}+\frac{b}{\left(s+1+\frac{\sqrt{2}}{2}\right)}+\frac{c}{\left(s+1-\frac{\sqrt{2}}{2}\right)}\right)$$

where $$\a,b,c\$$ are real numbers. Taking the inverse Laplace trasform of $$\I_L\$$: \begin{align*} \mathcal{L}^{-1}\{I_L\}=i(t)&=\frac{-1}{2}\left(a+b e^{-\left(1+{}^{\sqrt{2}}{\mskip -5mu/\mskip -3mu}_2\right) t} +c e^{-\left(1-{}^{\sqrt{2}}{\mskip -5mu/\mskip -3mu}_2\right) t}\right) u(t)\\ i(\infty)&= \frac{-a}{2} \end{align*} Identifying $$\a\$$, we find that: $$a=2 \quad \text{and}\quad i(\infty)=-1 \text{ A}$$

Now, in the second part at $$\t\geq 0\$$, we return to the intial circuit which becomes as:

Calculating $$\V_x\$$: \begin{align*} \left(\frac{5}{s}-V_x\right)\frac{s}{2} &=V_x+\left(V_x-4-\frac{5}{s}\right)\frac{1}{4s}\\ \left(\frac{5}{s}-V_x\right)\frac{s}{2} &= \left(1+\frac{1}{4s}\right)V_x-\left(\frac{1}{s}+\frac{5}{4s^2}\right)\\ V_x &= \frac{10s^2+4s+5}{s\left(4s+2s^2+1\right)}\\ V_x &= \frac{5s^2+2s+{}^{5}{\mskip -5mu/\mskip -3mu}_2}{s\left(s+1+\frac{\sqrt{2}}{2}\right)\left(s+1-\frac{\sqrt{2}}{2}\right)} \end{align*}

Decomposing the rational expression: $$V_x=\frac{d}{s}+\frac{e}{s+1+\frac{\sqrt{2}}{2}}+\frac{f}{s+1-\frac{\sqrt{2}}{2}}$$

where $$\d,e,f\$$ are real numbers. Identifying them, we find that: $$d=5, \qquad e=4\left(\frac{2+\sqrt{2}}{1+\sqrt{2}}\right), \qquad f=4\left(\frac{2-\sqrt{2}}{1-\sqrt{2}}\right)$$

Taking the inverse Laplace transform: $$\mathcal{L}^{-1}\{V_x\}=v_x(t)=\left[5+4\left(\frac{2+\sqrt{2}}{1+\sqrt{2}}\right)e^{-\left(1+{}^{\sqrt{2}}{\mskip -5mu/\mskip -3mu}_2\right)t}+4\left(\frac{2-\sqrt{2}}{1-\sqrt{2}}\right)e^{-\left(1-{}^{\sqrt{2}}{\mskip -5mu/\mskip -3mu}_2\right)t}\right]$$

Finally, simplifying the expression: $$v_x(t) =\left(5+5.657e^{-1.707t}-5.657e^{-0.293t}\right)u(t) \text{ V}$$