I have solved 1d shock tube problem. (Euler's equations). Using following steps:
1) Define Riemann problem over the domain
2) Carry out local linearisation
3) Based on linearisation, write eigen values and eigenvectors
4) Use upwinding, i.e. find out numerical flux and use update equation
When I implemented above strategy in Matlab, it worked fine. But 'same' problem was when coded in python, it showed problem for some values of the left and right states. When the left and right states were altered to some new parameters, it worked fine and got the expected results.
Why should this happen?
Is this a problem with python, or the 'thinking' strategy of python and matlab are different?
I used numpy for defining arrays and matrices. I used numpy.linalg.solve() function for finding the vector of characteristic variables and hence the vector of flux differences. I used pylab.plot(X,Y) for plotting.
(I cross checked the program several times. I guess there is no problem with it. And it runs well... its just that the graphs given are not correct for some values of the left and right states)


