Question: writing to file

Question:writing to file

EUIX 44 Maple

  I been trying to run a maple loop recently where maple computes the values of r,theta,phi for spherical coordinates from some fsolve statements. However I have found this to take an extremely long time (days). What I want is for it to make rows of these and then output them to a file so that I have rows of r,theta and phi for several hundred thousand of them atleast. Currently I simply create a n by 3 array with however many entries my loop has and then fill each position in the array using for loops then I use writedata to write the entire array into a file. I was wondering if there is a way to speed this up. For example directly outputing each row into a file thus skipping the array filling.

 

  I have looked at writeline but you seem to be only able to write strings to a file and appendto, however with appendto it always ends up writing everything into the file including the maple prompt and the input despite the fact I have set echo to 0 and quiet to true using interface(echo=0,quiet=true).

 

Can someone help?

Please Wait...