learningMatlab
PhÇ n 1
c¬ së Mat lab
Ch ¬ ng 1:
Cµ i ® Æ t matlab
1.1.Cµ i ® Æ t ch ¬ ng tr×nh:
Qui tr×nh cµ i ® Æ t Matlab còng t ¬ ng tù nh viÖ c cµ i ® Æ t c¸ c ch ¬ ng tr×nh phÇ n mÒ m kh¸ c, chØ cÇ n theo c¸ c h íng dÉ n vµ bæ xung thª m c¸ c th« ng sè cho phï hî p.
1.1.1 Khë i ® éng windows.
1.1.2 Do ch ¬ ng tr×nh ® î c cÊ u h×nh theo Autorun nª n khi g¾ n dÜ a CD vµ o æ ® Ü a th× ch ¬ ng tr×nh tù ho¹ t ® éng, cö a sæ
These codes require an ASCII input file called input.dat of the following form:
Lower Limit on x Upper Limit on x Final Time
Pressure for x<0 when t=0 Density for x<0 when t=0 Speed for x<0 when t=0
Pressure for x>0 when t=0 Density for x>0 when t=0 Speed for x>0 when t=0
These codes produce 8 ASCII output files:
density.out. Density vs. x
entropy.out. Entropy vs. x
mach.out. Mach number vs. x
massflux.out. Mass flux vs. x
pressure.out. Pressure vs. x
sound.out. Speed-of-sound vs. x
velocity.out. Velocity vs. x
waves.out. A description of the solution in terms of the three waves defined in the book (+,-,0).