(*  airy_ai_prime_values.nb *)
(* *)
(*  Purpose: *)
(*    Evaluate the derivative of the Airy Ai *)
(*    function at selected argument values, *)
(*    and write the data to a file. *)
(* *)
(*  Modified:  29 November 2005 *)
(*  Author:  John Burkardt *)

xvec = {};
Do [ {  
x = i/10, 
xvec = Append [ xvec, x],
}, {i,0,10,1} ]
num = Length [ xvec ];
fvec = {};

Do [ {  
x = xvec[[i]], 
f = AiryAiPrime[x] ,
fvec = Append[fvec,f],
 Print[ "f[", x,"] = ",N[f,16]] 
}, {i,1, num,1} ]

(* Write the data to a file. *)
fileout = OpenWrite [ "/Users/burkardt/public_html/math_src/test_values/airy_ai_prime_values.txt" ];
SetOptions [ fileout, FormatType ->TextForm];
Write[ fileout, "#  airy_ai_prime_values.txt" ];
today = Date[];
Write [ fileout, "#  Created on ",today ];
Write [ fileout, "#"];
Write [ fileout, "#  x  f" ];
Write [ fileout, "#"];
Do [ {
x = xvec[[i]];
f = fvec[[i]];
Write [ fileout,  N[x,16], "  ", N[f,16] ] },
{i,1,num,1}];
Close [ fileout ];