<![CDATA[
// use this if you want to place a note under the video
var noteHeight = 0;

var Browser = {
IeVersion: function() {
var version = 999; // we assume a sane browser
if (navigator.appVersion.indexOf("MSIE") != -1){
// bah, IE again, lets downgrade version number
version = parseFloat(navigator.appVersion.split("MSIE")[1]);
}
return version;
},
Ie: function() {
if (navigator.appVersion.indexOf("MSIE") != -1){
return true;
}else{
return false;
}
}
}

//some default settings
var verticalView = true;
var maximized = false;
$("#limaxv").css('display', 'block');
$("#liminv").css('display', 'none');

function computeHeightDefaultRatio(slideAreaWidth){
//this is the default 1.33 ratio
var ratio = 100 – (slideAreaWidth * 100) / 720;
desiredHeight = 540 – (540 * ratio) / 100;

return desiredHeight;
}

function computeWidthDefaultRatio(slideAreaHeight){
//this is the default 1.33 ratio

return slideAreaHeight * 1.33;
}

function setSlideAreaHorizontal(){
$('#playerComponent').css('width','320px');
var slideAreaWidth = $("#presentationContent").width() – $("#playerComponent").width()-20;
var desiredHeight = computeHeightDefaultRatio(slideAreaWidth);
setSlideAreaHorizontalCommon(desiredHeight, slideAreaWidth);
}

function setSlideAreaHorizontalMaximized(centerViewWhileMaximized){
$('#playerComponent').css('width','320px');
//obtain width by computing it using default ratio from the browser window height
var windowHeight = $(window).height()-50;
var computedWidth = computeWidthDefaultRatio(windowHeight);
var availableWidth = $("#presentationContent").width() – $("#playerComponent").width()-20;
//if computed width is larger than availableWidth, compute height using default ratio from the available width
//this is done to avoid slide area slide under the player because there is not enough room for its width
if (computedWidth 300){
$(“#playerComponent”).height(height+15+noteHeight);
$(“#summaryComponent”).height(height-250);
} else{
$(“#playerComponent”).height(325);
$(“#summaryComponent”).height(60);
}
}

function setSlideAreaVertical(){
var slideAreaWidth = $(“#playerComponent”).width();
var desiredHeight = computeHeightDefaultRatio(slideAreaWidth);
$(“#slideArea”).height(desiredHeight);
$(“#slideArea”).width(slideAreaWidth);
}

function accommodateSlideArea() {
if(verticalView) {
var presentationWidth = $(“#presentationContent”).width()-12;
$(‘#playerComponent’).width(presentationWidth);
setSlideAreaVertical();
}
else {
if (maximized){
setSlideAreaHorizontalMaximized(true);
}else{
setSlideAreaHorizontal();
}
}
}

$(window).resize(function() {
accommodateSlideArea();
});

function setHorizontalView(centerViewWhileMaximized) {
var playerContainerHeight = 265+noteHeight;
var playerComponentHeight = 590+noteHeight;
//temporary here until integration of overlay ads for other languages than en
$(‘#lhv’).css(‘font-weight’,’bold’);
$(‘#lhv’).css(‘color’, ‘#000000’);
$(‘#lvv’).css(‘font-weight’,’normal’);
$(‘#lvv’).css(‘color’, ‘#1C497B’);

$(“#lihv”).addClass(“selected”);
$(“#ahv”).addClass(“horizontal-selected”);
$(“#livv”).removeClass(“selected”);
$(“#avv”).removeClass(“vertical-selected”);

$(‘#playerComponent’).css(‘width’,’320px’);
$(‘#playerContainer’).css(‘margin-right’,’0px’);
$(‘#playerContainer’).height(playerContainerHeight);
$(‘#playerComponent’).height(playerComponentHeight);

if(Browser.IeVersion() >= 7){
$(‘#clearLine’).css(‘height’,’265px’);
}else{
$(‘#clearLine’).css(‘height’,’0px’);
}

$(‘#slideArea’).css(‘margin-left’,’6px’);
if (maximized){
setSlideAreaHorizontalMaximized(centerViewWhileMaximized);
}else{
setSlideAreaHorizontal();
}
verticalView = false;

$(‘#playerComponent’).css(‘width’,’320px’);
$(‘#playerContainer’).css(‘margin-right’,’0px’);
$(‘#playerContainer’).height(playerContainerHeight);
$(‘#playerComponent’).height(playerComponentHeight);

if(Browser.IeVersion() >= 7){
$(‘#clearLine’).css(‘height’,’265px’);
}else{
$(‘#clearLine’).css(‘height’,’0px’);
}
$(‘#slideArea’).css(‘margin-left’,’6px’);

if (maximized){
setSlideAreaHorizontalMaximized(centerViewWhileMaximized);
}else{
setSlideAreaHorizontal();
}
}

function setVerticalView() {
//temporary here until integration of overlay ads for other languages than en
$(‘#lvv’).css(‘font-weight’,’bold’);
$(‘#lvv’).css(‘color’, ‘#000000’);
$(‘#lhv’).css(‘font-weight’,’normal’);
$(‘#lhv’).css(‘color’, ‘#1C497B’);

$(“#livv”).addClass(“selected”);
$(“#avv”).addClass(“vertical-selected”);
$(“#lihv”).removeClass(“selected”);
$(“#ahv”).removeClass(“horizontal-selected”);

var presentationWidth = $(“#presentationContent”).width()-12;
var playerComponentHeight = 265+noteHeight;
$(‘#playerComponent’).width(presentationWidth);
$(‘#playerContainer’).css(‘margin-right’,’10px’);
$(‘#summaryComponent’).css(‘height’,’265px’);
$(‘#playerComponent’).height(playerComponentHeight);
$(‘#clearLine’).css(‘height’,’0px’);
$(‘#slideArea’).css(‘margin-left’,’0px’);
setSlideAreaVertical();
verticalView = true;

presentationWidth = $(“#presentationContent”).width()-12;
playerComponentHeight = 265+noteHeight;
$(‘#playerComponent’).width(presentationWidth);
$(‘#playerContainer’).css(‘margin-right’,’10px’);
$(‘#summaryComponent’).css(‘height’,’265px’);
$(‘#playerComponent’).height(playerComponentHeight);
$(‘#clearLine’).css(‘height’,’0px’);
$(‘#slideArea’).css(‘margin-left’,’0px’);
}

function setMaximizedView(){
//comment this for now
//$(“#limaxv”).addClass(“selected”);
//$(“#amaxv”).addClass(“maximize-selected”);
//$(“#liminv”).removeClass(“selected”);
//$(“#aminv”).removeClass(“minimize-selected”);
//make maximize button invisible
$(“#limaxv”).css(‘display’, ‘none’);
$(“#liminv”).css(‘display’, ‘block’);
maximized = true;
}

function setMinimizedView(){
//comment this for now
//$(“#liminv”).addClass(“selected”);
//$(“#aminv”).addClass(“minimize-selected”);
//$(“#limaxv”).removeClass(“selected”);
//$(“#amaxv”).removeClass(“maximize-selected”);
//make minimize button invisible
$(“#limaxv”).css(‘display’, ‘block’);
$(“#liminv”).css(‘display’, ‘none’);
maximized = false;
}

function modifyDocument (){
setMaximizedView();

//set css inline to avoid being overriden by the existing css classes
//an alternative would be jQuery addClass method, but it is error prone
$(“#columns_container”).css({“padding-left” : “0px”});
$(“#columns_container”).css({“margin-right” : “0px”});
$(“#rightbar”).css({“display” : “none”});
$(“#header”).css({“display” : “none”});
$(“#footer”).css({“display” : “none”});

//FIXME CHECK THIS set minimum width for the container to be smaller with 510px(the added left and right paddings)
$(“#container”).css({“min-width” : “480px”});

//expand presentation area according to available size
accommodateSlideArea();
}

function rollbackDocument () {
setMinimizedView();

//set css inline to avoid being overriden by the existing css classes
//an alternative would be jQuery addClass method, but it is error prone
$(“#columns_container”).css({“padding-left” : “10px”});
$(“#columns_container”).css({“margin-right” : “355px”});
$(“#rightbar”).css({“display” : “block”});
$(“#header”).css({“display” : “block”});
$(“#footer”).css({“display” : “block”});

//FIXME CHECK THIS set minimum width for the container at the original size
$(“#container”).css({“min-width” : “990px”});

//always rollback to horizontal for IE6; prevents from messing up the layout
if(Browser.IeVersion() >= 7){
//alert(“Version is: ” + Browser.IeVersion());
//accommodate presentation area according to available size
accommodateSlideArea();
}else{
//alert(“Version is: ” + Browser.IeVersion());
setHorizontalView(true);
}
}

var counter=10;

function countDown()
{
if (counter > 0){
$(“#counterMessage”).empty().append(JSResource.content_accessible_prefix + ” ” + counter + ” ” + JSResource.content_accessible_suffix);
–counter;
setTimeout(“countDown()”,1000);
}else
{
$(‘.close’).trigger(‘click’);
//close the overlay programatically
modifyDocument();
}
}

//after DOM loads
$(function() {
$(“.overlaytrigger”).overlay({
closeOnClick: false,
closeOnEsc:true,
mask: {
color: null,
loadSpeed: ‘fast’,
maskId: ‘overlay_mask’,
zIndex: 9999
},
effect: ‘apple’,
onBeforeLoad: function() {
//grab wrapper element inside content
var wrap = this.getOverlay().find(“.contentWrap”);
//load the page specified in the trigger
wrap.load(this.getTrigger().attr(“href”));
},
onLoad: function() {
counter = 10;
countDown();
},
onClose: function() {
//counter set to 0 to end countDown function that keeps running in the background if we close the overlay prior of the 10s
counter = 0;
modifyDocument();
}
});
});

//pass the title of this content to the bookmark JS function
function bookmarkContent(){
var contentTitle = “We Really Don’t Know How To Compute!”;
bookmark(contentTitle);
}

$(‘#playIssue’).click(function() {
$(“#videoIssueEmail”).attr(“href”, “mailto:video-issue@infoq.com?Subject=Issue watching video: “+window.location);
// next line is needed for IE, when href is changed IE also changes the html part(the text part)
$(“#videoIssueEmail”).html(“video-issue@infoq.com”);

$(‘#instructions’).show();
return false;
});
$(‘#hideInstructions’).click(function() {
$(‘#instructions’).hide();
return false;
});

$(“#playerContainer”).hover(function(){
if(!$(‘#problemsVideo’).is(“:visible”)){
$(“#problemsVideo”).show();
noteHeight=20;
if(verticalView){
setVerticalView();
}else{
setHorizontalView(false);
}
}
}, function(){
$(“#problemsVideo”).hide();
noteHeight=0;
if(verticalView){
setVerticalView();
}else{
setHorizontalView(false);
}

});
]]>

Gerald Jay Sussman on biology & computation.

  • The human genome is 1 GB. So is Windows OS.
  • We have no idea how to program a 10¹²-unit thing like a human, or a cow.
  • A salamander regrows three elbows if you break off its arm and reattach it — responding to local errors.
  • We have no idea how to write computer vision in a few steps like neurons do.
  • Program efficiency doesn’t matter.
  • Memory is free right now.
  • Computation is free right now.
  • For a million bucks you can get a seriously computer—but what to do with it?
  • Most of the cost of a computer program is paying programmers. —Huw Evans
  • Yet we spend so much time modifying existing code. —Huw Evans
  • Correctness doesn’t matter. (Getting a reasonable answer is fine.)
  • Security doesn’t matter. (Humans are attacked by parasites all the time.)
  • Biological systems are written to solve problems that the designer didn’t foresee.
  • This LISPian stuff of writing programs that write programs looks very awesome; what I’ve pretty much always wanted to do with computers. (I tried and failed to use PHP’s multiple dollar signs to helpful effect.)
  • Some stiff-matrix stuff that you can understand if you watch some Gilbert Strang videos.
  • The point being: with bindings and such you can write a program that’s somewhat robust: performing operator overloading or similar things so that you can just tell the computer basically what you mean. (Rather than having to be so specific.)
  • “Mathematical symbols are impressionistic” — just think about how the fnof; symbol is used — yeah, some function, whatever, ya know what I mean.
  • Systems that accept a wide variety of inputs and only give a small range of outputs.
  • Your cells have about 1 GB of ROM and a few megabytes of RAM.
  • “Galileo discovered the value of a lie — to figure it out without the friction and then put it back in.”
  • Propagators: Independent Stateless machines connecting stateful cells
  • Satisficing / monotonically increasing local information about a referent.
  • Synchronising problems in parallel computation go away.
  • EE, not CS, point of view. (and I daydreamed off into economic theories using this circuit-diagram thinking)
  • “I hate modern languages, even the ones I invent! … There are no names for intermediate parts [of expressions].”
  • Min 44. Maybe this is an insight into explaining statistics to programmers. Errorful processes go in; this would be like multiple inputs (maybe a distribution assumption, maybe a bound on the error, maybe an independence assumption or equal variances) — and an errorful result comes out. Just like division-of-integers has two outputs—quotient and remainder—so do statistical processes spit out a ton of outputs as well:—answer(s) like beta;’s, error estimates (p’s and t’s), and tons of different ways of looking at what might be wrong with the assumptions (Durbin-Watson, structural F statistic, White estimators). Of course you could turn these outputs into Boolean by saying like “alpha; <.05 goes to TRUE” — but really the continuous alpha score is better.
  • Expert reasoning in circuit diagrams as local reasoning between neighbouring pieces of the circuit diagram.
  • Improving measurements by making independent measurements of the same thing by different methods.
  • Tracking of provenance & shadow premises—….daydreaming: relationship to religious faith/scepticism.
  • Giggling when logic subsystems conflict.
  • Truth Maintenance Systems — the ability to back out
  • Finding lies — medical statistical results
  • Globally inconsistent worldviews that are locally consistent.
  • Aaaand, find me the consistent sub-worldviews that are consistent.
Advertisements

About isomorphismes

Argonaut: someone engaged in a dangerous but potentially rewarding adventure.
Video | This entry was posted in Uncategorized and tagged , , , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s