Skip to content

Magnetoelastic effective field equation is missing a 2*B2 #323

@marcrovi

Description

@marcrovi

The magnetoelastic energy is written as:

$$ E_{me} = B_1(E_{xx}m_{x}^2 + E_{yy}m_{y}^2 + E_{zz}m_{z}^2) + 2B_2(E_{xy}m_{x}m_{y}+E_{xz}m_{x}m_{z}+E_{yz}m_{y}m_{z}) $$

And the effective field is: $\mu_0 h_{me} = -\nabla_{m} E_{me}$
Therefore, for example, the effective field in $m_x$ would be:

$$ h_{me}^x = -2B_1 E_{xx}m_x + 2B_2( E_{xy}my + E_{xz} m_z) $$

The article: https://doi.org/10.12688/openreseurope.13302.1 explains how the model is implemented and in this github link you can find the code: https://github.com/Fredericvdv/Magnetoelasticity_MuMax3/blob/eeb112dff216a4ae3267fc27fe67aa0e7ada6423/cuda/magnetoelasticfield.cu

The effective field terms are:

            Bx[I] += -2.0f*(B1*m.x*Exx + B2*(m.y*Exy + m.z*Exz));
	    By[I] += -2.0f*(B1*m.y*Eyy + B2*(m.x*Eyx + m.z*Eyz));
	    Bz[I] += -2.0f*(B1*m.z*Ezz + B2*(m.x*Ezx + m.y*Ezy)); 

Where the 2.0f multiplied both B1 and B2. In the MuMax3 repository I found:

	    Bx[I] += -(2.0f*B1*m.x*Exx + B2*(m.y*Exy + m.z*Exz));
	    By[I] += -(2.0f*B1*m.y*Eyy + B2*(m.x*Eyx + m.z*Eyz));
	    Bz[I] += -(2.0f*B1*m.z*Ezz + B2*(m.x*Ezx + m.y*Ezy));

The parenthesis should be after the 2.0f.

I did a Pull Request to address this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions