Skip to content

Fix radius/circumferential mesh division settings in BSPM JMAG 2D FEA Analyzer #362

@noguchi-takahiro

Description

@noguchi-takahiro

Abstract

Fix radius/circumferential mesh division settings in BSPM JMAG 2D FEA Analyzer

Context

When we use rotation slide mesh in JMAG, a mesh model is created to divided the rotor and stator into two mesh region. JMAG provides options to specify both the radial and circumferential division numbers for this, and eMach also supports to do this. See the following code:

airgap_mesh_radial_div=5,
airgap_mesh_circum_div=720,

However, if I look into the JMAG file, the checkboxes remain active (checked), while the division number is set property. This means that these settings are not actually applied: here is what airgap mesh looks like, where the slide division is automatically determined by JMAG, i.e., not by us:

image image

Approach

We should add two lines before line 621 in add_mesh method to uncheck these boxes:

def add_mesh(self, study, model):
# this is for multi slide planes, which we will not be usin
refarray = [[0 for i in range(2)] for j in range(1)]
refarray[0][0] = 3
refarray[0][1] = 1
study.GetMeshControl().GetTable("SlideTable2D").SetTable(refarray)
study.GetMeshControl().SetValue("MeshType", 1) # make sure this has been exe'd:
# study.GetCondition(u"RotCon").AddSet(model.GetSetList().GetSet(u"Motion_Region"), 0)
study.GetMeshControl().SetValue(
"RadialDivision", self.config.airgap_mesh_radial_div
) # for air region near which motion occurs
study.GetMeshControl().SetValue(
"CircumferentialDivision", self.config.airgap_mesh_circum_div
) # 1440) # for air region near which motion occurs

I.e.,

        study.GetMeshControl().SetValue(u"AutoGapDivision", 0)  # this is new line
        study.GetMeshControl().SetValue(u"AutoDivision", 0)  # this is new line
        study.GetMeshControl().SetValue(
            "RadialDivision", self.config.airgap_mesh_radial_div
        )  # for air region near which motion occurs
        study.GetMeshControl().SetValue(
            "CircumferentialDivision", self.config.airgap_mesh_circum_div
        )  # 1440) # for air region near which motion occurs

Here is the expected results:

image image

where the number of division in radial is 5 and circumferential is 720.

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