u/RotemT

544 post karma · 90 comment karma · joined Jun 2020

RotemT

I think the key to understanding electromagnetic waves is to first understand how electric and magnetic fields behave even when there are no waves involved.

Let’s start with static fields.

A stationary electric charge produces an electric field around it. For a point charge, the field strength decreases as (1/r^2), where (r) is the distance from the charge. Similarly, a steady electric current produces a magnetic field around it.

More generally, the fields produced by finite, localized sources tend to become weaker as we move farther away from them. There are exceptions for idealized infinitely extended sources. For example, the electric field of an infinite uniformly charged plane is independent of distance.

So where do electromagnetic waves come into the picture?

Now imagine that instead of keeping our charges stationary or our currents constant, we start moving the charges back and forth or changing the currents.

This changes the electric and magnetic fields around the sources. However, these changes don’t happen instantaneously everywhere in space. Instead, disturbances in the electromagnetic field propagate outward at the speed of light in vacuum. (At least far enough away from the sources. Close to them it depends how you define the speed of propagation which is not trivial)

What’s particularly interesting is that once such a disturbance has been generated, it can continue propagating even after the source stops oscillating. It carries energy and momentum away from the source.

You can think of it somewhat like clapping your hands. Your hands produce a brief disturbance in the surrounding air, but the resulting sound wave keeps traveling outward long after your hands have stopped moving. Electromagnetic waves are similar in that respect, except that they don’t need a material medium to propagate.

These propagating electromagnetic disturbances are what we call electromagnetic waves, or electromagnetic radiation.

Far enough away from a finite source in vacuum, the electric and magnetic fields associated with the outgoing radiation generally decrease in amplitude as (1/r). This is different from the (1/r^2) dependence of the static electric field of a point charge.

But why do we represent these waves using sine and cosine functions?

An electromagnetic disturbance doesn’t necessarily have to be sinusoidal. A short pulse, for example, can also propagate through space.

However, sine and cosine functions are particularly useful because any sufficiently well-behaved time-varying signal can be decomposed into sinusoidal components of different frequencies. This is the idea behind Fourier analysis.

They’re also mathematically special: differentiating a sine or cosine gives another sine or cosine (possibly with a different amplitude or phase). This makes them especially natural solutions to the linear differential equations governing electromagnetic waves.

And sinusoidal excitation is not just a mathematical abstraction. Many real electrical systems, including AC circuits and antennas driven by sinusoidal currents, operate this way.

Now suppose we have an antenna carrying a sinusoidally oscillating current at a single frequency.

Because Maxwell’s equations are linear in vacuum, the resulting electromagnetic field will also oscillate at that frequency, although its amplitude, direction and phase can vary from one position to another.

Far away from the antenna, in any direction where it radiates, the outgoing field approaches a particularly simple form.

If you stay at a fixed point in space, the field oscillates with time. For a linearly polarized wave, it can point in one direction, decrease to zero, reverse direction, and repeat.

If instead you freeze time and look at the field along a line extending away from the source, you will find a spatially oscillating pattern, but with a gradually decreasing amplitude.

So yes, the sinusoidal oscillation and the decrease in field strength with distance happen simultaneously! They describe two different aspects of the same field.

The sine curve is therefore not the physical path that the electromagnetic wave travels along. It describes how a component of the field varies in space and time.

In the far field, the electric and magnetic fields are perpendicular to each other and to the direction of propagation. They oscillate in phase, and their magnitudes are related by (E=cB).

For a directional antenna, the radiated power is distributed unevenly across the sphere, but the same distance dependence still holds in the far field for any fixed direction with nonzero radiation.

What about the plane waves we often see in textbooks?

When we look at a sufficiently small region very far from a source, the outgoing wavefront is approximately flat, just as a small patch of Earth’s surface looks flat even though the Earth is spherical.

In that small region, the change in amplitude with distance is negligible, so we can approximate the field as a plane wave with constant amplitude.

This doesn’t contradict the inverse-square law! A real, finite antenna produces radiation whose field amplitudes decrease approximately as (1/r), so the energy flux decreases as (1/r^2). The local plane-wave approximation simply ignores this gradual decrease over a small region.

Finally, can these waves actually move electric charges?

Absolutely!

A charged particle placed in an oscillating electric field experiences an electric force

If the particle is moving, there can also be a magnetic force.

As the electric field changes direction, so does the electric force. A free charge can therefore be driven into oscillatory motion.

And here’s the interesting part: an accelerating charge can itself generate electromagnetic radiation, creating additional disturbances in the surrounding field.

This is closely related to how antennas transmit and receive electromagnetic waves.

I actually built an interactive electromagnetic field simulator partly because I wanted to make these concepts easier to visualize. You can place antennas, change their frequencies, amplitudes and phases, and watch how their electric and magnetic fields evolve and propagate through space. You can also explore interference, polarization and energy flow.

If you’re interested, you can play with it here: https://www.antennasim.com/

I’d suggest starting with a single dipole and observing how the field behaves close to it compared with farther away. I think seeing the fields evolve in time helps connect the equations to the actual physical phenomena.

RotemT

I think I will try that. Thanks for the suggestion!

RotemT

There is an option to adjust the heat map by gamma transformation but currently the spacing is linear. I could add an option to display the axes in log scale or some power scale

RotemT

Maybe one of Paul Falstad’s applets ?

They are really nice to play with.

RotemT

Thanks that helps a lot

RotemT

And sorry to bother you but did you get the message: “this connection is not private?”
Or did you get another warning ?

RotemT

Thanks for the heads up!

RotemT

Thanks for the feedback :)

RotemT

What about it screams AI? (Genuinely curious)

I actually started this project about two years ago, originally writing the simulation from scratch in Java (Processing).

Last year I decided to turn it into a website, and I used ChatGPT to help port the code to JavaScript and improve the UI, since web development isn’t really my area of expertise.

The physics, numerical modeling, and development of new features are things I’ve been working on myself, although AI has certainly helped with implementation.

So I can understand why parts of the website might look AI-generated, but there’s quite a bit of original work behind it :)

RotemT

Hi, I’m Rotem and I am here to learn new things and maybe help other too

RotemT

This is very cool!

RotemT

😞

RotemT

Thanks :)

RotemT

Thats weird, thanks for the heads up!
:)

RotemT

Hi :)

Its a website that lets users visualize radiation.
You can place and interact with different sources of radiation and see how the electromagnetic field is affected.

You can choose which field you want to see (electric, magnetic or energy flow field). The default is the electric field.

RotemT

Thanks!😊

RotemT

Why are you so quick to assume this was AI generated?

Did I use AI to improve UI? Yes,
but I have been working on this side project since before any of the LLMs were useful enough to help

RotemT

Thanks so much:).

And I agree , gauge theory is a beautiful powerful tool. I might try to simulate different fields in the future like Klein Gordon or a Fermion field.

What sort of fields have you simulated?

Do you have any links?

RotemT

Thanks so much for your time :)

RotemT
RotemT

Yeah that’s also a good idea. To let the user freely choose the slices

RotemT

I really want to but I am not sure what’s the best way to display the fields. I could just show 3D arrows or the radiation pattern but many professional tools already do that. I just wanted to make something cute to play with

RotemT

I programmed the simulation from scratch in Java more than 2 years ago without using LLMs.

But to be honest I did use chat GPT to convert the code to JavaScript and improve the UI so it would look like a decent website so I understand why it might look completely vibe coded

RotemT

🤯

RotemT

The video shows how the website looks. In the example there are two pependicular Hertzian dipoles of equal electric moment and half pi phase shift. At first first the magnetic field is displayed and later the the electric field is displayed instead.