about summary refs log tree commit diff
path: root/sourcecodes/bnt-master/BNT/learning/compute_cooling_schedule.m
diff options
context:
space:
mode:
Diffstat (limited to 'sourcecodes/bnt-master/BNT/learning/compute_cooling_schedule.m')
-rw-r--r--sourcecodes/bnt-master/BNT/learning/compute_cooling_schedule.m13
1 files changed, 13 insertions, 0 deletions
diff --git a/sourcecodes/bnt-master/BNT/learning/compute_cooling_schedule.m b/sourcecodes/bnt-master/BNT/learning/compute_cooling_schedule.m
new file mode 100644
index 00000000..397c2f8c
--- /dev/null
+++ b/sourcecodes/bnt-master/BNT/learning/compute_cooling_schedule.m
@@ -0,0 +1,13 @@
+function temp_schedule = compute_cooling_schedule(init_temp, final_temp, anneal_rate)
+
+temp_schedule = [];
+i = 1;
+temp_schedule(i)=init_temp;
+while temp_schedule(i) > final_temp
+  i = i + 1;
+  temp_schedule(i)=temp_schedule(i-1)*anneal_rate;
+end
+
+  
+
+