Question Regarding SwiftComp in Abaqus

  1. Junyu Wang


    When I run homogenization, the homogenization window returns an error message: "UnboundLocalError: Local Variable 'nSG' referenced before assignment".

    So I have created a 3-D model for the plate SG and assigned material properties to the fiber and matrix before running homogenization. I also chose the plate model for macrostructure as prompted. Did anyone run into a similar problem?

    I have consulted with the user manual but found no useful information related to this.


  2. Su Tian

    Hello Junyu,

    My guess is that you are creating your own 3D SG, correct? For the current version of the GUI, only the built-in 3D SG (spherical inclusion) created from the toolbar is supported.

  3. Junyu Wang

    Yes. I was using the Abaqus SwiftComp GUI with a 3D SG I made

  4. Junyu Wang

    Correct. If that is the case, is there any suggestions on how to analyze the SG? Since the only built in 3D SG is with spherical inclusion but what I need is cylindrical inclusion, like a fiber reinforced composite.

  5. Wenbin Yu

    Have you studied the videos at ---- Emailed forum response from
  6. Bo Peng

    Could you please confirm if the model has been meshed ? Sent from my iPhone ---- Emailed forum response from
  7. Dhananjay Sriharsha Rao

    Hi Did you try the 2D SG for fiber reinforced composite. But if you need the 3D SG, you can generate an input file from the GUI and use it to write the SwiftComp file and run the SwiftComp file using command. Regards On Thu, 5 Dec 2019 at 00:09, Junyu Wang @ cdmHUB - The Composites HUB <> wrote: ---- Emailed forum response from
  8. Bo Peng

    Hi Junyu,

    Could you please confirm if the model has been meshed ? When the part you are using for homogenization is not meshed, the error message will show. Please let me know if the error message is still there when the part is meshed.

    Best regards,


  9. Mason Wu

    Hi all, 

    I am having the same issue as Junyu encountered - same error message. 

    1. I have my part meshed.

    2. I followed the youtube video exactly.

    Please see the attached error message.

    Do I need to set the work directory the same place where I have SwiftComp?


    Thank you



  10. Junyu Wang

    I tried again after meshing the part. It worked. Thanks!