# Differentiation with vectors

## Main Question or Discussion Point

Hi there to all. I am stuck and i want some help to clear my view

When you have defined the vector S=(S_x ,S_y ,S_z) and you have a function like
E_h = k1 (S_x^2 S_y^2 + S_x^2 S_z^2 + S_y^2 S_z^2) + k2 S_z - k3 S_x S_y

and you try to calculate -\frac{\partial E_h}{\partial S} what the result is?

(the S is vector)

My mind has been blocked.... help me please.

## Answers and Replies

Pengwuino
Gold Member
You can't differentiate with respect to a vector. You need to differentiate with respect to the coordinates.

LCKurtz
Homework Helper
Gold Member
I don't understand your notation. For example, what does S_x2 mean?

Are you trying to describe a directional derivative?

I don't understand your notation. For example, what does S_x2 mean?

Are you trying to describe a directional derivative?

If you have S=(Sx,Sy,Sz) then S_x is the x component of S so S_x^2 is (S_x)^2 correctly .

Last edited:
You can't differentiate with respect to a vector. You need to differentiate with respect to the coordinates.
The landau-lifgarbagez equation is

$$\frac{\partial S}{\partial t}= -\gamma S \times H_{eff}$$ where $$S$$ is the magnetization vector and $$H_{eff}$$ is the effective magnetic field. More often you meet the $$H_{eff}$$ to be

$$H_{eff}= - \frac{\partial f }{\partial S}$$ where $$f$$ is a function like $$E_h$$

$$E_h = k_1 (S_x^2 S_y^2 + S_x^2 S_z^2 + S_y^2 S_z^2) + k_2 S_z - k_3 S_x S_y$$

and S is the magnetization vector.

How do you write down the result of $$-\frac{\partial E_h}{\partial S}$$?

Last edited:
D H
Staff Emeritus
You can't differentiate with respect to a vector. You need to differentiate with respect to the coordinates.
Sure you can. Welcome to the wonderful world of tensors.

Hi there to all. I am stuck and i want some help to clear my view

When you have defined the vector S=(S_x ,S_y ,S_z) and you have a function like
E_h = k1 (S_x^2 S_y^2 + S_x^2 S_z^2 + S_y^2 S_z^2) + k2 S_z - k3 S_x S_y

and you try to calculate -\frac{\partial E_h}{\partial S} what the result is?

(the S is vector)

My mind has been blocked.... help me please.
Try to learn the LaTeX system here; it looks like you already know it. Something like this:

When you have defined the vector $$S=(S_x ,S_y ,S_z)$$ and you have a function like
$$E_h = k_1 (S_x^2 S_y^2 + S_x^2 S_z^2 + S_y^2 S_z^2) + k_2 S_z - k_3 S_x S_y$$

and you try to calculate $$-\frac{\partial E_h}{\partial S}$$ what the result is?
What you want to calculate are the components of the vector (actually, a Cartesian tensor) $$-\frac{\partial E_h}{\partial S_{\mu}}$$ where $$\mu$$ indices the vector elements.

What you want to calculate are the components of the vector (actually, a Cartesian tensor) $$-\frac{\partial E_h}{\partial S_{\mu}}$$ where $$\mu$$ indices the vector elements.

So is this the result correct $$-\frac{\partial E_h}{\partial S}= ( -\frac{\partial E_h}{\partial S_x}, -\frac{\partial E_h}{\partial S_y}, -\frac{\partial E_h}{\partial S_z} )$$ ??

D H
Staff Emeritus