Stanford engineers develop smart windows