Computational Physics Project write up.pdf
-
Upload
efrain-anaya -
Category
Documents
-
view
231 -
download
2
Transcript of Computational Physics Project write up.pdf
![Page 1: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/1.jpg)
Computational Physics Project
I started off by first deriving the algorithm needed for the 1-‐Dimensional heat equation., which came from the Taylor expansion of
This is a forward difference time algorithm since its increasing while the spatial part is a central difference, since it both increases and decreases.
The K /Cp is a constant called thermal diffusivity and from now on will be eta (η). The algorithm yielded from the Taylor Series expansion is T[i][j+1] = T[i][j] + η(T[i+1][j]+T[i-‐1][j] –2T[i][j]) We can then use to determine a solution to the heat equation. The first code is for a 1 dimensional bar, the graph has the thermal diffusivity of that material.
![Page 2: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/2.jpg)
![Page 3: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/3.jpg)
The next code was for a sinusoidal distribution., and I chose the b.c’s accordingly.
![Page 4: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/4.jpg)
![Page 5: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/5.jpg)
The next code was for two bars in contact with each other.
![Page 6: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/6.jpg)
![Page 7: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/7.jpg)
![Page 8: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/8.jpg)
![Page 9: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/9.jpg)
Finally this was Newtons law of cooling combined with the heat equation. I chose the environment temperature to be 70 degrees, and the heat source to be 100 degrees, this then leaves the( Te – To )to be 30 degrees. I then chose an arbitrary “h” value for the equations. Two dimensional heat equation:
You can expand this equation with the Taylor expansion as well, but this equation doesn’t have any thermal diffusivity as you can cancel it out, (since time =0). This then becomes a heated plate equation.
![Page 10: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/10.jpg)
![Page 11: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/11.jpg)
For an external source of heat centered on the plate, and the boundaries being zero.
Here the time derivative is zero, leaving the Laplacian, and an external heat source.
![Page 12: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/12.jpg)
![Page 13: Computational Physics Project write up.pdf](https://reader030.fdocuments.us/reader030/viewer/2022020107/5695d1041a28ab9b0294cdf1/html5/thumbnails/13.jpg)