You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So maybe to fix this the methods moving the object such as shift, move_to, to_corner should be overrided? The thing is we can't be 100% sure that all the methods modifying the object's position have been taken into account. Maybe there's a more general way of fixing this.
The text was updated successfully, but these errors were encountered:
So whenever a
Charge
object is instanciated, the attributepoint
is set:manim-physics/src/manim_physics/electromagnetism.py
Lines 16 to 40 in 70ab45a
but this attribute is not updated when using methods such as
move_to
orshift
:This implies some incorrect behaviour e.g. when using
ElectricField.get_force_on_charge
:Result
You can see here that the
f
vector is still located on the origin, where thecharge_2
was previously located.This happens because the code of the
get_force_on_charge
method is using thecharge.point
attribute L147:manim-physics/src/manim_physics/electromagnetism.py
Lines 129 to 149 in 70ab45a
So maybe to fix this the methods moving the object such as
shift
,move_to
,to_corner
should be overrided? The thing is we can't be 100% sure that all the methods modifying the object's position have been taken into account. Maybe there's a more general way of fixing this.The text was updated successfully, but these errors were encountered: