Skip to main content

TapeHeadConfig

Struct TapeHeadConfig 

Source
pub struct TapeHeadConfig {
    pub model: Option<String>,
    pub ja_ms: f64,
    pub ja_a: f64,
    pub ja_alpha: f64,
    pub ja_k: f64,
    pub ja_c: f64,
    pub kv: f64,
    pub isat: f64,
    pub gp: f64,
    pub h_bias: f64,
    pub rp: f64,
}
Expand description

Voltage-driven Jiles-Atherton tape head configuration.

Unlike a transformer core (driven by Ampere-law magnetizing CURRENT, whose knee needs hundreds of mA at studio turns counts), a record/playback head is a tiny gap/coil whose magnetic field is driven by the head GAP VOLTAGE: H = kv * V. With kv chosen so the J-A knee lands at line level (~1 V), tape saturation tracks signal Drive directly.

The J-A hysteresis parameters share physics with the transformer core (Jiles & Atherton 1986; Chowdhury DAFx-19 wave-digital tape realization) but use a SMALL-GEOMETRY head whose saturation occurs at ~1 V:

  • ja_a is reduced vs an output-transformer core so the Langevin knee is reached at the small fields a head produces,
  • the geometry turns/area/path are nominal (the voltage law uses kv, not Ampere’s law, so they only need to be sane positives).

Fields§

§model: Option<String>

Optional named head model (for provenance / future library lookup).

§ja_ms: f64

Jiles-Atherton saturation magnetization (A/m).

§ja_a: f64

Jiles-Atherton anhysteretic shape parameter (A/m).

§ja_alpha: f64

Jiles-Atherton inter-domain coupling.

§ja_k: f64

Jiles-Atherton domain-wall pinning parameter (A/m).

§ja_c: f64

Jiles-Atherton reversible magnetization fraction (0..1).

§kv: f64

Field-per-volt coupling (A/m per V) — places the knee at line level.

§isat: f64

Saturating magnetic current scale (A) — harmonic drive strength.

§gp: f64

Linear leakage conductance (S) keeping the port well-posed.

§h_bias: f64

Fixed record-bias field offset (A/m): asymmetric transfer -> even harmonics (the soft, even-rich tape/transformer colour).

§rp: f64

WDF port resistance (Ω) — sets the scattering port impedance.

Implementations§

Source§

impl TapeHeadConfig

Source

pub fn studio_head() -> Self

A studio record/playback head whose J-A knee lands at ~1 V line level.

Values verified in pedalkernel-rt/tests/tape_head_voltage.rs: THD climbs monotonically from ~0.7% at 0.05 V to ~7% at 2 V, Newton converges in well under the iteration budget, output is finite/stable.

Source

pub fn with_model(model: String) -> Self

Trait Implementations§

Source§

impl Clone for TapeHeadConfig

Source§

fn clone(&self) -> TapeHeadConfig

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 Debug for TapeHeadConfig

Source§

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

Formats the value using the given formatter. Read more
Source§

impl Default for TapeHeadConfig

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl PartialEq for TapeHeadConfig

Source§

fn eq(&self, other: &TapeHeadConfig) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl StructuralPartialEq for TapeHeadConfig

Auto Trait Implementations§

Blanket Implementations§

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<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.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
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 = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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.
§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more