Line Integral over a vector field

8 views (last 30 days)
I have a vector b that tells me the magnitude of a vector field pointing outwards over half the unit circle (the values are symmetric so if I want the whole circle I just have to repeat the values of b). How can I compute the line integral over the unit circle?
  1 Comment
Roger Stafford
Roger Stafford on 17 Mar 2014
You need more than the magnitude of a vector field if you are to compute a line integral over it. You also need to know the direction in which it points. That is, you need to know each of the field's components as you move along the integration path. You say that the field is "pointing outwards over half the unit circle". If that means the field direction is orthogonal to the tangential direction of the circle, you would necessarily get a zero value for your line integral. If the direction is not orthogonal, you need to use the dot product of the field vector with the path's tangential direction along the path. You need to clarify this matter before we can effectively give help on this problem.

Sign in to comment.

Accepted Answer

Youssef  Khmou
Youssef Khmou on 17 Mar 2014
hi, i think this is similar to the wave vector k, like Roger expressed implicitly, the vector is orthogonal to the wave front which is circle in your case, here is a simple view point :
the variable in this example, k, try to use trapz to integrate, but whats the intuitive result? should the integral equals zero?
t=0:0.01:pi;
x=cos(t);
y=sin(t);
Mag1=linspace(1,2,floor(length(t)/2));
Mag2=linspace(2,1,floor(length(t)/2));
Mag=[Mag1 2 Mag2];
k=Mag+y;
quiver(x,y,x,-k,'>');
hold on;
plot(x,y);
xlabel('x');
ylabel('y');
grid;

More Answers (1)

Kanagala chaitanya
Kanagala chaitanya on 9 Apr 2019
t=0:0.01:pi;
x=cos(t);
y=sin(t);
Mag1=linspace(1,2,floor(length(t)/2));
Mag2=linspace(2,1,floor(length(t)/2));
Mag=[Mag1 2 Mag2];
k=Mag+y;
quiver(x,y,x,-k,'>');
hold on;
plot(x,y);
xlabel('x');
ylabel('y');
grid;

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!