Older Version
Newer Version
cogburn
May 23, 2012
Specific
This program should be useful for chemistry and physics teachers to speed calculations concerning specific heats.
This program should be useful for chemistry and physics teachers to speed calculations concerning specific heats.
'Specific Heat Calculator ver. 1.0
'by Scott Ausbrooks
'May 2012
'This program is written to be a solver for all specific heat
'calculations one might encounter in a general chemistry course.
nomainwin
WindowWidth = 360
WindowHeight = 320
radiobutton #cfg.bQ, "Solve for Heat gained or Lost ", [SolveForQ],[waitHere],100,75,230,20
radiobutton #cfg.bM, "Solve for Mass ", [SolveForMass],[waitHere],100,100,230,20
radiobutton #cfg.bdeltaT, "Solve for Temperature Change ", [SolveForDeltaT],[waitHere],100,125,230,20
radiobutton #cfg.bCp, "Solve for Specific Heat ", [SolveForCp],[waitHere],100,150,230,20
radiobutton #cfg.bTf, "Solve for Final Temperature ", [SolveForTf],[waitHere],100,175,230,20
radiobutton #cfg.bTf, "Solve for Cp of metal ", [CpMetal],[waitHere],100,200,230,20
open "Specific Heat Solver" for dialog as #cfg
print #cfg, "trapclose [quit]"
wait
[SolveForQ]
prompt "Mass = ";m
prompt "Starting Temperature = ";Ti
prompt "Final Temperature = "; Tf
prompt "Specific Heat = ";Cp
q = m * (Tf-Ti) * Cp
notice "Q = ";q
wait
[SolveForMass]
prompt "Heat gained or lost = ";q
prompt "Starting Temperature = ";Ti
prompt "Final Temperature = "; Tf
prompt "Specific Heat = ";Cp
m = q/ ((Tf-Ti)) * Cp
notice "Mass = ";m
wait
[SolveForDeltaT]
prompt "Mass = ";m
prompt "Specific Heat = ";Cp
prompt "Heat gained or lost = ";q
deltaT= q/(m * Cp)
notice "deltaT = ";deltaT
wait
[SolveForCp]
prompt "Mass = ";m
prompt "Starting Temperature = ";Ti
prompt "Final Temperature = "; Tf
prompt "Heat gained or lost = ";q
Cp = q/(m* (Tf-Ti))
notice "Cp = ";Cp
wait
[SolveForTf]
prompt "Mass of metal = ";Mm
prompt "Starting temperature of metal = ";Tim
prompt "Specific heat of metal = ";Cpm
prompt "Mass of water = ";Mw
prompt "Starting temperature of water = ";Tiw
Cpw = 4.18
w = (Mm*Cpm*Tim)
x = (Mm * Cpm)
y = (Mw*Cpw)
z = (Mw*Cpw*Tiw)
Tf = (w+z)/(y+x)
notice "Tf = ";Tf
wait
[CpMetal]
prompt "Mass of metal = ";Mm
prompt "Starting temperature of metal = ";Tim
prompt "Final Temperature of system = "; Tfs
prompt "Mass of water = ";Mw
prompt "Starting temperature of water = ";Tiw
Cpw = 4.18
Cpm = (Mw * (Tfs-Tiw) * Cpw)/(Mm *(Tim-Tfs))
notice "Cp of metal = "; Cpm
[waitHere]
wait
[quit]
close #cfg
end