Skip to main content

ReflectedHeatChernoff

Struct ReflectedHeatChernoff 

Source
pub struct ReflectedHeatChernoff<C, R, F = f64>{
    pub region: R,
    /* private fields */
}
Expand description

Chernoff wrapper for Neumann (reflecting) BCs via the image method.

F_refl(τ) f = C(τ)f + C(τ)(f ∘ σ_R) (Walsh 1986 §3.4, math.md §25.3).

order() returns inner.order(): reflection preserves order for symmetric (Neumann) BCs (Proposition 25.1 — commutator vanishes).

§v2.8 scope

Concrete ChernoffFunction<f64> impl for: ReflectedHeatChernoff<DiffusionChernoff<f64>, HalfSpaceRegion<f64, 1>>. Generic-C impls deferred to v2.9 (requires CoordinateState<F, D> supertrait).

Fields§

§region: R

The reflecting region. Stored for future multi-D GridFn2D/GridFn3D impls (deferred to v2.9) and for public inspection by callers.

Implementations§

Source§

impl<C, R, F> ReflectedHeatChernoff<C, R, F>

Source

pub fn new(inner: C, region: R) -> Result<Self, SemiflowError>

Wrap inner Chernoff function with reflecting region region.

§Errors

Returns Err if the inner or region is invalid; always Ok for pre-validated inputs.

Trait Implementations§

Source§

impl ChernoffFunction for ReflectedHeatChernoff<DiffusionChernoff<f64>, HalfSpaceRegion<f64, 1>, f64>

Image-method apply_into for the D=1 half-space on a one-sided grid.

§Implementation note (half-line [0, L] grid)

math.md §25.3 specifies a 4-step full-line algorithm where the ghost h = f ∘ σ_R has support at the OUTSIDE (negative-x) nodes of a full-line grid. For the common case of a one-sided grid [0, L] (all nodes inside R), there are no outside nodes, so ghost = 0 and the 4-step algorithm reduces to a plain inner Chernoff step — NOT the correct Neumann semigroup.

The correct Neumann semigroup on a [0, L] half-line grid is obtained by replacing src.grid.boundary with BoundaryPolicy::Reflect before the inner Chernoff step. This gives the DiffusionChernoff stencil access to the even extension of src at the left boundary (x = 0), which is exactly what the full-line image method computes when restricted to x ∈ [0, L].

Equivalence proof sketch (single node x = 0, pure-heat stencil):

Full-line image method at x = 0:
  step1 = W0*f(0) + W1*f(h)  + W2*f(h')         (src = 0 for x < 0)
  step3 = W1*f(h) + W2*f(h')                     (ghost = f(|x|) for x < 0)
  sum   = W0*f(0) + 2*W1*f(h) + 2*W2*f(h')

Half-line Reflect step at x = 0:
  C_reflect*f(0) = W0*f(0) + W1*(f(h) + f(h)) + W2*(f(h') + f(h'))
                 = W0*f(0) + 2*W1*f(h)          + 2*W2*f(h')  == sum

The equivalence holds at every grid node (interior nodes are unaffected by boundary policy for small tau).

Source§

fn order(&self) -> u32

Order matches inner (Proposition 25.1 — no cap for Neumann BCs).

Source§

fn growth(&self) -> Growth<f64>

Growth: (inner_M, inner_ω) — no doubling on a one-sided grid because the Reflect-boundary step is a single contraction of the inner Chernoff.

Source§

type S = GridFn1D

The state space type on which S(tau) acts. Read more
Source§

fn apply_into( &self, tau: f64, src: &Self::S, dst: &mut Self::S, scratch: &mut ScratchPool<f64>, ) -> Result<(), SemiflowError>

Zero-alloc apply: dst := S(tau) src. Caller provides pre-allocated dst and a scratch pool for hot-path temporaries (ADR-0041 Wave 1). Read more
Source§

fn apply_adjoint_into( &self, tau: F, src: &Self::S, dst: &mut Self::S, scratch: &mut ScratchPool<F>, ) -> Result<(), SemiflowError>

Apply the TRANSPOSE (adjoint) semigroup exp(τ Aᵀ) src into dst. Read more
Source§

fn plan_len(&self, tau: F, proto: &Self::S) -> Option<(usize, usize)>

Sizes (data, work) of a τ-keyed step plan for states shaped like proto (ADR-0215), or None (default) when the engine has no plan. Read more
Source§

fn fill_plan( &self, tau: F, proto: &Self::S, data: &mut [F], ) -> Result<(), SemiflowError>

Fill data (length plan_len(..).0) for (τ, proto). Read more
Source§

fn apply_planned_into( &self, tau: F, data: &[F], work: &mut [F], src: &Self::S, dst: &mut Self::S, scratch: &mut ScratchPool<F>, ) -> Result<(), SemiflowError>

dst := S(τ) src with a plan data filled by THIS engine for τ, and a work area of length plan_len(..).1. A plan that does not match — another τ, sampling grid, length or engine state, or a truncated buffer — falls back to apply_into. Default: apply_into. Read more
Source§

impl<C, R, F> Clone for ReflectedHeatChernoff<C, R, F>

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<C, R, F> Debug for ReflectedHeatChernoff<C, R, F>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<C, R, F> Freeze for ReflectedHeatChernoff<C, R, F>
where C: Freeze, R: Freeze, PhantomData<F>: Freeze,

§

impl<C, R, F> RefUnwindSafe for ReflectedHeatChernoff<C, R, F>

§

impl<C, R, F> Send for ReflectedHeatChernoff<C, R, F>
where C: Send, R: Send, PhantomData<F>: Send,

§

impl<C, R, F> Sync for ReflectedHeatChernoff<C, R, F>
where C: Sync, R: Sync, PhantomData<F>: Sync,

§

impl<C, R, F> Unpin for ReflectedHeatChernoff<C, R, F>
where C: Unpin, R: Unpin, PhantomData<F>: Unpin,

§

impl<C, R, F> UnsafeUnpin for ReflectedHeatChernoff<C, R, F>

§

impl<C, R, F> UnwindSafe for ReflectedHeatChernoff<C, R, F>

Blanket Implementations§

Source§

impl<C, F> Adjointable<F, 1> for C

Source§

fn apply_adjoint_into( &self, tau: F, a: F, b: F, c: F, src: &MeasureState<F, 1>, dst: &mut MeasureState<F, 1>, ) -> Result<(), SemiflowError>

Push-forward one Chernoff step on the measure side (Lemma A.1, §38.3). Read more
Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<C, F> ApplyChernoffExt<F> for C
where C: ChernoffFunction<F>, <C as ChernoffFunction<F>>::S: Clone, F: SemiflowFloat,

Source§

fn apply_chernoff( &self, tau: F, src: &Self::S, ) -> Result<Self::S, SemiflowError>

Allocating single-step apply: returns S(tau) src as a fresh state. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.