I realise that I have to give that more thought. Thanks for getting me on track.
On Feb 8, 5:58 pm, Chris Smith <smi...@gmail.com> wrote: > On Wed, Feb 8, 2012 at 4:43 PM, janwillem <jwevand...@xs4all.nl> wrote: > > Thanks Chris, I must confess I overlooked sympyfy, however, there is a > > problem with symbols not being defined as is the case when using multi > > char names like in the below version. If resp is not defined the diff > > complains. What I need is that the student just enters a formula and > > is not bothered with defining the symbols. Any additional > > possibilities? > > import sympy > > s = '(signal - 1.01 * blank) / resp' > > y = sympy.sympify(s) > > print y > > #only works when symbol resp is defined > > resp = sympy.Symbol('resp') > > dydresp = y.diff(resp) > > print dydresp > > Does the student need access to the variables or is the program going > to compute a derivative? And if the latter, how do you decide which > one it will be? > > /c -- You received this message because you are subscribed to the Google Groups "sympy" group. To post to this group, send email to sympy@googlegroups.com. To unsubscribe from this group, send email to sympy+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/sympy?hl=en.