The Designer's Guide Community
Forum
Welcome, Guest. Please Login or Register. Please follow the Forum guidelines.
Jul 17th, 2024, 12:33pm
Pages: 1
Send Topic Print
ODE solving in verilog-A? (Read 766 times)
manus
New Member
*
Offline



Posts: 2

ODE solving in verilog-A?
Aug 26th, 2010, 3:44pm
 
If a differential equation is being solved in verilog-a, how are the initial conditions set? There doesn't seem to be any requirement that initial conditions be provided. What does it do without initial conditions? What's the way to force initial conditions?

I'm using verilog-a to model an electro-mechanical system with a 2nd order ODE governing the kinematics.

Pos(x):ddt(Vel(vl))==-gamma*Vel(vl)/Mro-Kro/Mro*Pos(x)+F(Fw)/Mro;

F(Fw) has been assigned as a function of input voltages in a preceding line.

Thanks!
Back to top
 
 
View Profile   IP Logged
carlgrace
Senior Member
****
Offline



Posts: 231
Berkeley, CA
Re: ODE solving in verilog-A?
Reply #1 - Aug 26th, 2010, 4:27pm
 
Have you tried forcing the various parameters during the @(initial_step) code block?

Carl
Back to top
 
 
View Profile   IP Logged
manus
New Member
*
Offline



Posts: 2

Re: ODE solving in verilog-A?
Reply #2 - Aug 26th, 2010, 4:42pm
 
Is the @(initial_step) code block used for all analyses, or just transient?

I can set an initial condition for Vel(vl) that way, but I can't set an initial condition for Pos(x). If I try to set an initial condition for Pos(x) I get the error: "Encountered an illegal mixing of direct and indirect assignments to branch quantity 'x'. Remove one of the assignments and try again."

For a second order ODE I think I need to set two initial conditions to solve for all parameters. Is there another way to set an initial condition for Pos(x) that verilog-a will allow?
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.