Open Access Open Access  Restricted Access Subscription Access

First Law of Thermodynamics for Closed System: A Python Approach

Pankaj Dumka, Krishna Gajula, Vikrant Sharma, Dhananjay R Mishra

Abstract


In this paper, an attempt has been made to develop a Python module for evaluating the first law of thermodynamics, which includes the process of work done and amount of heat gained or lost by the system and the amount of internal energy stored. The modules NumPy and Matplotlib were used to perform the stipulated task. In addition, the correctness of codes was checked against different numerical problems, and it has been observed that the program results match exactly with the results in the literature. As a result, the functions thus developed have shown high accuracy with the least effort and error in all the cases.

Cite as

Krishna Gajula, Vikrant Sharma, Dhananjay R. Mishra, & Pankaj Dumka. (2022). First Law of Thermodynamics for Closed System: A Python Approach. Research and Applications of Thermal Engineering, 5(3), 1–10. https://doi.org/10.5281/zenodo.7198286


Full Text:

PDF

References


Nag PK. Engineering thermodynamics. Tata McGraw Hill; 2013.

Incropera FP, DeWitt DP, Bergman TL, Lavine AS, Incropera, F.P., Dewitt D.P., Bergman, T., Lavine A. Fundamentals of Heat and Mass Transfer. 8th ed. Hoboken, NJ: Wiley’s; 2007. doi:10.1016/j.applthermaleng.2011.03.022.

Huei YC. Benefits and introduction to python programming for freshmore students using inexpensive robots. Proc. IEEE Int. Conf. Teaching, Assess. Learn. Eng. Learn. Futur. Now, TALE 2014, 2015, p. 12–7. doi:10.1109/TALE.2014.7062611.

Lin JWB. Why python is the next wave in earth sciences computing. Bull Am Meteorol Soc 2012;93:1823–4. doi:10.1175/BAMS-D-12-00148.1.

Dumka P, Pawar PS, Sauda A, Shukla G, Mishra DR. Application of He’s homotopy and perturbation method to solve heat transfer equations: A python approach. Adv Eng Softw 2022;170:103160. doi:10.1016/j.advengsoft.2022.103160.

Dumka P, Deo A, Gajula K, Sharma V, Chauhan R, Mishra DR. Load and Load Duration Curves Using Python. Int J All Res Educ Sci Methods 2022;10:2127–34.

Meurer A, Smith CP, Paprocki M, Čertík O, Kirpichev SB, Rocklin M, et al. SymPy: Symbolic computing in python. PeerJ Comput Sci 2017;2017:1–27. doi:10.7717/peerj-cs.103.

Rocklin M, Terrel AR. Symbolic statistics with SymPy. Comput Sci Eng 2012;14:88–93. doi:10.1109/MCSE.2012.56.

Rocklin M. Uncertainty Modeling with SymPy Stats. Proc 11th Python Sci Conf 2012:51–5. doi:10.25080/majora-54c7f2c8-009.

Dumka P, Sharma S, Gautam H, Mishra DR. Finite Volume Modelling of an Axisymmetric Cylindrical Fin using Python. Res Appl Therm Eng 2021;4:1–11.

Huang C. Python Solver for Stochastic Differential Equations 2011;34:1–13.

Cywiak M, Cywiak D. SymPy. Multi-Platform Graph. Program. with Kivy Basic Anal. Program. 2D, 3D, Stereosc. Des., Berkeley, CA: Apress; 2021, p. 173–90. doi:10.1007/978-1-4842-7113-1_11.

Johansson R. Numerical python: Scientific computing and data science applications with numpy, SciPy and matplotlib, Second edition. Apress, Berkeley, CA; 2018. doi:10.1007/978-1-4842-4246-9.

Dumka P, Chauhan R, Singh A, Singh G, Mishra D. Implementation of Buckingham ’ s Pi theorem using Python. Adv Eng Softw 2022;173:103232. doi:10.1016/j.advengsoft.2022.103232.

Dumka P, Rana K, Pratap S, Tomar S, Pawar PS, Mishra DR. Modelling air standard thermodynamic cycles using python. Adv Eng Softw 2022;172:103186. doi:10.1016/j.advengsoft.2022.103186.

Pawar PS, Mishra DR, Dumka P. Solving First Order Ordinary Differential Equations using Least Square Method : A comparative study. Int J Innov Sci Res Technol 2022;7:857–64.

Ranjani J, Sheela A, Pandi Meena K. Combination of NumPy, SciPy and Matplotlib/Pylab-A good alternative methodology to MATLAB-A Comparative analysis. Proc. 1st Int. Conf. Innov. Inf. Commun. Technol. ICIICT 2019, 2019, p. 1–5. doi:10.1109/ICIICT1.2019.8741475.

Kanagachidambaresan GR, Manohar Vinoothna G. Visualizations. In: Prakash KB, Kanagachidambaresan GR, editors. EAI/Springer Innov. Commun. Comput., Cham: Springer International Publishing; 2021, p. 15–21. doi:10.1007/978-3-030-57077-4_3.

Pawar PS, Mishra DR, Dumka P, Pradesh M. OBTAINING EXACT SOLUTIONS OF VISCO- INCOMPRESSIBLE PARALLEL FLOWS USING PYTHON. Int J Eng Appl Sci Technol 2022;6:213–7.

Gajula K, Sharma V, Sharma B, Mishra DR, Dumka P. Modelling of Energy in Transit Using Python. Int J Innov Sci Res Technol 2022;7:1152–6.


Refbacks

  • There are currently no refbacks.