The Designer's Guide Community
Forum
Welcome, Guest. Please Login or Register. Please follow the Forum guidelines.
Jul 17th, 2024, 4:21am
Pages: 1
Send Topic Print
smoothing transition function in transient analysis (Read 939 times)
Dracon
Junior Member
**
Offline



Posts: 11

smoothing transition function in transient analysis
Mar 07th, 2009, 7:27am
 
Dear All,

I have a problem with function that should smooth my output signal.
The transition(V(x), td,tr,tf) add to signal rise and fall times but only in linear way.
I have written following funkction based on Lagrange interpolation between three points (x1,y1) (x2,y2) , (x12,y12) and wanted signal, after smoothing to be more exponential, but I get convergence problem:
       "internal timestep too small in transient analysis"
Note that points(x,y) are changing in time.

analog function real fsmooth;
       input x,x1,y1,x12,y12,x2,y2;
       real x,x1,y1,x12,y12,x2,y2;
     real n1,n12,n2;
           begin
                 n1 = ((x-x12)*(x-x2))/((x1-x12)*(x1-x2));
                 n12 = ((x-x1)*(x-x2))/((x12-x1)*(x12-x2));
                 n2 = ((x-x1)*(x-x12))/((x2-x1)*(x2-x12));
                 fsmooth = n1*y1 + n12*y12 + n2*y2;
           end

     endfunction
Perhaps there is some embedded function to do this??

Thanks for your answers.
Best regards,
Dracon
Back to top
 
 
View Profile   IP Logged
pancho_hideboo
Senior Fellow
******
Offline



Posts: 1424
Real Homeless
Re: smoothing transition function in transient analysis
Reply #1 - Mar 8th, 2009, 9:47am
 
Dracon wrote on Mar 7th, 2009, 7:27am:
I have written following function based on Lagrange interpolation between three points (x1,y1) (x2,y2) , (x12,y12) and wanted signal, after smoothing to be more exponential, but I get convergence problem:
       "internal timestep too small in transient analysis"

Try other interpolation filter such as spline, raised-cosine, etc.

Dracon wrote on Mar 7th, 2009, 7:27am:
Perhaps there is some embedded function to do this??
There is no built-in function provided for such purpose.
Everyone write own interpolation filter, if needed.
Back to top
 
 
View Profile WWW Top+Secret Top+Secret   IP Logged
Ken Kundert
Global Moderator
*****
Offline



Posts: 2386
Silicon Valley
Re: smoothing transition function in transient analysis
Reply #2 - Mar 8th, 2009, 2:38pm
 
The reason why it is not built into the language is because in practice, it is very rarely needed.  My experience is that people overuse smoothing, usually at great cost in modeling and simulation time. Can I ask why you think you need it?

-Ken
Back to top
 
 
View Profile WWW   IP Logged
Dracon
Junior Member
**
Offline



Posts: 11

Re: smoothing transition function in transient analysis
Reply #3 - Mar 8th, 2009, 3:01pm
 
I just begun my journey with modelling circuits and thought it maybe good idea to make signal transitions as it look like in specification. I needed it for driver de-emphasis model, but now if I look on that from a perspective of large simulation time I do not think this is my goal. I think the model have to be simple for functional verifications.
Thanks
Back to top
 
 
View Profile   IP Logged
Pages: 1
Send Topic Print
Copyright 2002-2024 Designer’s Guide Consulting, Inc. Designer’s Guide® is a registered trademark of Designer’s Guide Consulting, Inc. All rights reserved. Send comments or questions to editor@designers-guide.org. Consider submitting a paper or model.