Programmer Guide/Command Reference/EVAL/ydiff: Difference between revisions

From STX Wiki
Jump to navigationJump to search
m (1 revision: Initial import)
No edit summary
Line 1: Line 1:
{{DISPLAYTITLE:{{SUBPAGENAME}}}}
{{DISPLAYTITLE:{{SUBPAGENAME}}}}
=====ydiff=====
Calculates the differentiation (differnce quotients) of the vector ''y'' = f(''x'').
----
;Usage 1: <code>ydiff(<var>y<sub>vector</sub></var> {, <var>dx<sub>scalar</sub></var>=1})</code>
;Result 1: The result is the vector ''r'' with <code>nrow(''y'')-1</code>elements.
::<code>''r''[i]=(''y''[i+1]-''y''[i])/dx; with: i=0..nrow(''y'')-2</code>
----
;Usage 2: <code>ydiff(<var>y<sub>vector</sub></var>, <var>x<sub>vector</sub></var>)</code>
;Result 2: The result is the vector ''r'' with <code>nrow(''y'')-1</code>elements.
::<code>''r''[i]=(''y''[i+1]-''y''[i])/(''x''[i+1]-''x''[i]); with: i=0..nrow(''y'')-2</code>
----
[[Programmer_Guide/Command_Reference/EVAL/yint|yint]]


Calculates the differentiation <code>r</code> of the vector <var>y</var> with <code>n-1</code> elements.
[[Programmer_Guide/Command_Reference/EVAL#Functions|<function list>]]
 
=====Usage:=====
 
<code>ydiff(<var>y</var>)</code>
 
=====Parameters:=====
 
;<var>y</var>
 
:The y data vector.
 
=====Result:=====
 
r[i] = <var>y</var>[i+1] - <var>y</var>[i]
 
=====Usage:=====
 
<code>ydiff(<var>y</var>,<var>dx</var>)</code>
 
=====Parameters:=====
 
;<var>dx</var>
 
:The <var>x</var> increment.
 
=====Result:=====
 
r[i] = (<var>y</var>[i+1] - <var>y</var>[i])/<var>dx</var>
 
=====Usage:=====
 
<code>ydiff(<var>y</var>,<var>x</var>)</code>
 
=====Parameters:=====
 
;<var>x</var>
 
:The x data vector with <code>n</code> elements.
 
=====Result:=====
 
r[i] = (<var>y</var>[i+1] - <var>y</var>[i])/(<var>x</var>[i+1] - <var>x</var>[i])

Revision as of 08:46, 13 April 2011

Calculates the differentiation (differnce quotients) of the vector y = f(x).


Usage 1
ydiff(yvector {, dxscalar=1})
Result 1
The result is the vector r with nrow(y)-1elements.
r[i]=(y[i+1]-y[i])/dx; with: i=0..nrow(y)-2

Usage 2
ydiff(yvector, xvector)
Result 2
The result is the vector r with nrow(y)-1elements.
r[i]=(y[i+1]-y[i])/(x[i+1]-x[i]); with: i=0..nrow(y)-2

yint

<function list>

Navigation menu

Personal tools