Nodes

A node within a structure is represented by the Node object.  This object encapsulates all the properties of a node such as its position and orientation of the local axes.  All the nodes that form a structure are contained within the Nodes collection that is stored as part of the Frame object.

 

 

A summary of all the properties and methods of the Node object are listed in the table below.

 

Property

Type

Description

Elements

ElementList

Read Only.  Returns a list of all elements connected to the node.

Masses

NodeMassList

Read Only.  Returns a list of all node masses attached to the node.

Orientation

Variant

Get/Set the orientation of the local nodal axes.

OrientX

Double

Get/Set the rotation about the x-axes that specifies the orientation of the nodes local axes.

OrientY

Double

Get/Set the rotation about the y-axes that specifies the orientation of the nodes local axes.

OrientZ

Double

Get/Set the rotation about the z-axes that specifies the orientation of the nodes local axes.

Pinned

Boolean

Get/Set the whether the node is pinned or rigid.

Restraints

RestraintList

Read Only.  Returns a list of all restraints applied to the node.

Springs

SpringList

Read Only.  Returns a list of all springs attached to the node.

XYZ

Variant

Get/Set the position of the node.

X

Double

Get/Set the x-coordinate of the nodes position.

Y

Double

Get/Set the y-coordinate of the nodes position.

Z

Double

Get/Set the z-coordinate of the nodes position.

UserData

Variant

Get/Set user defined value stored with the node.

UserDataUnits

mfUnitType

Get/Set the units of the user defined value stored with the node.

 

Method

Returns

Description

GlobalToLocal

Variant

Transforms a vector of values from global to local nodal coordinates.

Loads

NodeLoadList

Returns the loads applied to the node by specified load cases.

LocalToGlobal

Variant

Transforms a vector of values from local nodal coordinates to global coordinates.

PreDisps

NodePreDispList

Returns the prescribed displacements applied to the node by specified load cases.

Results

NodeResult

Returns the results at the node for a specific analysis and load case.

GetUserData

Variant

Returns variant arrays containing the values and units of the specified user data fields.

SetUserData

Variant

Sets the values and units of the specified user data fields.

 

The Application, Frame, Number, Label and Index properties in addition to the Delete method are common to many objects and are described in Chapter 2.

Creating Nodes

A node is added to a frame using the AddNode method of the Nodes collection.  This method has three parameters that specify the x, y and z coordinates of the node in the global coordinate system.  The y and z parameters are optional values and have a default value of 0.0.  The position of the node will be set using the current units of length that are set within the Multiframe application.  For example, the following demonstrates how to add a node to a structure.

Dim myNode as Multiframe.Node
Dim xVar,yVar as Variant

’Set units to metres
Call mfApp.Preferences.SetUnit(mfUnitLength, "m")

’Add node at x=1,y=4,z=5
Set myNode = myFrame.Nodes.AddNode(1.0, 4.0, 5.0)

In this example, the script sets the unit lengths to metres before adding the node.

 

Adding nodes one by one can be tedious and very time consuming using automation. A virtually unlimited number of nodes can be created using the AddNodes method of the Nodes collection.  This method also has three parameters corresponding the coordinates in the global x, y and z directions, and returns a NodeList object containing each of the nodes added to the structure.  Each of the parameters to this method may be an array of values, containing a value for each of the new nodes, or a single value that will be applied to each of the new nodes.  The parameters for the y and z parameters are optional and have a default value of 0.0.  This is very convenient when working on a 2D structure or even a continuous beam as the redundant direction can be ignored.  Some examples of using the AddNodes method follow.

Dim myNodeList as New Multiframe.NodeList
Dim xVar,yVar as Variant

’Set units to metres
Call mfApp.Preferences.SetUnit(mfUnitLength, "m")

'Add nodes for a 3 element continuous beam 12 units long
Set myNodeList = myFrame.Nodes.AddNodes(Array(0.0, 4.0, 8.0, 12.0))

'Add nodes for a portal frame, 12 m wide, 4m/5.25m high
xVar = Array(0.0,0.0,6.0,12.0,12.0)           ‘x coords
yVar = Array(0.0,4.0,5.25,4.0,0.0)            ‘y coords
Set myNodeList = myFrame.Nodes.AddNodes(xVar, yVar)

A feature of Multiframe is that only a single node can exist at any point in space.  When adding a node to the structure, Multiframe will test for the existence of a node at the specified location.  If such a node exists, a new node will not be created, and the existing node will be returned to the user instead.

Automatically create nodes when adding Elements.

When creating the geometry of a frame it is not necessary to specify the individual nodes and then add elements by connecting the individual nodes.  A simpler method is to directly create elements by specifying the location of its ends.  In this case, nodes will automatically be added to the frame if a node does not already exist at the specified location.

Properties

The Node object encapsulates the data describing a joint within a structural model.  These properties described the position of the node, the orientation of the nodes local axes and if the node is pinned or rigid.  The Node object also provides several other properties that provide information about other items that are connected or associated with the node such as springs, restraints and joint masses.

 

The position of a node in global space is specified using the x, y or z properties of the Node object.  These properties, which give the location of the node in each of the global directions, are expressed in terms of the length units currently in use within the Multiframe application.  The coordinates of the node may also be referenced using the xyz property that returns the position of the node as a variant containing an array of three values.

Dim myNode as Multiframe.Node
 
’Get reference to node
Set myNode = myFrame.Nodes(21)

’Scale x coord of node by 4 times
myNode.x = myNode.x * 4.0

’Set position of node
myNode.xyz = Array(10.0,2.0,1.0)

The orientation of a node is controlled by the OrientX, OrientY, OrientZ properties of the Node object. They define the rotations of the global axes that are combined to give the orientation of the local nodal axes.  To complement these three properties, the Orientation property provides access to the same information as an array of three values.

 

The Pinned property of the Node object defines if a node as pinned or rigid. This Boolean valued property is equal to true when the node is a pinned node.

 

A list of the springs attached to a node can be obtained using the Springs property of the Node object.  This read only property returns a SpringList object which references each spring applied to the node.  The springs attached to several nodes within a structure can be determined using the Springs property of the NodeList object which returns a SpringList object containing all the springs connected to any node contained within the list of nodes.

Dim myNodeList as New Multiframe.NodeList
Dim mySpringList as New Multiframe.SpringList

’Get all nodes connected to node 15
Set mySpringList = myFrame.Nodes(15).Springs

’Get all springs connected to nodes 1,2 and nodes 5 to 10
myNodeList.Add “1,2,5-10”
Set mySpringList = myNodeList.Springs

’Get all springs in frame
myNodeList.Clear
myNodeList.Add myFrame.Nodes
Set mySpringList = myNodeList.Springs

Similarly the Restraints and Masses properties return list of any restraints or node masses attached to a node.

 

The UserData and UserDataUnits properties enable values other than those defined within Multiframe to be stored with each node. These properties take a single parameter identifying separate values to be stored with the node thus allowing any number of values to be stored with each node. Furthermore, each value is stored as a variant data type so that strings, numbers or even arrays may be stored with each user data entry.  To provide compatability of the user data with the handling of units within Multiframe the type of units associated with each user data entry may be set using the UserDataUnits property.  By default each user data value is assumed to be dimensionless. A simple example demonstrating these properties if shown below

Dim myNode as Multiframe.Node
 
’Get reference to node
Set myNode = myFrame.Nodes(21)

’Store user data values
myNode.UserData(1) = 12.5   ‘ number
myNode.UserData(2) = “ABC”  ‘ string
myNode.UserData(3) = 6.0    ‘ Length value
myNode.UserDataUnits(3) = mfUnitsLength

msgbox “User Data 1 = ”+ myNode.UserData(1)
msgbox “User Data 2 = ”+ myNode.UserData(2)
msgbox “User Data 3 = ”+ myNode.UserData(3)

Note units conversions will only be applied to user data values represented as numbers.

Methods

A list of loads applied to a node can be obtained using the Loads and PreDisps methods of the Nodes object.  These methods take a single parameter identifying the load cases that are to be considered when compiling the list of loads.  This parameter is optional, and, if omitted, this method will return all the loads applied to the node as part of any load case within the frame. The Loads and PreDisps methods return the list of loads as NodeLoadList or NodePreDispList objects respectively.  The flexibility of these methods is demonstrated below

Dim myNode As Multiframe.Node
Dim myLoadList As New Multiframe.NodeLoadList
Dim myDispList As New Multiframe.NodePreDispList

'Get reference to node 5
Set myNode = myFrame.Nodes(5)

'Get all loads applied to node 5 in load case 1
Set myLoadList = myNode.Loads(1)

'Get all prescribed disps applied to node 5 in load case 3
Set myDispList = myNode.PreDisps(myFrame.LoadCases(3))

'Get all loads applied to node 5 in load cases 1 to 3 and 5
Set myLoadList = myNode.Loads("1-3,5")

'Get all loads applied to node 5 (all load cases)
Set myLoadList = myNode.Loads(myFrame.LoadCases)

The Results method of the Node object provides a means of directly accessing the results at a node from a particular analysis, without navigating through the hierarchy of the Results object.  This method takes three parameters; the first is a variant parameter identifying the load case for which the results are required, the second identifies the type of analysis.  The third parameter is redundant and has been included for future expansion of the automation interface.  The Results method returns a NodeResult object that encapsulates access to the displacements and reactions at the node.  This object is described in detail in Chapter 7.

 

The Node object also provides two methods for transforming an array of values between global and local nodal coordinates.  These methods can transform arrays containing either 3 or 6 values.  The GlobalToLocal method, as the name suggests, transforms values from the global coordinate system to the local nodal coordinates as defined by the nodal orientation.  Conversely, the LocalToGlobal method transforms values expressed in the local nodal coordinates back to global coordinates.  A typical application of transforming values between coordinate systems is in transforming the reactions (expressed in global coordinates) at a node with an inclined restraint to determine the reactions normal to the restraint.

Dim myNode As Multiframe.Node
Dim r As Variant

Set myNode = myFrame.Nodes(1)

’Get vector of nodal reactions wrt global axes
r = myNode.Results(1, mfAnalysisStatic).Reactions

’Tranform reactions to local nodal axes
r = myNode.GlobalToLocal(r)