Force between two charged rods? Suppose that we have two rods of length $l_1, l_2$ connected at one end but free to rotate. These rods have charge density $\lambda$ uniformly distributed, so the total charge of rod $i$ is $\lambda l_i$. Given an interior angle between them $\theta$, what is the force between the two rods? What is the torque?
Idea for a solution: find the force on a particle with charge $d\lambda$ from a finite-length rod then integrate over the whole rod. However, it's been a while since I last took an E&M class, so I'm not sure how to do that. I'm also not sure what the torque would be; $k\sin \theta$ makes the most sense until you realize that that would also mean small torque for small angles, which is wrong. This indicates the torque must be discontinuous at $\theta = 0$. Something proportional to $\cot \frac{\theta}{2}$ is my  best bet.
Edit: this is not homework, though it appears to be. I just thought of it and couldn't easily solve it.
 A: Since this is a homework-type problem, here are some
Hints for the force


*

*The electrostatic force $d\vec F$ on a small segment $dl$ of the rod given the field $\vec E$ of the other rod is
$$
  d\vec F = \lambda\, dl \,\vec E
$$

*Determine the field of one rod, and use the above expression to integrate the force it exerts on the other rod.

*This is a 2D problem since, by symmetry, the force is in the plane containing both rods.
Hints for the torque


*

*Take the point at which both rods are joined as the origin, then the torque on a small segment of one rod due to the field of the other is
$$
  d\vec \tau = \vec r\times d\vec F
$$
where $\vec r$ is the vector pointing from the origin to the segment.

*Integrate to find the total torque.
Addendum 1.
I started solving this problem, then I got to integrals I needed to compute to determine the electric field of one rod at a general location on the other, and I realized that there is no solution to this problem as stated.  The force between the two charge elements at the end of each rod where they are joined is infinite (because the distance between them is zero).  You can make this problem well-posed by considering a charge densities $\lambda_1, \lambda_2$ that goes to zero sufficiently quickly at the point where the rods are joined so that the integrals you have to perform don't diverge, but that would be a different problem.
Addendum 2.
I pointed out in the comments that the integrals you would need to compute to obtain the force between uniformly charged rods with joined endpoints diverges because of the charges that are at zero distance from one another at the vertex (place where the rods are joined).
Here are the integrals you need to compute as requested.  Take rod 1 to be on the positive $x$-axis with left-hand endpoint at the origin, and take rod 2 to be angled at some $\theta$ measured counterclockwise from the positive $x$-axis with it's left endpoint at the origin as well.  Let $r_1$ denote the radial coordinate along rod 1 and let $r_2$ denote the coordinate along rod 2 with $r_1=r_2=0$ at the origin.  Given any two points on the rods located at radial distances $r_1$ and $r_2$, the squared distance between these points is
$$
  d^2 = r_1^2+r_2^2-2r_1r_2\cos\theta
$$
which comes from some basic vector algebra, or equivalently, the law of cosines.  Now, let's say we're computing the force on rod $2$ by rod $1$, then we also need the expression for the vector pointing from the point at position $r_1$ on rod 1 to the point at position $r_2$ on rod 2.  This is given by
$$
  \vec d = (r_2\cos\theta -r_1)\,\hat x+r_2\sin\theta\,\hat y
$$
The force of charge element $dq_1 = \lambda_(r_1)dr_1$ one charge element $dq_2 = \lambda_2(r_2) dr_2$ at the positions $r_1$ and $r_2$ along the rods is given by Coulomb's Law;
$$
  d\vec F = \frac{1}{4\pi\epsilon_0}\frac{dq_1dq_2}{d^3}\vec d
= \frac{1}{4\pi\epsilon_0}\frac{\lambda_1(r_1)dr_1\lambda_2(r_2)dr_2 ((r_2\cos\theta -r_1)\,\hat x+r_2\sin\theta\,\hat y)}{(r_1^2+r_2^2-2r_1r_2\cos\theta)^{3/2}}
$$
and the desired force is given by and integral over the lengths of both rods from $0$ to the length of each rod;
$$
  \vec F = \frac{1}{4\pi\epsilon_0}\int_{0}^{\ell_1} dr_1\int_0^{\ell_2} dr_2
\frac{\lambda_1(r_1)\lambda_2(r_2) ((r_2\cos\theta -r_1)\,\hat x+r_2\sin\theta\,\hat y)}{(r_1^2+r_2^2-2r_1r_2\cos\theta)^{3/2}}
$$
Now you can simply play around with the function forms of $\lambda_1$ and $\lambda_2$ to determine what sorts of charge distributions give convergent integrals!
A: As joshphysics' answer showed, the force would indeed be infinite in the case of uniform lineic distributions, but the torque does not need to be. Using the same conventions joshphysics did, let's compute the elementary torque $d\vec{T}$ experienced by a piece $dr_2$ of rod 2 at position $\vec{r_2}$ from the joining point and integrate it over rod 2. It can be written
$$
\begin{array}{rcl}
\vec{T} &=& \int_0^{\ell_2}d\vec{T} \\
 &=& \int_0^{\ell_2}\vec{r_2}\wedge\lambda_2dr_2\int^{\ell_1}_0 
\frac{1}{4\pi\varepsilon_0}
\frac{\lambda_1dr_1}{({r_1}^2+{r_2}^2-2r_1r_2\cos\theta)^{3/2}}\,(\vec{r_2}-\vec{r_1})\\
\vec{T}
&=&\frac{1}{4\pi\varepsilon_0}
\int_0^{\ell_2}\int_0^{\ell_1} \frac{\lambda_1\lambda_2\,r_1r_2\sin\theta\,dr_1dr_2}{({r_1}^2+{r_2}^2-2r_1r_2\cos\theta)^{3/2}}\hat{z}
\end{array}
$$
To make the integration easy, let's suppose that $\theta=\pi/2$, so that we have first to compute
$$
\int_0^{\ell_1}\frac{r_1\,dr_1}{({r_1}^2+{r_2}^2)^{3/2}} = 
\left[-\frac{1}{\sqrt{{r_1}^2+{r_2}^2}}\right]_0^{\ell_1} = \frac1{r_2}-\frac1{\sqrt{{\ell_1}^2+{r_2}^2}}
$$
so that finally
$$
\vec{T} = \frac{\lambda_1\lambda_2}{4\pi\varepsilon_0}
\int_0^{\ell_2}\left(1 - \frac{r_2}{\sqrt{{\ell_1}^2+{r_2}^2}}\right)dr_2\,\hat{z}
$$
that can be integrated similarly as the previous one to give, if I'm not mistaken,
$$
\vec{T} = \frac{\lambda_1\lambda_2}{4\pi\varepsilon_0}\left(\ell_2+\ell_1 -\sqrt{{\ell_1}^2+{\ell_2}^2}\right)\hat{z}
$$
A: Physical intuitiion
I imagine that $\theta=\pi$ is a stable equilibrium and $\theta=0$ will be an unstable equilibrium. So the torque should be zero at $\theta=0$ and slowly (linearly) increase for small $\theta$, but in a direction which drives the system away from equilibrium. So $\tau \sim k \, \sin \theta$ seems like a reasonable conjecture for perturbations from the equilibria.
Find the potential energy of the system
Consider a small element in rod1 and find it's potential energy due to rod 2. Thsi will involve an integration over rod2. Now, integrate over rod1 to find the total potential energy of the system. Both integrations are over scalars... no mess with multiple components and projections. You will get an expression for the system's potential energy as a function of the angle between the rods.
Finding the torque
Fix your coordinate sustem with the origin at the hinge and (say) X-axis along rod2. Then, effectively, you only have 1 degree of freedom: the angle $\theta$ between the rods. To find the torque $\tau$, differentiate the expression for potential energy w.r.t $\theta$.
If you want to find the force, you could invert the expression $\int_0^L F(r) \, r\, dr = \tau$ to find $F(r)$ and then integrate that along the rod to find the tangential component of the force.
