∂t2Ψ(r,t)=∇⋅(c2A(r,t)∇Ψ)−κ∂tΨ−μDt1−α∂tΨ−δΨδV(Ψ;θ(r,t))−∫K(r−r′;ξ)(Ψ(r,t)−Ψ(r′,t))dr′+Sstruct(t)+ξ(r,t)
c6767cd verified | document.addEventListener('DOMContentLoaded', function() { | |
| // Initialize wave simulation canvas | |
| const canvas = document.getElementById('waveCanvas'); | |
| const ctx = canvas.getContext('2d'); | |
| // Set canvas dimensions | |
| function resizeCanvas() { | |
| const container = canvas.parentElement; | |
| canvas.width = container.clientWidth; | |
| canvas.height = container.clientHeight; | |
| } | |
| window.addEventListener('resize', resizeCanvas); | |
| resizeCanvas(); | |
| // Simple wave simulation | |
| function simulateWave() { | |
| if (!canvas.width || !canvas.height) return; | |
| ctx.clearRect(0, 0, canvas.width, canvas.height); | |
| // Draw a simple wave for demonstration | |
| ctx.strokeStyle = '#8b5cf6'; | |
| ctx.lineWidth = 2; | |
| ctx.beginPath(); | |
| const amplitude = canvas.height / 4; | |
| const frequency = 0.02; | |
| const phase = Date.now() * 0.001; | |
| for (let x = 0; x < canvas.width; x++) { | |
| const y = canvas.height / 2 + amplitude * Math.sin(x * frequency + phase); | |
| if (x === 0) { | |
| ctx.moveTo(x, y); | |
| } else { | |
| ctx.lineTo(x, y); | |
| } | |
| } | |
| ctx.stroke(); | |
| requestAnimationFrame(simulateWave); | |
| } | |
| // Start simulation | |
| simulateWave(); | |
| }); |