From owner-help-octave at bevo dot che dot wisc dot edu Tue Nov 28 07:52:13 1995 Subject: Re: How to quad("sin(a*sin(x))*sin(x)",0,pi/2)? From: vdp at us0 dot mayo dot EDU (Vinayak Dutt) To: help-octave at bevo dot che dot wisc dot edu Date: Tue, 28 Nov 95 07:51:56 CST # # Now I know this won't work as written but I'd like to do something like: # # quad("sin(a*sin(x))*sin(x)",0,pi/2) # # and loop over various values of "a". How can I do this? # # If I could "define" a function from the command line I could keep # changing the definition in a loop. Is this possiable? # # Perhaps a could do some fancy "printf" to a file that defines the function, # but this seems way convoluted. # why don't you use a global variable to keep the value of "a" and use that in your "defined" function? --vinayak- /* * vinayak dutt * ex-graduate student, ultrasound research * mayo graduate school, rochester mn * * e-mail: vdp at mayo dot edu * dutt dot vinayak at mayo dot edu * vdp at us0 dot mayo dot edu * http://www.mayo.edu/ultrasound/ultrasound.html * */ #include "disclaimer.h"