|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?注册
x
ostringstream name;
name<<"cavity_"<<m<<".dat";
ofstream out(name.str().c_str());
out<<"Title=\"LBM Lid Driven Flow\"\n"
<<"VARIABLES=\"X\",\"Y\",\"U\",\"V\"\n"<<"ZONE T=\"BOX\",I="
<<NX+1<<",J="<<NY+1<<",F=POINT"<<endl;
cout<<"The "<<n<<"th computation result:"<<endl
<<"The u,v of point (NX/2, NY/2) is: "<<setprecision(6)
<<u[NX/2][NY/2][0]<<", "<<u[NX/2][NY/2][1]<<endl;
cout<<"The max relative error of uv is: "
<<setiosflags(ios::scientific)<<error<<endl; |
|