Question: write c++ program that prompts the user to input values for E,R,L,C,f initial and f final. R should be entered in ohms, E should be

 write c++ program that prompts the user to input values for

E,R,L,C,f initial and f final. R should be entered in ohms, E

write c++ program that prompts the user to input values for E,R,L,C,f initial and f final. R should be entered in ohms, E should be entered in volts, C should be entered in mF,uF or nF. L should be in my and f initial and f final should be entered in Hz.

It is useful to be able to generate tables of information involving repeated calculations in engineering. One example of this is where the current is to be calculated (as a function of frequency) for a series RLC elecrical cy) for a series RLC electrical circuit. Shown on page 3 is a "series RIC" circuit, consisting of a sinusoidal voltage source, a resistor, an inductor, and a capacitor. The current I in this circuit changes as the frequency of the sinusoidal voltage changes. R-Resistance in Ohms () L = Inductance in Henries (H) C- Capacitance in Farads (F) Current in Amperes (A) E-Sinusoidal voltage in Volts (V), at some frequency, f f Frequency in Hertz (Hz) The current, I, can be calculated in the circuit using the following relationships: x, = inductive reactance = 2 , . f-L in ohms () Xc capacitive reactancein ohms (2) 7-total circuit impedance = R2 + (XI + Xc)2 in ohms () I-current in Amperes (A) Program Requirements: 1 The user should be prompted to input the values for E, R, L, C, fa tial and final. The value for R should be entered in ohms (for example, the user enters 500) . The value of E should be entered in volts The value of C should be entered in mF, uF, or nF (then convert it to F). For example, the user enters 10 mF . The value of L should be entered in mH or uH (then convert it to H) . The value of fmitial and frnal should be entered in Hz, kHz, or MHz (then convert it to Hz) Create a table containing values of f, XL, XC, Z, and I for a range of values of f. . Use a loop vary f from finitial to the first value of fgreater than or equal to finai where f doubles each 2. time through the loop. For example, if fnatial 100 and firal 1E6, then f 100, 200, 400, 800, 1638400 (this spacing is common as graphs often place frequency on a log scale)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!