Illustration of function functions, MATLAB Programming

Illustration of Function functions:

For illustration, to pass the sin function into fplot, one would pass its handle as shown in figure for the result.

 239_Illustration of Function functions.png

>> fplot(@sin, [-pi pi])

The fplot function is a good shortcut-it is not essential to generate x and y vectors, and it plots a constant curve instead of the discrete points.

The function feval will compute a function handle and execute the function for the identified argument. For illustration, the below is equivalent to sin(3.2):

>> feval(@sin, 3.2)

ans =

    -0.0584

Posted Date: 10/22/2012 1:12:15 AM | Location : United States







Related Discussions:- Illustration of function functions, Assignment Help, Ask Question on Illustration of function functions, Get Answer, Expert's Help, Illustration of function functions Discussions

Write discussion on Illustration of function functions
Your posts are moderated
Related Questions
write a function program to compute a standard deviation of a number

Use Matlab to solve the following set of linear equations by Gaussian Elimination. Write a for loop to perform elementary row operations on the augmented matrix to produce

Call to length function: The call to length function consists of the name of the function, followed by an argument in the parentheses. This function takes the argument, and re

Command Window: To the left of the Command Window, there are 2 tabs for the Current Directory Window and Workspace Window. If the Current Directory tab is selected, the files

This can be done from the command line or from a makefile. You require a script (filename.m). Just type at the command line, or contain in the makefile: matlab

khdjkafhoi woiruwoi epojrpeo

can i post attachments of the assignment? and you do them for me?

Q. Explain Power system toolbox ? Power system toolbox (PST) was developed to enable users to perform power system analysis within MATLAB. PST may be used on any computer syste

how to control a suspension by linear quadratic regulator method?

Consider the 3rd order Bessel function J3(x). Write a script findBessRoots.m that computes all the roots of J3(x) in the interval [0; 40]. Your script must store the roots of the f