pub struct PupilFunction {
pub field: FieldSel,
pub wave: usize,
pub ref_primary: bool,
pub grid: PupilGrid,
pub samples: PupilSamples,
pub opd: Vec<f64>,
pub mask: Vec<bool>,
pub rays: RayBuf,
pub chief: Trace,
pub reference: RefSurface,
pub amp: Vec<f64>,
}Expand description
1 つの視野・波長の瞳関数: 格子の標本ごとの光線と OPD [波]
Fields§
§field: FieldSel§wave: usize波長の番号
ref_primary: bool参照球の中心が主波長の主光線か(false なら波長 wave 自身の主光線)
grid: PupilGrid§samples: PupilSamples§opd: Vec<f64>標本ごとの OPD [波]((参照の主光線の光路 − 光線の光路) / λ。使えない標本の値は意味を持たない。Self::mask)
mask: Vec<bool>使える標本(像面に届き、OPD が有限)
rays: RayBuf標本の光線の列(波長 wave、crate::system::Cols::WAVE)
chief: Trace参照球の中心に使った主光線の追跡(ref_primary なら主波長、でなければ波長 wave)
reference: RefSurfaceOPD の基準の面
amp: Vec<f64>標本ごとの振幅(系のアポダイゼーション × 選んだ膜・偏光の振幅、WaveAmp。どこでも 1 なら全部 1.0)。
区間の面積の割合などの重み(samples.wt)は含まない
Implementations§
Source§impl PupilFunction
impl PupilFunction
Sourcepub fn trace(
s: &System,
field: FieldSel,
wave: Option<usize>,
grid: PupilGrid,
ref_primary: bool,
) -> Result<Arc<PupilFunction>>
pub fn trace( s: &System, field: FieldSel, wave: Option<usize>, grid: PupilGrid, ref_primary: bool, ) -> Result<Arc<PupilFunction>>
視野 field・波長 wave(None で主波長)の格子 grid の光線を追い、OPD を求める。解析が瞳の格子の光線を追うのは
ここだけ。結果は系の中にしまい([PupilCache])、同じ系・同じ引数ならもう 1 度は追わない(系を直すと捨てる)
Sourcepub fn trace_amp(
s: &System,
field: FieldSel,
wave: Option<usize>,
grid: PupilGrid,
ref_primary: bool,
extra: Option<&dyn PupilAmp>,
) -> Result<Arc<PupilFunction>>
pub fn trace_amp( s: &System, field: FieldSel, wave: Option<usize>, grid: PupilGrid, ref_primary: bool, extra: Option<&dyn PupilAmp>, ) -> Result<Arc<PupilFunction>>
Self::trace に、膜・偏光の振幅 extra(PupilAmp)を足す。extra があるときはしまわない
pub fn is_empty(&self) -> bool
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PupilFunction
impl RefUnwindSafe for PupilFunction
impl Send for PupilFunction
impl Sync for PupilFunction
impl Unpin for PupilFunction
impl UnsafeUnpin for PupilFunction
impl UnwindSafe for PupilFunction
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more