hey guys i have a text file having 7 columns "x","z","p","v","w","av","aw" of numeric values at different time steps.So i want a c++ code to store these values in different
arrays on which i can operate.My function is of form U(t,z) and returning the "v" and "w" values corresponding to given z and t value.
here is my text file:
TIME= 0.00
9.00000 -0.67000 6.57270 0.00000 0.00000 0.00000 0.00000
9.00000 -0.65029 6.37938 0.00000 0.00000 0.00000 0.00000
9.00000 -0.63059 6.18606 0.00000 0.00000 0.00000 0.00000
9.00000 -0.61088 5.99274 0.00000 0.00000 0.00000 0.00000
9.00000 -0.59117 5.79942 0.00000 0.00000 0.00000 0.00000
9.00000 -0.57147 5.60610 0.00000 0.00000 0.00000 0.00000
9.00000 -0.55176 5.41278 0.00000 0.00000 0.00000 0.00000
9.00000 -0.53206 5.21946 0.00000 0.00000 0.00000 0.00000
9.00000 -0.51235 5.02614 0.00000 0.00000 0.00000 0.00000
9.00000 -0.49264 4.83282 0.00000 0.00000 0.00000 0.00000
Further if the given z value is not in the "z" list for a particular time step t,i am doing linear interpolation.
........how can i read for the different time step from the file.
here is my code for reading the text file for only one given time step i.e.
-0.67001 6.54438 -0.01078 0.00001 -0.00987 0.00000
-0.65043 6.35235 -0.01081 -0.00014 -0.00981 0.00329
-0.63086 6.16032 -0.01083 -0.00028 -0.00976 0.00657
-0.61129 5.96829 -0.01086 -0.00034 -0.00969 0.00967
-0.59172 5.77623 -0.01089 -0.00038 -0.00961 0.01154
-0.57215 5.58411 -0.01096 -0.00035 -0.00945 0.01071
-0.55258 5.39199 -0.01103 -0.00034 -0.00929 0.00992
this post is different from the previous one.........here i need to read the different columns at different time steps...........pls help
as i m a new to this forum i was not kowning about code tags.sorry for ur inconvenience.