07-03-2019 04:45 AM - edited 07-03-2019 04:45 AM
Hello experts, in NX12 it's possible to define weighting factors for RBE3 interpolation elements. That sounds really good. But modifying it individually is really difficult if the amount of independent nodes or grid points raises.
Is there a way to define functions maybe by means of geometric information to keep into account the distance from center grid point to independent grid points respectively?
if (distance >100 [mm]) then (Weighting_Factor = 0.) else ( Weighting_Factor = 1.)
or
if (distance >100 [mm]) then (Weighting_Factor = 100/(distance)^2) else (Weighting_Factor = 1.)
When defining the weighting factor it's possible to use an expression instead of a primitive real number and the value of expression is placed into DOF entry. But, It's not associative, changing the expression does not change the weighting factor. And the expression is constant, it would be better to use a function or table field for weighting factors.
Who can help? - All suggestions are welcome. Best wishes, Michael
07-03-2019 02:14 PM
Expressions cannot be used in the EAD UI.
For this particular case, if you renumbered the nodes so that the nodes on the inner ring were in one range and the nodes in the outer ring were in another, you could define the weighting values for one node in the range, then copy/paste those values into the table cells for the other nodes in that range (ranges of cells can be copied/pasted just like Excel).
For more complicated scenarios, a NX Open journal can be written to compute and set the appropriate value for each node/dof.
07-04-2019 04:10 AM - edited 07-04-2019 04:43 AM
indeed there could be a nice Nx.open programme there. A few things to flush out...
For Each theFEElm As CAE.FEElement In InListofFEElemSelected Dim arrtheFENodes() As CAE.FENode = theFEElm.GetNodes 'Find Independent Node theIndNode Dim theIndNodecoordinates As Point3d = arrtheFENodes(0).Coordinates For Each Node In arrtheFENodes() If Node.Label = theIndNode.Label Then Continue For Else Dim thecoordinates As Point3d = arrtheFENodes(1).Coordinates 'Calculate distance Dim xDiff As Double = Math.Abs(theIndNodecoordinates.X - thecoordinates.X) Dim yDiff As Double = Math.Abs(theIndNodecoordinates.Y - thecoordinates.Y) Dim zdiff As Double = Math.Abs(theIndNodecoordinates.Z - thecoordinates.Z) distance = Math.sqrt(xDiff^2 + yDiff^2 + zDiff^2) If WeiggingOption = 1 Then if distance >100 then Weighting_Factor = 0 Else Weighting_Factor = 1. End if Else 'WeighingOption = 2 If distance >100 then Weighting_Factor = 100/(distance)^2) Else Weighting_Factor = 1. End if 'allocate Weighting_Factor to the node Next Node Next theFEElm
07-04-2019 04:45 AM - edited 07-04-2019 04:46 AM
a nice programm to be thought of here indeed. A few things to flush out...
For Each theFEElm As CAE.FEElement In InListofFEElem Dim arrtheFENodes() As CAE.FENode = theFEElm.GetNodes 'Find Independent Node theIndNode Dim theIndNodecoordinates As Point3d = arrtheFENodes(0).Coordinates For Each Node In arrtheFENodes() If Node.Label = theIndNode.Label Then Continue For Else Dim thecoordinates As Point3d = arrtheFENodes(1).Coordinates 'Calculate distance Dim xDiff As Double = Math.Abs(theIndNodecoordinates.X - thecoordinates.X) Dim yDiff As Double = Math.Abs(theIndNodecoordinates.Y - thecoordinates.Y) Dim zdiff As Double = Math.Abs(theIndNodecoordinates.Z - thecoordinates.Z) distance = Math.sqrt(xDiff^2 + yDiff^2 + zDiff^2) If WeightingOption = 1 Then if distance >100 then Weighting_Factor = 0 Else Weighting_Factor = 1. End if Else 'WeightingOption = 2 If distance >100 then Weighting_Factor = 100/(distance)^2) Else Weighting_Factor = 1. End if 'allocate Weighting_Factor to the node Next Node Next theFEElm
07-04-2019 05:07 AM
a few things to flush out but still...
For Each theFEElm As CAE.FEElement In InListofFEElem Dim arrtheFENodes() As CAE.FENode = theFEElm.GetNodes 'Find Independent Node theIndNode Dim theIndNodecoordinates As Point3d = arrtheFENodes(0).Coordinates For Each Node In arrtheFENodes() If Node.Label = theIndNode.Label Then Continue For Else Dim thecoordinates As Point3d = arrtheFENodes(1).Coordinates 'Calculate distance Dim xDiff As Double = Math.Abs(theIndNodecoordinates.X - thecoordinates.X) Dim yDiff As Double = Math.Abs(theIndNodecoordinates.Y - thecoordinates.Y) Dim zdiff As Double = Math.Abs(theIndNodecoordinates.Z - thecoordinates.Z) distance = Math.sqrt(xDiff^2 + yDiff^2 + zDiff^2) If WeightingOption = 1 Then if distance >100 then Weighting_Factor = 0 Else Weighting_Factor = 1. End if Else 'WeightingOption = 2 If distance >100 then Weighting_Factor = 100/(distance)^2) Else Weighting_Factor = 1. End if 'allocate Weighting_Factor to the node Next Node Next theFEElm
07-04-2019 05:41 AM
thank you for answering. Unfortunately, renumbering is not the way to do because the list of grid points in dialogue "Element Associated Data" is not sorted by means of grid point labels but probably by means of internal object declarations or so. It's not possible to rearrange or sort the table. (point for an enhancement request, I assume)
See here :
- elements => one layer of parabolic hexahedrons,
- outer grid points => 2001-2032,
- inner grid points => 3001-3032,
- middle grid point => 4001-4016):
So, the method of using a script with NXOpen is the better way (for those who can develop such a script ).
Info: I made the modification showed here manually and that was very complicated because of necessity for not forgetting a grid point.
Best wishes, Michael
07-04-2019 05:48 AM
thank you for answering. Is your script working? - It looks very well in the basic formulas. But the coding for NX objects I can't check. I assume it is a first attempt but my ability for writing such scripts are limited.
Best wishes, Michael
07-04-2019 05:54 AM - edited 07-04-2019 06:31 AM
No .
It's something I lifted from some program I have. So there's a quite a few things missing
the bare-bone Nx script needs not to be complicated. for example
What I do not know is
I coded something a while ago and the way around a similar issue to 1 (albeit with element type) I used the .GetSolverCardSyntax(). I then parsed the string to get what I wanted. In the case of an RBE3 , field 4 of the parsed data should containt the independant node ID.
if you go down that route then it's a different question to be posted in different forum. Have fun...
Function SetRBE3MyWay( InListofFEElem As List (of CAE.FEElement), _ IndbTheRefDistance as Double,_ Optional theWeightingOption As Integer = 1) For Each theFEElm As CAE.FEElement In InListofFEElem Dim dicoNodeLabelWFactor As New Dictionary(Of Integer, Integer) Dim arrtheFENodes() As CAE.FENode = theFEElm.GetNodes 'Find Independent Node theIndNode Dim theIndNodecoordinates As Point3d = arrtheFENodes(0).Coordinates For Each Node In arrtheFENodes() If Node.Label = theIndNode.Label Then Continue For Else Dim thecoordinates As Point3d = arrtheFENodes(1).Coordinates 'Calculate distance Dim xDiff As Double = Math.Abs(theIndNodecoordinates.X - thecoordinates.X) Dim yDiff As Double = Math.Abs(theIndNodecoordinates.Y - thecoordinates.Y) Dim zdiff As Double = Math.Abs(theIndNodecoordinates.Z - thecoordinates.Z) distance = Math.sqrt(xDiff^2 + yDiff^2 + zDiff^2) If theWeightingOption = 1 Then If distance >IndbTheRefDistance then Weighting_Factor = 0 Else Weighting_Factor = 1. End if Else 'theWeightingOption = 2 If distance >IndbTheRefDistance then Weighting_Factor = IndbTheRefDistance/(distance)^2) Else Weighting_Factor = 1. End if dicoNodeLabelWFactor.Add(Node.Label, Weighting_Factor) Next Node 'allocate Weighting_Factors to each by looping through the dictionary create Next theFEElm End Function
07-04-2019 08:02 AM
where/how did you get the interpolation element? I don't have it the list if connections!
07-04-2019 10:35 AM
I'm not really sure what you mean, so here two answers:
1. The interpolation element is the:
1D spider connection with RBE3 elements.
2. The weighting factors are modifyable at:
Nodes and Elements => Elements => Associated Data
=> Interpolation
After that, select the RBE3 element that you want from view. There it is....
Best wishes, Michael