help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Numerical Differentiation and Integration of Array Data


From: syberraith
Subject: Re: Numerical Differentiation and Integration of Array Data
Date: Sat, 3 Dec 2011 05:44:53 -0800 (PST)

Well, if this accomplishes my goal, all the better.  I did have it in the
back of my mind the that I was taking one step forward, then one step back. 
It's just how I worked out the process.

***

tic
n = 1000000;  # Number of data points
p = 0.005;   # Time period
a = 0.25; # Variable parameter;

t = linspace(0, p , n);
tmp = a + sin(t .* 2 .* pi ./ p);
s = tmp(end) .- tmp(1)
toc

***

s =  -2.4980e-16
ans = 0.44271

I'll have to see how that works out for my project functions.


--
View this message in context: 
http://octave.1599824.n4.nabble.com/Numerical-Differentiation-and-Integration-of-Array-Data-tp4145498p4153312.html
Sent from the Octave - General mailing list archive at Nabble.com.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]