Connect with us

frequency response

Discussion in 'CAD' started by ranger, May 15, 2007.

Scroll to continue with content
  1. ranger

    ranger Guest

    I'm trying to plot the frequency of a power supply I've designed. Here
    is the net list:

    PowerSupply

    v1 4 5 dc 0 sin(0 34 60)

    D1 4 2 1N4007
    D2 0 5 1N4007
    D3 5 2 1N4007
    D4 0 4 1N4007

    c1 2 0 1000u
    c2 2 0 100n
    cout out 0 100n

    radj adj 0 5k
    r1 out adj 240

    x 2 adj out LM317

    ..include parts.lib
    ..control
    set units=degree
    destroy all

    tran 0.01ms 100ms
    plot v(4,5) v(out) vs (time*1000)

    destroy all

    ac dec 10 60Hz 7000Hz
    plot ac1.v(out) vs ac1.frequency

    ..endc
    ..end
    --------------------------------------------------------------

    I'm not doing it correctly though. For the second plot (freq
    response), I get values in excess of 6000V ! This is so wrong as my
    calculations have shown just above 28V is possible.
    Please assist me in doing a frequency response.

    Thanks.
     
  2. Hello,

    I tried a transient analysis of your netlist with LTspice and it worked in
    principle
    but there is a small oscillation at the output. The value of Cout is
    undersized.
    Just increase its value to 10u and you will be saved.
    How can you run any .AC-analysis without any source having AC specified?
    It's impossible. Please explain where your AC is specified.

    AC-analysis is a linear system analysis in SPICE!
    It has nothing to do with the AC-voltage applied to your rectifier diodes.
    Where do you want to apply the AC-voltage or current?

    Best regards,
    Helmut

    PS: Nobody can exactly reproduce your circuit wihout knowing your LM317
    model.
     
  3. DDDiiD

    DDDiiD Guest

    Thanks for the suggestion.


    I thought having "v1 4 5 dc 0 sin(0 34 60)" would allow me to do an ac
    analysis because its an ac source. But from your reply, I see that
    this is not the case. The applied ac voltage should be applied to the
    rectifier as v1 is now. What changes should I make to the v1 to allow
    me to perform this ac analysis, while retaining my peak value of 34v
    and frequency of 60Hz.

    I'm using the following model:
    http://www.industrycommunity.com/myforum/moazzam_mahmood_next1/messages/48.html

    Thanks again.
     
  4. Hello,

    I still think you expect something different from the .AC simulation.
    The .AC simulation could be used to measure the small signal input
    "noise" rejection of the regulator versus frequency or it could be
    used to measure the dynamic output resistance of your regulator.
    All these .AC simulations will require to setup the appropriated
    DC condition for the LM317. This means you would apply a DC
    voltage of e.g. 32V at the input with an additional AC definition.
    It would be also necessary to add the correct load device,
    e,g, a resistor load or a current source load.

    The normal 60Hz ripple rejection has to be simulated with .TRAN
    because this is a really nonlinear system.

    Best regards,
    Helmut
     
  5. Sorry, it should be DC 34V in your cicuit.
     
  6. ranger

    ranger Guest

    All these .AC simulations will require to setup the appropriated
    I'm not sure I quite understand this. I am suppose to change "v1 4 5
    dc 0 sin(0 34 60)" to "v1 4 5 dc 34 sin(0 34 60)" thereby giving it a
    dc defintion?
     
  7. Hello,

    A possible Spice-line could be as shown below.

    V1 1 0 DC 38 AC 1

    Overall I rate an AC-simulation useless at this point in the
    circuit, because your diode bridge is acting like a switch
    which conducts only for a fraction of each period.

    Who the hell told you to do a .AC-simulation at this point
    in the circuit and for what reason?

    Best regards,
    Helmut
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-