# Math Help - Vector field help

1. ## Vector field help

Hello!

One of my assignments is to create a vector field resembling a tornado, shape-wise, at least...

I've gotten the basic shape of the tornado, given by the function f(x,y) = 2*ln(x^2+y^2)... How would I go about converting this function to a vector field resembling this shape?

2. I assume the function you've given is a surface $z=2\ln{(x^2+y^2)}$ where the magnitude of the velocity is constant. You need to also say how the speed changes when you move away from the surface.

So you'll need a function of the form:

$\text{speed}=f(x,y,z)$

To get this function, you'll probably want to simplify the equation for your surface, then write an expression that is constant on your surface and increases when $x^2+y^2$ decreases.

The direction at (x,y,z) will be (y,-x,0), which will make the wind go in a circle clockwise around the z-axis. It needs to be a unit vector, so:

$\text{direction}=(\frac{y}{\sqrt{x^2+y^2}},\frac{-x}{\sqrt{x^2+y^2}},0) \text{ or } \frac{y}{\sqrt{x^2+y^2}}i-\frac{x}{\sqrt{x^2+y^2}}j$

and to get your vector field, just multiply speed by direction.

Post again if you're still having trouble.

Let's say if I were to model the speed with something like 1/e^(x^2+y^2) because it's a tornado and tornadoes have 0 outside and inside of the "wall"... (Well, 0 is impossible without piecewise functions, so really, really small magnitudes will suffice)... How would I go about doing the actual modeling and integrating with the direction vector?

Sorry, I've just gotten into vector fields and my teacher threw this assignment at me so I don't really have the hang of it yet... Please bear with me.

4. Ok. You can make the speed $1/e^{x^2+y^2}$. Of course, that will mean that everything is independent of z. So we don't really need to keep z around - we can just use 2 dimensions. Vector fields still work in 2 dimensions, so that's not really a problem.

A vector field is just a vector for every point, and a vector is just magnitude and direction. If the direction is a unit vector $\frac{u}{r}i+\frac{v}{r}j\text{, where }r=\sqrt{u^2+v^2}$, you just multiply the unit vector by the magnitude r to get the actual vector ui + vj.

If the components u and v of the vector are functions of the coordinates x and y, you have a vector field u(x,y)i + v(x,y)j. In three dimensions, it would look like u(x,y,z)i + v(x,y,z)j + w(x,y,z)k.

So you have the speed (which is the magnitude of the velocity vector) and the direction unit vector (which I gave you in my previous post). Multiply them together to get the equations of the vector field:

$v(x,y)\text{ = speed * direction = }1/e^{x^2+y^2} * \left(\frac{y}{\sqrt{x^2+y^2}}i-\frac{x}{\sqrt{x^2+y^2}}j\right)$, and substituting $r=\sqrt{x^2+y^2}$ gives us:

$v(x,y) = \frac{y}{re^{r^2}}i-\frac{x}{re^{r^2}}j\text{, where }r=\sqrt{x^2+y^2}$.

Hope that helps! Post again if there's something you don't understand.

5. Thank you! I think I understand the concept a lot more now...

But the problem still remains.
My goal is to create a vector field that resembles a tornado and the surface z = 2*ln(x^2+y^2), but I'd assume, as you said, it's a constant function... Is it possible to integrate the properties of 1/e^(x^2+y^2) with the surface z = 2*ln(x^2+y^2)?

Sorry if I sound a little lost!

6. Let's set the speed to be 1 on z = 2*ln(x^2+y^2) and behaving as 1/e^(x^2+y^2) when off the curve.

Let q0 be the value e^(z/2) of x^2+y^2 when speed=1. Let q=x^2+y^2. So we want speed=1 when q=q0 and speed goes like 1/e^q. So the equation is speed=1/e^(q-q0). Substituting in gives:

speed = 1/e^(x^2-y^2-e^(z/2))

Is that what you're looking for?