Closed pixelzoom closed 1 month ago
(This comment was originally in #66 on 5/10/24.)
In https://github.com/phetsims/faradays-electromagnetic-lab/commit/9c1861fe137e90a7b533df01d76197033f28e613, I added a query parameter for setting up the constant Bx or gradient Bx field that @ariel-phet suggested in https://github.com/phetsims/faradays-electromagnetic-lab/issues/66#issuecomment-2089265340.
The query parameter is gradientField
, documented as:
// Ignores the magnet model and sets up a static gradient B-field, where all field vectors are (Bx,0), and Bx varies
// linearly over a range. The value for this query parameter is the range of Bx from positions x=100 to x=650.
// These positions will be noted by yellow vertical lines. By is always 0.
//
// This is useful for calibrating the sim, and verifying behavior of the pickup coil. This query parameter affects
// all screens, even though it is only useful in the Pickup Coil and Transformer screens.
//
// Examples:
// gradientField=300,300 creates a constant B-field with (Bx,By) = (300,0) everywhere.
// gradientField=0,300 create a gradient B-field, where Bx changes linearly from 0 to 300, and By is 0 everywhere.
//
Below is a screenshot showing gradientField=0,300
. The vertical yellow lines show the x-range over which the gradient occurs.
I'll need to meet with @ariel-phet to talk more about how he envisions using this.
@ariel-phet and I met yesterday to review the behavior of the pickup coil using the gradientField
query parameter, described in https://github.com/phetsims/faradays-electromagnetic-lab/issues/66#issuecomment-2105392854.
Running with ?dev&gradientField=...
and opening the "Pickup Coil debugger" panel in the Pickup Coil screen...
With gradientField=300,300
(constant-strength field)... We changed the number of loops and loop area, and verified that the flux (Φ) shown in the panel behaved as expected.
With gradientField=0,300
(left-to-right gradient field)... We turned on "Lock to Axis", and moved the bar magnet as far to the left (out of the way) as possible. We slowly dragged the pickup coil left and right, and verified that flux changed as expected. We repeated with various settings for number of loops and loop area.
@arouinfar Do you want to take this for a spin?
Thanks @pixelzoom this was helpful in reviewing #156, closing.
Related to https://github.com/phetsims/faradays-electromagnetic-lab/issues/156 (new flux model) ...
(This was originally put in https://github.com/phetsims/faradays-electromagnetic-lab/issues/66 by mistake on 5/1/24, so I'm moving it here.)
Notes from 5/1/24 meeting with @arouinfar and @ariel-phet.
@ariel-phet said that he had a hard time convincing himself that #156 was correct by just playing with the sim. He had this idea for inspecting flux, which I'll try to summarize here:
Create a field where all vectors point to the right and have the same strength, with a control to change the strength. Move the pickup coil through this field to verify that flux is behaving as expected.
Create a field where all vectors point the right, but the stength increase from [0,max] -- a left-to-right gradient. Move the pickup coil through this field to verify that flux is behaving as expected.
Query parameters for selecting one of these 2 calibration fields.
I'll need to give some thought to the best way to do this.