Test
Aus Wiki1
(Unterschied zwischen Versionen)
Zeile 18: | Zeile 18: | ||
// Erstelle die Temperaturmesspunkte | // Erstelle die Temperaturmesspunkte | ||
- | var temp1 = | + | var temp1 = brd.create('glider', [2,2,he1], {strokeColor:'#00f', fillColor:'#00f', size:10, name:'T1'}); |
- | var temp2 = board.create('glider', [10,2, | + | var temp2 = board.create('glider', [10,2,he2], {strokeColor:'#f00', fillColor:'#f00', size:10, name:'T2'}); |
// Berechne die Temperaturdifferenz | // Berechne die Temperaturdifferenz | ||
- | var deltaT = | + | var deltaT = brd.create('segment', [temp1, temp2], {strokeColor:'#000', strokeWidth:2}); |
- | var label = | + | var label = brd.create('text', [8, 7, function(){return 'ΔT = ' + Math.abs(temp1.Y() - temp2.Y()).toFixed(1) + ' K';}], {fontSize:18}); |
- | + | board.update(); | |
</jsxgraph> | </jsxgraph> |