|
[Sponsors] |
June 11, 2017, 02:24 |
2D-Shocktube inviscid MATLAB
|
#1 |
New Member
|
Dear all
I was successfully able to generate and run 1D-shocktube code in MATLAB. Now I am trying to extend the same to 2D but I am facing some difficulty here. Whenever I try to run the 2D code I am getting the following error " *"Array dimensions must match for binary array op. Error in laxfried1 (line 45) w(:,2:nx-1,2:ny-1)=((w(:,3:nx,2:ny-1)+w(:,1:nx-2,2:ny-1)+w(:,2:nx-1,3:ny)+w(:,2:nx-1,1:ny-2))/4)-(dt/(2*dx)).*(F(:,3:nx,2:ny-1)-F(:,1:nx-2,2:ny-1))-..."* Can anyone help me out where i went wrong, I am trying from my side as well. Please find attached 1D and 2D code for your reference. Thank you all. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
How to start Fluent with Matlab?? | Jay Hu | FLUENT | 8 | November 9, 2022 06:30 |
Export/Import data contour plots with Matlab | meangreen | FLUENT | 11 | October 28, 2020 10:06 |
Very small Matlab job: post-processing OpenFOAM (.CSV) results | RbBb | CFD Freelancers | 1 | July 11, 2016 09:00 |
Live connection Matlab VS OF | levka | OpenFOAM Running, Solving & CFD | 0 | July 10, 2012 04:15 |
Inviscid Drag at subsonic, subcritical Mach # | Axel Rohde | Main CFD Forum | 1 | November 19, 2001 12:19 |