Can someone verify a computational result for me?

  • Thread starter Thread starter cowmoo32
  • Start date Start date
  • Tags Tags
    Computational
AI Thread Summary
In a computational physics class, two students are comparing results from different code implementations for calculating the electrostatic potential of a finite charged wire segment, yielding vastly different values. One student calculates a potential of approximately 0.0995, while the other gets 10,596, indicating a significant discrepancy. The charge density along the wire is defined as λ=λ0cos(πx/2L), and there is a discussion about the antisymmetry of the charge distribution affecting the potential. The students have not yet covered this topic in their introductory E&M class, making it difficult to verify their results analytically. The conversation highlights the challenges in computational physics when discrepancies arise in expected outcomes.
cowmoo32
Messages
121
Reaction score
0
This is for a computational physics class, but isn't a homework question, per se. My friend and I have two different sets of code trying to achieve the same thing and we're getting vastly different answers, orders of magnitude apart. We haven't covered this sort of problem in our intro E&M class yet so we aren't able to confirm a result by hand.

Using a λ0 value of 1e-6 and L = 0.5m I'm getting V = ~0.0995 and he's getting 10,596.

Write a Python code that computes the electrostatic potential of a finite segment of charged wire of length 2L, at a height H=L above the center of the wire. The charge density along the wire varies as λ=λ0cos\frac{Pi*x}{2L}
http://moodle.wolfware.ncsu.edu/file.php/33699/Lesson12/wire.png
 
Physics news on Phys.org
Isn't that charge distribution antisymmetric, so the charge density at the point L-x along the wire is the negative of the charge density at the point L+x? Since the distance of these points to the point at a distance L in the middle of the wire is the same, the the contributions to the potential of these points cancels.
 
-delete- I did it wrong.
 
Last edited:
Thread 'Question about pressure of a liquid'
I am looking at pressure in liquids and I am testing my idea. The vertical tube is 100m, the contraption is filled with water. The vertical tube is very thin(maybe 1mm^2 cross section). The area of the base is ~100m^2. Will he top half be launched in the air if suddenly it cracked?- assuming its light enough. I want to test my idea that if I had a thin long ruber tube that I lifted up, then the pressure at "red lines" will be high and that the $force = pressure * area$ would be massive...
Back
Top