Connect with us

sawtooth circuit modeling?

Discussion in 'Electronic Design' started by dantimatter, Jun 7, 2007.

Scroll to continue with content
  1. dantimatter

    dantimatter Guest

    hello all,

    i'd like to model a circuit that outputs a sawtooth function. there's
    really two things that i'm looking for: 1) a schematic of the simplest
    circuit that can produce a sawtooth output, and 2) a way to model it
    with something like MATLAB or Mathematica. is anyone here familiar
    with any schematic capture circuit analysis packages, particularly
    ones that can generate the underlying circuit equations? what i
    imagine would be ideal is if i could just plunk together a couple of
    resistors, capacitors, and op-amps in a SPICE like program, then get
    the equations that describe the circuit, and finally carry those
    equations over to MATLAB to model how things change as i vary system
    parameters. i'm at a total loss here. does anyone have any

    many thanks,
  2. D from BC

    D from BC Guest

    SwitchercadIII from Linear Technology is a free spice program..
    A triangle generator can be easily defined in the program.
    ex:.pick rise and fall times..

    Here's some triangle generator cct. ideas
    Square wave and integrator
    bidirection I source and capacitor (hysteretic oscillator)
    RC circuit
    Sound card
    There's some bigass chip out there that does wave synthesis (forgot

    D from BC
  3. martin

    martin Guest

    This is one of the simplest generator

    can't help with the matlab stuff

  4. John Fields

    John Fields Guest

    Yes, capitalize the first word of a sentence and the personal
    pronoun: 'I'.
  5. J.A. Legris

    J.A. Legris Guest

    Google this:
    matlab spice interface

    Many good links will magically appear. Good luck!
  6. martin

    martin Guest

  7. Rich Grise

    Rich Grise Guest

    Go take the course again, from the beginning, but pay attention this time.

    Good Luck!
  8. MooseFET

    MooseFET Guest

    Why? LTSpice does everything needed so why bring less well suited
    software into the picture?

    "simplest" has many meansing. Here's a bit of ASCII art:

    +V ----/\/\/---------+------+----- Output
    ! !
    --- DEVICE
    --- !
    ! !

    DEVICE can be a NE-2 a DIAC, an SCR, ... and etc.
  9. dantimatter

    dantimatter Guest

    thanks to all for the quick responses. i'd like to use MATLAB i'm
    teaching half-of-a-course on systems biology, and the laboratory
    component consists of a bank of computers loaded with MATLAB and
    Mathematica. the machines don't have a circuit simulator. there's a
    particular biological oscillator problem that i'd like the students to
    think about, but it requires some circuit modeling. if this turns out
    to be too difficult to implement or not intsructive, i'll just drop
    this particular problem from the class.

  10. dantimatter

    dantimatter Guest

    and before 'john fields' gets all preachy, there should be a 'because'
    between 'MATLAB' and 'i'm' in the second sentence, and instructive
    should be spelled 'instructive'.
  11. Your "bit of ASCII art" is only capable of generating a sawtooth
    waveform with an infinite input voltage.

    It instead generates an exponantial waveform.

    The best way to generate a sawtooth is to integrate a constant current.

    Many thanks,

    Don Lancaster voice phone: (928)428-4073
    Synergetics 3860 West First Street Box 809 Thatcher, AZ 85552
    rss: email:

    Please visit my GURU's LAIR web site at
  12. J.A. Legris

    J.A. Legris Guest

    I suggest that you post the actual biological problem here - you just
    might get lucky.
  13. dantimatter

    dantimatter Guest

    the data's not published just yet, so i'm reluctant to give out too
    many details. :)

    it looks like you using an op-amp integrator might do the trick for
    the ramping-up, and if i can rig up a switch across the capacitor that
    will quickly discharge it once the voltage has reached a certain
    value, then i've got my sawtooth. so now i guess the question is: how
    do i implement that switch? it's been so long since i've looked at an
    electronics textbook; at least 10 years. is there a way to set up
    some kind of comparator, so that when the voltage on the output of the
    op-amp reaches a certain threshold, the switch is thrown and the
    capacitor rapidly discharges, and then is quickly thrown again so the
    ramping-up can begin all over again?

    many thanks to all!

  14. D from BC

    D from BC Guest

    Constant current source + 555 timer set up for astable multivibrator
    D from BC
  15. J.A. Legris

    J.A. Legris Guest

    Ugh. 555.

    Notwithstanding, Win Hill provides a circuit on p.290 of AoE, Fig.

    Here's another possibility:
  16. D from BC

    D from BC Guest

    Parts Count from Above Link
    1 dual op amp
    4 resistors
    1 cap
    2 diodes
    Split supply??!

    Parts Count for 555 sawtooth gen
    1 LMC555
    1 JFET
    1 resistor
    1 capacitor
    Single supply

    I don't have the fig 5.35 the 555+ Isource cct?
    I make this stuff up but later discover how old my idea is.. :)
    D from BC
  17. J.A. Legris

    J.A. Legris Guest

    Yes it is. It has more parts that yours but then again, it probably
    works! I like the op-amp design because it is more symmetrical. Can
    you use the 555 version to make a nice triangle or reverse sawtooth?
  18. D from BC

    D from BC Guest

    It's all up to the quality of the current source in the 555 cct..
    I don't know the fine bugs of a JFET I source used in this app..

    Yes triangle can be formed too..The 555 would need to control a
    sink/source Iregulator.

    Reverse sawtooth can be done with inversion to regular sawtooth.
    D from BC
  19. Jasen

    Jasen Guest

    a square wave fed to a R-C low-pass filter.

    that's basically a logarythmic decay curve in both directions.

    and similar to what you'd find on pin 2 of a 555 based astable oscilator.

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