Reply by Fred Abse October 20, 20122012-10-20
On Thu, 18 Oct 2012 12:32:23 -0700, Jim Thompson wrote:

> Suppose, in PSpice, I have a behavioral current source that "quits" unless > it has at least 0.5V across it... > > GDC_I1 N_1 N_2 VALUE {(1+TANH(2.2/0.1*(V(N_1,N_2)-0.5)))/2*1mA} > > Can LTspice understand that line "as is", or must it be changed? > > If it must be changed, what is the proper syntax? > > Thanks! >
"As is", that produces a linear ramp of current from 0 to 1 mA, in LTspice. Try this: Version 4 SHEET 1 880 680 WIRE 304 64 192 64 WIRE 432 64 304 64 WIRE 192 96 192 64 WIRE 432 96 432 64 WIRE 192 240 192 176 WIRE 272 240 192 240 WIRE 320 240 272 240 WIRE 432 240 432 176 WIRE 432 240 320 240 FLAG 320 320 0 FLAG 304 64 N_1 FLAG 272 240 N_2 SYMBOL Misc\\Gpoly 192 192 M180 WINDOW 0 24 104 Left 2 WINDOW 3 -260 4 Left 2 SYMATTR InstName GDC_I1 SYMATTR Value VALUE = {(1+TANH(2.2/0.1*(V(N_1,N_2)-0.5)))/2*1mA} SYMBOL res 304 224 R0 SYMATTR InstName R2 SYMATTR Value 1T SYMBOL voltage 432 80 R0 WINDOW 123 0 0 Left 2 WINDOW 39 0 0 Left 2 SYMATTR InstName V1 SYMATTR Value 0 TEXT -70 338 Left 2 !.dc v1 0 10 0.5 -- "For a successful technology, reality must take precedence over public relations, for nature cannot be fooled." (Richard Feynman)
Reply by Jim Thompson October 18, 20122012-10-18
Suppose, in PSpice, I have a behavioral current source that "quits"
unless it has at least 0.5V across it...

GDC_I1 N_1 N_2 VALUE {(1+TANH(2.2/0.1*(V(N_1,N_2)-0.5)))/2*1mA}

Can LTspice understand that line "as is", or must it be changed?

If it must be changed, what is the proper syntax?

Thanks!
		
                                        ...Jim Thompson
-- 
| James E.Thompson, CTO                            |    mens     |
| Analog Innovations, Inc.                         |     et      |
| Analog/Mixed-Signal ASIC's and Discrete Systems  |    manus    |
| Phoenix, Arizona  85048    Skype: Contacts Only  |             |
| Voice:(480)460-2350  Fax: Available upon request |  Brass Rat  |
| E-mail Icon at http://www.analog-innovations.com |    1962     |
             
I love to cook with wine.     Sometimes I even put it in the food.