equations in VCCS Pspice. urgent!!

Discussion in 'Homework Help' started by yoyo1987, Apr 24, 2014.

  1. yoyo1987

    Thread Starter New Member

    Apr 24, 2014
    17
    0
    I need to create a special VCCS (voltage controlled current source), that will send a current that equals I=i^2+2*(i^3). does anyone know how to do this?
     
  2. strantor

    AAC Fanatic!

    Oct 3, 2010
    4,302
    1,988
    I like your tactic; two identical questions, one with the word "urgent" in the title. Throw out two types of lures and see which one gets a bite first, it's genius! I'll have to try this next time I have a question....
     
  3. mvaseem

    Member

    Jan 31, 2014
    48
    8
    You are saying VCCS while the equation has O/P current dependent on other current source. That would mean CCCS. Isn't it ?
     
  4. yoyo1987

    Thread Starter New Member

    Apr 24, 2014
    17
    0
    I=v^2+2(v^3)

    how do i do something like that?
     
  5. WBahn

    Moderator

    Mar 31, 2012
    17,743
    4,795
    In most spice implementations you can define a source based on a mathematical expression involving other circuit variables. You might look for information on formula sources or something like that.
     
  6. mvaseem

    Member

    Jan 31, 2014
    48
    8
    You can do that using G device in Pspice. That means input is voltage and output is current.

    In your equation "v" must be voltage on some net.

    See below code. I am trying to output current through device G1 which is function of voltage of net1 (which is 5V).
    Plotting trace I(G1) in Pspice would give 275A current.

    *
    V1 net1 0 5
    G1 out 0 value={v(net1)**2+2*(v(net1)**3)}
    R1 out 0 1k
    .tran 0 1m
    .probe
    .end
     
  7. yoyo1987

    Thread Starter New Member

    Apr 24, 2014
    17
    0
    i'll try it.
     
  8. yoyo1987

    Thread Starter New Member

    Apr 24, 2014
    17
    0
    where exactly can I write the code?
     
  9. mvaseem

    Member

    Jan 31, 2014
    48
    8
    You can write it in text editor (notepad), change the extension from .txt to .cir.
    Launch Pspice -> Open Simulation -> Select file type (from default .sim to .cir) -> Browse for cir file -> Run simulation.
     
  10. yoyo1987

    Thread Starter New Member

    Apr 24, 2014
    17
    0
  11. mvaseem

    Member

    Jan 31, 2014
    48
    8
    You can definitely build the circuit in Orcad Capture, which is tightly integrated with Pspice. All the device symbols are available in Capture-Pspice library. You just need to instantiate and connect them. Apply desired values and simulate.
     
  12. yoyo1987

    Thread Starter New Member

    Apr 24, 2014
    17
    0
    all the devices are available, but I need the CCCS to give me a v^3+2*v^2, how do i do that in Orcad capture? I need to write that in code?, if so, so how do I connect between the orcad and the Pspice code?

    I'm sorry, but I'm pretty new with this whole program
     
  13. mvaseem

    Member

    Jan 31, 2014
    48
    8
    You need to draw the circuit in Capture. When you simulate it from Capture, it will generate netlist (for Pspice). This netlist is in the same form as the code I've written. Finally this netlist would automatically be simulated in pspice.
    See attached Image. This would produce same result as the text code.
     
  14. yoyo1987

    Thread Starter New Member

    Apr 24, 2014
    17
    0
    is there any way to do this only in Orcad capture? this Pspice code is messing me up!
    the only problem I have is to explain to Oracad that I want my VCCS to do something a little different.

    in your example, I draw the circuit (but how do I enter the value for G, and how do I call part of the circuit net1 ?) and when I play it , it generates netlist, then I write the code you gave me??
     
  15. yoyo1987

    Thread Starter New Member

    Apr 24, 2014
    17
    0
    it would be easier for both of us if I send you a personal message (it doesn't look like anyone else cares anyways..)
     
  16. djsfantasi

    AAC Fanatic!

    Apr 11, 2010
    2,804
    833
    Noooo. I am watching this thread.
     
Loading...