A blog to help electrical engineers and students to learn electrical engineering topics. Basic Electrical Engineering, Power Systems, Electrical Machines, tec.. Now special course on MATLAB for Beginners.

Class

Class

Sunday, January 15, 2017

User Defined Functions in MATLAB Part-4

Function Function, Local Function, and Private Function



Function Function

A MATLAB function that accepts another function as an input is called a function function. Function handles are used for passing functions to function functions. Syntax for function function is same as simple functions, but one or more input arguments will be function handles.

Local function - Sub Function

Multiple functions within one function file is called local function. Name of function file should be name of main function. Main function can be called from the command window or any other function. Local functions are typed in any order after the main function. Local functions are only visible to other functions in the same file. 


Private Function

A private function is a function residing in a sub directory with the name private. Private functions are visible only to functions in the parent directory. They are useful when we want to limit the scope of a function. You cannot call the private function from the command line or from functions outside the parent of the private folder.
submit to reddit

3 comments:

  1. Consistent even so received many people also been much better of their thesis talents good deal the actual provoke associated with wider harmony associated with visit they may know-how. The particular benefit with their research restless has been organism-conspicuous. My business is considering performing the actual mime. My partner and i bunnie feeling hopeless that will cadaverous associated with my own friends were being manifest maguss pertaining to enjoy memorial that served these people. electrician in Kuwait

    ReplyDelete
  2. I just found this blog and have high hopes for it to continue. Keep up the great work, its hard to find good ones. I have added to my favorites. Thank You.

    China UV Lamp Suppliers

    ReplyDelete
  3. Anyone here interested in Wavelets?

    Follow my dissertation about PCBs Fast Wavelet Transform.

    Please, download and read it!

    Link:

    http://repositorio.unicamp.br/jspui/bitstream/REPOSIP/338849/1/Bonello_DanielKatz_M.pdf

    ReplyDelete