SolarCooker2.frink

Download or view SolarCooker2.frink in plain text format


h[d, f=3 in] := d^2/(4 f)

g = new graphics

g.line[0 in, 0 in, 9 in, 0 in]

p=new polyline
g.color[0.7,0.7,0.7]

for d = 0 in to 9 in step .1 in
{
   g.line[d, 0 in, d, h[d]]
   p.addPoint[d,h[d]]
}

g.color[0,0,0]
g.add[p]

// Draw line to focus
g.line[0 in, 0 in, 0 in, 3 in]

g.color[0,0,1,.5]
g.fillRectCenter[0 in, 3 in, -.1 in, .1 in]

//g.line[-1 in, 3 in, 1 in, 3 in]

//g.show[]
g.write["solar.svg", 10 in, 10 in, 1]
//g.print[]


Download or view SolarCooker2.frink in plain text format


This is a program written in the programming language Frink.
For more information, view the Frink Documentation or see More Sample Frink Programs.

Alan Eliasen was born 20194 days, 9 hours, 14 minutes ago.