Changeset 472
- Timestamp:
- Dec 4, 2009 5:06:44 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/addcmds.tcl
- Property rcs:date changed from 2001/10/14 05:36:29 to 2001/10/19 19:27:58
- Property rcs:lines changed from +8 -3 to +13 -8
- Property rcs:rev changed from 1.23 to 1.24
r458 r472 746 746 grid $np.dl2 -column 0 -row 9 747 747 catch { 748 foreach {x tmin tmax x} $newhist(inst${newhist(setnum)}ITYP) {} 748 set s $newhist(setnum) 749 foreach {x tmin tmax x} $newhist(inst${s}ITYP) {} 749 750 $np.d1.m1 config -text $tmin 750 751 $np.d1.m2 config -text $tmax … … 819 820 if {$newhist(insttype) == "TOF"} { 820 821 catch { 821 foreach {x tmin tmax x} $newhist(inst${newhist(setnum)}ITYP) {} 822 set s $newhist(setnum) 823 foreach {x tmin tmax x} $newhist(inst${s}ITYP) {} 822 824 if {$newhist(tmin) <$tmin } { 823 825 $np.d1.e1 config -fg red … … 828 830 append msg "Max value of $newhist(tmax) msec is invalid.\n" 829 831 } 832 set s $newhist(setnum) 830 833 set dmin [expr {1000. * $newhist(tmin) / \ 831 [lindex $newhist(inst${ newhist(setnum)}ICONS) 0]}]834 [lindex $newhist(inst${s}ICONS) 0]}] 832 835 set dmax [expr {1000. * $newhist(tmax) / \ 833 [lindex $newhist(inst${ newhist(setnum)}ICONS) 0]}]836 [lindex $newhist(inst${s}ICONS) 0]}] 834 837 } 835 838 } elseif {$newhist(insttype) == "CW"} { … … 843 846 } 844 847 catch { 845 set dmin [expr {[lindex $newhist(inst${newhist(setnum)}ICONS) 0]\ 848 set s $newhist(setnum) 849 set dmin [expr {[lindex $newhist(inst${s}ICONS) 0]\ 846 850 * 0.5 / sin(acos(0.)*$newhist(tmax)/180.)}] 847 set dmax [expr {[lindex $newhist(inst${ newhist(setnum)}ICONS) 0]\851 set dmax [expr {[lindex $newhist(inst${s}ICONS) 0]\ 848 852 * 0.5 / sin(acos(0.)*$newhist(tmin)/180.)}] 849 853 } … … 858 862 } 859 863 catch { 860 set ang [lindex $newhist(inst${newhist(setnum)}ICONS) 0] 864 set s $newhist(setnum) 865 set ang [lindex $newhist(inst${s}ICONS) 0] 861 866 set dmin [expr {12.398/ (2.0*sin($ang*acos(0.)/180) * \ 862 867 $newhist(tmax))}]
Note: See TracChangeset
for help on using the changeset viewer.