/** * RegularGrid3D — Uniform 3D scalar/vector field for PDE solvers. * * Flat Float32Array storage with stencil operations (laplacian, gradient, divergence) * for finite difference methods. Shared by thermal, structural, and hydraulic solvers. */ export declare class RegularGrid3D { readonly nx: number; readonly ny: number; readonly nz: number; readonly components: number; readonly dx: number; readonly dy: number; readonly dz: number; readonly data: Float32Array; constructor(resolution: [number, number, number], domainSize: [number, number, number], components?: number); /** Flat index for cell (i, j, k) component c */ private idx; get(i: number, j: number, k: number, component?: number): number; set(i: number, j: number, k: number, value: number, component?: number): void; /** Total number of cells */ get cellCount(): number; /** * Discrete Laplacian ∇²f at (i,j,k) using 2nd-order central differences. * * BOUNDARY CONTRACT: This solver uses a flat array without ghost cells. * At boundaries (e.g. i=0 or i=nx-1), the partial derivative in that * direction is skipped. This results in a partial Laplacian which implicitly * enforces a homogeneous Neumann boundary condition (∂T/∂n = 0 / zero flux) * if no explicit boundary condition overwrites it after integration. */ laplacian(i: number, j: number, k: number, component?: number): number; /** * Gradient ∇f at (i,j,k) using central differences. * Falls back to one-sided differences at boundaries. */ gradient(i: number, j: number, k: number, component?: number): [number, number, number]; /** * Divergence ∇·F for a 3-component vector field at (i,j,k). * Components 0,1,2 = x,y,z. */ divergence(i: number, j: number, k: number): number; fill(value: number): void; copy(other: RegularGrid3D): void; /** this.data += scale * other.data (element-wise) */ addScaled(other: RegularGrid3D, scale: number): void; /** L∞ norm (max absolute value) */ maxAbs(): number; /** L2 norm */ norm2(): number; /** Direct reference to the flat data buffer (for ScalarFieldOverlay) */ toFloat32Array(): Float32Array; /** * Sample grid values at mesh vertex positions via trilinear interpolation. * @param positions Flat xyz vertex positions [x0,y0,z0, x1,y1,z1, ...] * @param domainOrigin World-space origin of the grid domain * @param component Which component to sample (default 0) */ sampleAtPositions(positions: Float32Array, domainOrigin?: [number, number, number], component?: number): Float32Array; /** * Create a deep clone of this grid. */ clone(): RegularGrid3D; } //# sourceMappingURL=RegularGrid3D.d.ts.map