︠7aaae52b-c538-4f94-808c-e6f78f01746ci︠ %html

Berechnung der Schärfentiefe und Plot der Zerstreuungskreisgröße

Formeln

Quelle: http://www.faqs.org/faqs/rec-photo/lenses/tutorial/

Definitionen:

    Soa     alternate object point to front principal point distance
    Sia     rear principal point to alternate image point distance
    h       hyperfocal distance
    C       diameter of circle of confusion
    c       diameter of largest acceptable circle of confusion
    N       f-stop (focal length divided by diameter of entrance pupil)
    Ne      effective f-stop Ne = N * (1+M/p) 
    D       the aperture (entrance pupil) diameter (D=f/N)
    M       magnification (M=f/(So-f))

The diameter of the circle of confusion can be computed by similar triangles, and then solved in terms of the lens parameters and object distances. For a while let us assume unity pupil magnification, i.e. p=1.

    When So is finite
    C = D*(Sia-Si)/Sia = f^2*(So/Soa-1)/(N*(So-f))
    When So = Infinity,
    C = f^2/(N Soa)

Note that in this formula C is positive when the alternate image point is behind the film (i.e. the alternate object point is in front of the main object) and negative in the opposite case. In reality, the circle of confusion is always positive and has a diameter equal to Abs(C).

︡cf385244-781a-4567-96ab-4a1e54a7f9af︡{"html": "

Berechnung der Schärfentiefe und Plot der Zerstreuungskreisgröße

\n

Formeln

\n

Quelle: http://www.faqs.org/faqs/rec-photo/lenses/tutorial/

\n
\n

Definitionen:

\n
    Soa     alternate object point to front principal point distance\n    Sia     rear principal point to alternate image point distance\n    h       hyperfocal distance\n    C       diameter of circle of confusion\n    c       diameter of largest acceptable circle of confusion\n    N       f-stop (focal length divided by diameter of entrance pupil)\n    Ne      effective f-stop Ne = N * (1+M/p) \n    D       the aperture (entrance pupil) diameter (D=f/N)\n    M       magnification (M=f/(So-f))\n
\n

The diameter of the circle of confusion can be computed by similar triangles, and then solved in terms of the lens parameters and object distances. For a while let us assume unity pupil magnification, i.e. p=1.

\n
    When So is finite\n    C = D*(Sia-Si)/Sia = f^2*(So/Soa-1)/(N*(So-f))\n    When So = Infinity,\n    C = f^2/(N Soa)\n
\n

Note that in this formula C is positive when the alternate image point is behind the film (i.e. the alternate object point is in front of the main object) and negative in the opposite case. In reality, the circle of confusion is always positive and has a diameter equal to Abs(C).

\n
"}︡ ︠14f072cd-56fc-423f-9f07-e969c5b1550f︠ C(f,So,Soa,N)= f^2*(So/Soa-1)/(N*(So-f));C.show() ︡47410446-fbab-4977-ab05-e6ead40b86d8︡{"html": "
\\newcommand{\\Bold}[1]{\\mathbf{#1}}\\left( f, \\mbox{So}, \\mbox{Soa}, N \\right) \\ {\\mapsto} \\ \\frac{{\\left(\\frac{\\mbox{So}}{\\mbox{Soa}} - 1\\right)} f^{2}}{{\\left(\\mbox{So} - f\\right)} N}
"}︡ ︠f7b5f010-6652-4600-9878-53f5ac84e0e0i︠ %html

Vorbelegung

Objektentfernung, Brennweite (jeweils Meter)

Blende

Sensorbreite in Pixel und Meter (daraus Zerstreungskreis)

︡fc678908-423b-40e4-9713-d7489a86a365︡{"html": "

Vorbelegung

\r\n

Objektentfernung, Brennweite (jeweils Meter)

\r\n

Blende

\r\n

Sensorbreite in Pixel und Meter (daraus Zerstreungskreis)

"}︡ ︠1f190fa4-405c-448b-adbe-c48c34589da3︠ So=1.12 # Gegenstandsweite f=0.2 # Brennweite N=5.6 # Blende hpixel=4928 # Sensorbreite Pixel swidth=0.0236 # Sensorbreite m ︡73a3585a-18e3-45be-b1bc-c17613c89884︡︡ ︠4526b604-ba74-42da-bbdb-4ecb4316df83i︠ %html

Dies sind die Werte für dieses Bild.

Nun die Zerstreuungskreisgröße in Abhängigkeit von der Distanz ausrechnen.

︡e9dd926f-a0e4-4deb-90fc-732c751b5bfe︡{"html": "

Dies sind die Werte für dieses Bild.

\n

Nun die Zerstreuungskreisgröße in Abhängigkeit von der Distanz ausrechnen.

"}︡ ︠a84a9aec-caf5-4047-bed1-d0ab1a2ad371︠ x=var("x") c=swidth/hpixel Cf(x)=C(f,So,x,N) show(Cf) ︡ed08dd11-93ba-418d-8b30-b50fe0f3c7d8︡{"html": "
\\newcommand{\\Bold}[1]{\\mathbf{#1}}x \\ {\\mapsto}\\ \\frac{0.00869565217391304}{x} - 0.00776397515527950
"}︡ ︠b36d91a1-8a85-4f0b-9d7d-a67446ecb8a5︠ nah=solve(Cf(x)==c,x)[0].right() fern=solve(Cf(x)==-c,x)[0].right() print "nah/fern: %s und %s resp. %f und %f"%(nah,fern,nah,fern) ︡ffef4635-e157-4003-8124-f60d7c834441︡{"stdout": "nah/fern: 128077/114425 und 71657/63940 resp. 1.119310 und 1.120691"}︡ ︠c5c10725-bc58-4d3d-91d3-6ee3bbc3826b︠ dCf=derivative(Cf,x);aCf(x)=dCf(So)*(x-So) gerade=plot(aCf,So-0.5,So+0.5,color="red") plot (Cf,0.5,5)+gerade p=plot(gerade+plot (Cf,0.5,5)+text(u"Übersicht",(3,Cf(0.5)))) p.axes_labels(["Entfernung\n(m)","Zerstreuungskreis (m)",]) p.show() ︡3a1ad9eb-98dd-456c-a9d1-97fadb4373b2︡{"html": ""}︡ ︠449569ff-e472-4b02-b075-c95eb9c715fci︠ %html

Das obige Diagramm deckt auf der x-Achse den Entfernungsbereich von 50 cm bis 5 Meter ab, auf der y-Achse einen Zerstreuungskreisdurchmesser bis ca. 1 cm (d.h. 0.01 m).

Und nun ein Ausschnitt aus diesem Diagramm, welches nur den Bereich von +- 1 cm um die Fokusebene zeigt. Entsprechend ist die y-Achse so skaliert, daß sie nur bis ca 0.07 mm (7e-5 m) reicht. In diesem Bereich entspricht die Funktion praktisch einer Geraden.

︡19e48068-c89c-452a-b5cd-6a8abc33f69d︡{"html": "

Das obige Diagramm deckt auf der x-Achse den Entfernungsbereich von 50 cm bis 5 Meter ab, auf der y-Achse einen Zerstreuungskreisdurchmesser bis ca. 1 cm (d.h. 0.01 m).

\n

Und nun ein Ausschnitt aus diesem Diagramm, welches nur den Bereich von +- 1 cm um die Fokusebene zeigt. Entsprechend ist die y-Achse so skaliert, daß sie nur bis ca 0.07 mm (7e-5 m) reicht. In diesem Bereich entspricht die Funktion praktisch einer Geraden.

"}︡ ︠78dac28e-3e80-490d-92ae-46c2ec63cb5a︠ lnnah=line([(nah,0),(nah,c)],rgbcolor=(0.8,0,0)) lnfern=line([(fern,0),(fern,-c)],rgbcolor=(0.8,0,0)) txt=text(u"Unschärfekreis %.3f mm"%(c*1000),(So,c),horizontal_alignment="left") txt2=text(u"Schärfentiefe %.3f m - %.3f m (%.2f mm)"%(nah,fern,(fern-nah)*1000),(So,-c*2),horizontal_alignment="right") p=plot(plot(Cf,So-0.01,So+.01)+lnfern+lnnah+txt+txt2) p.axes_labels(["Entfernung\n(m)","Zerstreuungskreis (m)",]) p.show() ︡983f83ed-2535-4afa-a98f-d014f3784ee8︡{"html": ""}︡ ︠f8799bd6-0ffd-4d0d-86e8-4b5a19d7daf0︠ lnnah=arrow((nah,0),(nah,c),rgbcolor=(0.8,0,0)) lnfern=arrow((fern,0),(fern,-c),rgbcolor=(0.8,0,0)) plot(plot(Cf,So-0.001,So+.001)+lnfern+lnnah,gridlines=True,ticks=[[],None]) ︡b1ac63b7-9e94-4348-bded-f68988b00c78︡{"html": ""}︡ ︠c91fe97d-1899-424b-be46-51226ce9ec39i︠ %html

Das Vorzeichen zeigt hier die Orientierung des Unschärfekreises. Bei einer kreisrunden bzw. symmetrischen Blende sieht man das natürlich nicht.

︡b939296a-e82f-4bc0-9a2b-2459233fa93f︡{"html": "

Das Vorzeichen zeigt hier die Orientierung des Unschärfekreises. Bei einer kreisrunden bzw. symmetrischen Blende sieht man das natürlich nicht.

"}︡