Otto Cycle p-v Diagram with Thermal Efficiency
Objective: clear allclose allclc %inputsgamma=1.4t3=2300 %state variablep1=1.01325t1=300 %engine geometric parameterbore=0.068;stroke=0.065;con_rod=0.1;cr=7; %calculating the swept volume and the clearance volumev_swept=(pi/4)*(bore^2)*stroke;v_clearance=v_swept/(cr-1); v1=v_swept+v_clearance;v2=v_clearance %state variables at state…