Difference between revisions of "Fdvec.m"

From Spinach Documentation Wiki
Jump to: navigation, search
Line 1: Line 1:
−
{{DISPLAYTITLE:function.m}}
+
{{DISPLAYTITLE:fdvec.m}}
−
Reasonable description of what the function does and how.
+
Performs arbitrary-order finite-difference differentiation of a user-supplied row or column vector. Uses central finite-difference stencils in the middle and sided stencils of the same order of accuracy on the sides.
  
 
==Syntax==
 
==Syntax==
  
−
     function call string
+
     dx=fdvec(x,npoints,order)
  
 
==Arguments==
 
==Arguments==
  
−
    argument      - description of the argument
+
    x      - column or row vector to be differentiated
−
 
+
−
    argument      - description of the argument
+
    npoints - number of points in the finite difference
−
                    description of the argument
+
              stencil
 +
 +
    order  - order of the derivative required
  
 
==Outputs==
 
==Outputs==
  
−
     output  - description of the output
+
    dx     - column or row vector with the derivative
−
 
−
    output  - description of the output
 
−
              description of the output
 
−
 
 
−
==Examples==
 
−
A description of what is done in the example below:
 
−
 
 
−
    % Comment
 
−
    matlab code
 
−
 
−
    % Comment
 
−
    matlab code
 
−
 
 
−
==Notes==
 
−
Reasonable further notes on good and bad practices.
 
  
 
==See also==
 
==See also==
−
Links to related functions.
+
[[fdmat.m]], [[fdlap.m]], [[fdhess.m]], [[fdkup.m]], [[fdweights.m]], [[fftdiff.m]], [[fourdif.m]], [[fourlap.m]]
  
  
−
''Version 2.2, authors: [[Author 1]]''
+
''Version 2.2, authors: [[Ilya Kuprov]]''

Revision as of 15:08, 16 August 2018

Performs arbitrary-order finite-difference differentiation of a user-supplied row or column vector. Uses central finite-difference stencils in the middle and sided stencils of the same order of accuracy on the sides.

Syntax

    dx=fdvec(x,npoints,order)

Arguments

   x       - column or row vector to be differentiated

   npoints - number of points in the finite difference
             stencil

   order   - order of the derivative required

Outputs

   dx      - column or row vector with the derivative

See also

fdmat.m, fdlap.m, fdhess.m, fdkup.m, fdweights.m, fftdiff.m, fourdif.m, fourlap.m


Version 2.2, authors: Ilya Kuprov