Module VIIAClassDefinition

This module contains project methods to create shapes according to the naming convention for VIIA.

VIIA project settings for naming convention - Shape creation

Create functions

These functions are used to create the shapes based on VIIA naming convention.

viiapackage.VIIAClassDefinition._viia_create_beam(project: ViiaProject, name: Union[str, Layer], material: str, geometry: str, points: List[List[Union[float, str, Shapes, Level]]], is_truss: bool = False, is_roof_beam: bool = False) Beam[source]

VIIA function to create a beam shape based on layer, material, geometry and contour points. The beam can be optionally turned into a truss element.

Warning

In this release a string containing the full name is still accepted as input for name. In future releases this functionality will be deprecated. Enter a layer object instead.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • name (str or Layer): Name of the layer as a string, or the Layer object itself, to which the newly created column should be added. Full name of shape is also accepted, not applying auto naming function, this will be removed in future releases.

  • material (str): Name of the material of the beam shape to be created, complying VIIA naming convention.

  • geometry (str): Name of the geometry of the beam shape to be created, complying VIIA naming convention.

  • points (list of list of floats and shapes): The start and end point of the beam shape. Each point is a list of 3 floats or 2 floats and 1 shape. If 3 floats are given, the unmodified point is used. If 2 floats and 1 shape is given, the unknown coordinate at the index of the shape is calculated by projection on this shape. Shapes can be inputted as objects or strings e.g. [[19.2, 6, “roof_1”], [0, 1, 4]] or [[19.2, roof_1, 15], [0, 1, 4]]. The z-coordinate can also be provided as level object, or name of the level.

  • is_truss (bool): Select to transform the beam object into a truss object. Default value is False.

  • is_roof_beam (bool): Select to indicate if the beam is part of the roof structure (and is plotted in the roof plot also in case of no roof sheeting). Default value is False.

Output:
  • Returns the created beam object reference.

  • The beam is added to the project and to the layer.

viiapackage.VIIAClassDefinition._viia_create_cavity_wall_tie(project: ViiaProject, inner_leaf: Wall, outer_leaf: Wall, point_inner: Union[List[float], Node], point_outer: Union[List[float], Node], material: Optional[Material] = None)[source]

Function to create a cavity wall tie between two walls. The two points that are given are added as internal points to their corresponding Wall object, and a spring is constructed between these two points. By default, the VIIA convention for cavity wall tie material is used.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • layer (str, Layer): String or Layer object to which the tie should be added.

  • inner_leaf (Wall): Object reference to the inner leaf wall.

  • outer_leaf (Wall): Object reference to the outer leaf wall.

  • point_inner (List, Node): Coordinate or Node on inner leaf.

  • point_outer (List, Node): Coordinate or Node on outer leaf.

  • material (Material): Optional object reference to a material for the tie.

Output:
  • Spring object describing the cavity wall tie

viiapackage.VIIAClassDefinition._viia_create_column(project: ViiaProject, name: Union[str, Layer], material: str, geometry: str, points: List[List[Union[float, str, Shapes, Level]]], is_truss: bool = False) Column[source]

VIIA function to create a column shape based on layer, material, geometry and contour points. The column can be optionally turned into a truss element.

Warning

In this release a string containing the full name is still accepted as input for name. In future releases this functionality will be deprecated. Enter a layer object instead.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • name (str or Layer): Name of the layer as a string, or the Layer object itself, to which the newly created column should be added. Full name of shape is also accepted, not applying auto naming function, this will be removed in future releases.

  • material (str): Name of the material of the column shape to be created, complying VIIA naming convention.

  • geometry (str): Name of the geometry of the column shape to be created, complying VIIA naming convention.

  • points (list of list of floats and shapes): The start and end point of the column shape. Each point is a list of 3 floats or 2 floats and 1 shape. If 3 floats are given, the unmodified point is used. If 2 floats and 1 shape is given, the unknown coordinate at the index of the shape is calculated by projection on this shape. Shapes can be inputted as objects or strings e.g. [[19.2, 6, “roof_1”], [0, 1, 4]] or [[19.2, roof_1, 15], [0, 1, 4]]. The z-coordinate can also be provided as level object, or name of the level.

  • is_truss (bool): Select to transform the column object into a truss object. Default value is False.

Output:
  • Returns the created column object reference.

  • The column is added to the project and to the layer.

viiapackage.VIIAClassDefinition._viia_create_floor(project: ViiaProject, name: Union[str, Layer], material: str, geometry: str, points: List[List[List[Union[float, str, Shapes, Level]]]], element_x_axis: Optional[Union[List[float], str]] = None) Floor[source]

VIIA function to create a floor shape based on layer, material, geometry and contour points. The points list can also contain the openings in the floor shape.

Warning

In this release a string containing the full name is still accepted as input for name. In future releases this functionality will be deprecated. Enter a layer object instead.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • name (str or Layer): Name of the layer as a string, or the Layer object itself, to which the newly created floor should be added. Full name of shape is also accepted, not applying auto naming function, this will be removed in future releases.

  • material (str): Name of the material of the floor shape to be created, complying VIIA naming convention.

  • geometry (str): Name of the geometry of the floor shape to be created, complying VIIA naming convention. If naming convention dictates that the geometry is incorporated into the material (e.g. wood plank floors), setting the geometry to 0 skips the geometry parameter when generating the object name.

  • points (list of list of list of floats and shapes): The points of the contour and opening of the floor shape. Each point is a list of 3 floats or 2 floats and 1 shape. If 3 floats are given, the unmodified point is used. If 2 floats and 1 shape is given, the unknown coordinate at the index of the shape is calculated by projection on this shape. Shapes can be inputted as objects or strings. e.g. [[[0, 0, 0], [1, 0, 0], [1, “wall_1”, 0], [0, wall_1, 0]], [coordinates of opening1], [coordinates of opening2] etc.]. The z-coordinate can also be provided as level object, or name of the level.

  • element_x_axis (list of floats): Optional input to define direction of the local x-axis of the floor, which also defines the spanning direction of the floor. Default value is None, in which case the element-x-axis is set to the direction of the intersection of the surface with a horizontal plane. In case of a floor (with a horizontal surface), the local x-axis is set in the global x-direction. Alternative also the name of the direction can be provided.

Output:
  • Returns the created floor object reference.

  • The floor is added to the project and to the layer.

viiapackage.VIIAClassDefinition._viia_create_fstrip(project: ViiaProject, name: Union[str, Layer], material: str, geometry: str, points: List[List[List[Union[float, str, Shapes, Level]]]], element_x_axis: Optional[Union[List[float], str]] = None) Fstrip[source]

VIIA function to create a foundation strip shape based on layer, material, geometry and contour points. The points list can also contain the openings in the foundation strip shape.

Warning

In this release a string containing the full name is still accepted as input for name. In future releases this functionality will be deprecated. Enter a layer object instead.

Note

Foundation strips can only be created in the layer for foundations ‘F’.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • name (str or Layer): Name of the layer as a string, or the Layer object itself, to which the newly created foundation strip should be added.

  • material (str): Name of the material of the foundation strip shape to be created, complying VIIA naming convention.

  • geometry (str): Name of the geometry of the foundation strip shape to be created, complying VIIA naming convention. If naming convention dictates that the geometry is incorporated into the material (e.g. wood plank foundation strips), setting the geometry to 0 skips the geometry parameter when generating the object name.

  • points (list of list of floats and shapes): The points of the contour and opening of the foundation strip shape. Each point is a list of 3 floats or 2 floats and 1 shape. If 3 floats are given, the unmodified point is used. If 2 floats and 1 shape is given, the unknown coordinate at the index of the shape is calculated by projection on this shape. Shapes can be inputted as objects or strings. e.g. [[[0, 0, 0], [1, 0, 0], [1, “wall_1”, 0], [0, wall_1, 0]], [coordinates of opening1], [coordinates of opening2] etc.]. The z-coordinate can also be provided as level object, or name of the level.

Output:
  • Returns the created fstrip object reference.

  • The fstrip is added to the project and to the layer.

viiapackage.VIIAClassDefinition._viia_create_main_surface_reinforcement(project: ViiaProject, name: Union[str, Layer], material: str, geometry: str, points: List[List[Union[float, str, Shapes, Level]]], host_members: Optional[List[Union[Floor, Wall]]] = None, discretisation: str = 'element', element_x_axis: Optional[Union[List[float], str]] = None, regions: Optional[List['Regions']] = None) MainSurfaceReinforcement[source]

VIIA function to create main surface reinforcement shape based on layer, material, geometry and contour points. The points list can also contain the openings in the main surface reinforcement shape.

Warning

In this release a string containing the full name is still accepted as input for name. In future releases this functionality will be deprecated. Enter a layer object instead.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • name (str or Layer): Name of the layer as a string, or the Layer object itself, to which the newly created main surface reinforcement should be added.

  • material (str): Name of the material of the main surface reinforcement shape to be created, complying VIIA naming convention.

  • geometry (str): Name of the geometry of the main surface reinforcement shape to be created, complying VIIA naming convention.

  • points (list of list of floats and shapes): The points of the contour and opening of the main surface reinforcement shape. Each point is a list of 3 floats or 2 floats and 1 shape. If 3 floats are given, the unmodified point is used. If 2 floats and 1 shape is given, the unknown coordinate at the index of the shape is calculated by projection on this shape. Shapes can be inputted as objects or strings. e.g. [[[0, 0, 0], [1, 0, 0], [1, “wall_1”, 0], [0, wall_1, 0]], [coordinates of opening1], [coordinates of opening2] etc.]. The z-coordinate can also be provided as level object, or name of the level.

  • host_members (obj): Optional input for a list of object reference of the shape to which the reinforcement belongs. Default value is None.

  • discretisation (str): Setting for the meshing of the surface reinforcement. Meshing can be based on the mesh elements it is embedded in, ‘element’, or based on the shape itself, ‘section’. Default value is ‘element’.

  • element_x_axis (obj): Optional input to define direction of the local x-axis of the roof, which also defines the spanning direction of the roof. Default value is None, in which case the element-x-axis is set to the direction of the intersection of the surface with a horizontal plane. In case of a roof (with a horizontal surface), the local x-axis is set in the global x-direction.

  • regions (list of obj): List of object references of a region (surface) within the surface shape. It may not overlap the contour of the surface shape, but openings might be. Openings need to be set in the surface shape and cannot be set as part of the region. Default value is None.

Output:
  • Returns the created main surface reinforcement object reference.

  • The main surface reinforcement is added to the project and to the layer.

viiapackage.VIIAClassDefinition._viia_create_roof(project: ViiaProject, name: Union[str, Layer], material: str, geometry: str, points: List[List[List[Union[float, str, Shapes, Level]]]], element_x_axis: Optional[Union[List[float], str]] = None) Roof[source]

VIIA function to create a roof shape based on layer, material, geometry and contour points. The points list can also contain the openings in the roof shape.

Warning

In this release a string containing the full name is still accepted as input for name. In future releases this functionality will be deprecated. Enter a layer object instead.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • name (str or Layer): Name of the layer as a string, or the Layer object itself, to which the newly created roof should be added. Full name of shape is also accepted, not applying auto naming function, this will be removed in future releases.

  • material (str): Name of the material of the roof shape to be created, complying VIIA naming convention.

  • geometry (str): Name of the geometry of the roof shape to be created, complying VIIA naming convention. If naming convention dictates that the geometry is incorporated into the material (e.g. wood plank roofs), setting the geometry to 0 skips the geometry parameter when generating the object name.

  • points (list of list of list of floats and shapes): The points of the contour and opening of the roof shape. Each point is a list of 3 floats or 2 floats and 1 shape. If 3 floats are given, the unmodified point is used. If 2 floats and 1 shape is given, the unknown coordinate at the index of the shape is calculated by projection on this shape. Shapes can be inputted as objects or strings. e.g. [[[0, 0, 0], [1, 0, 0], [1, “wall_1”, 0], [0, wall_1, 0]], [coordinates of opening1], [coordinates of opening2] etc.]. The z-coordinate can also be provided as level object, or name of the level.

  • element_x_axis (list of floats): Optional input to define direction of the local x-axis of the roof, which also defines the spanning direction of the roof. Default value is None, in which case the element-x-axis is set to the direction of the intersection of the surface with a horizontal plane. In case of a roof (with a horizontal surface), the local x-axis is set in the global x-direction.

Output:
  • Returns the created roof object reference.

  • The roof is added to the project and to the layer.

viiapackage.VIIAClassDefinition._viia_create_roof(project: ViiaProject, name: Union[str, Layer], material: str, geometry: str, points: List[List[List[Union[float, str, Shapes, Level]]]], element_x_axis: Optional[Union[List[float], str]] = None) Roof[source]

VIIA function to create a roof shape based on layer, material, geometry and contour points. The points list can also contain the openings in the roof shape.

Warning

In this release a string containing the full name is still accepted as input for name. In future releases this functionality will be deprecated. Enter a layer object instead.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • name (str or Layer): Name of the layer as a string, or the Layer object itself, to which the newly created roof should be added. Full name of shape is also accepted, not applying auto naming function, this will be removed in future releases.

  • material (str): Name of the material of the roof shape to be created, complying VIIA naming convention.

  • geometry (str): Name of the geometry of the roof shape to be created, complying VIIA naming convention. If naming convention dictates that the geometry is incorporated into the material (e.g. wood plank roofs), setting the geometry to 0 skips the geometry parameter when generating the object name.

  • points (list of list of list of floats and shapes): The points of the contour and opening of the roof shape. Each point is a list of 3 floats or 2 floats and 1 shape. If 3 floats are given, the unmodified point is used. If 2 floats and 1 shape is given, the unknown coordinate at the index of the shape is calculated by projection on this shape. Shapes can be inputted as objects or strings. e.g. [[[0, 0, 0], [1, 0, 0], [1, “wall_1”, 0], [0, wall_1, 0]], [coordinates of opening1], [coordinates of opening2] etc.]. The z-coordinate can also be provided as level object, or name of the level.

  • element_x_axis (list of floats): Optional input to define direction of the local x-axis of the roof, which also defines the spanning direction of the roof. Default value is None, in which case the element-x-axis is set to the direction of the intersection of the surface with a horizontal plane. In case of a roof (with a horizontal surface), the local x-axis is set in the global x-direction.

Output:
  • Returns the created roof object reference.

  • The roof is added to the project and to the layer.

viiapackage.VIIAClassDefinition._viia_create_wall(project: ViiaProject, name: Union[str, Layer], material: str, geometry: str, points: List[List[List[Union[float, str, Shapes, Level]]]], cavity_inner_wall_id: Optional[int] = None, structural_type: str = 'psse') Wall[source]

VIIA function to create a wall shape based on naming convention for shape, material, geometry and contour points. The points list can also contain the openings in the wall shape.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • name (str or Layer): Name of the layer as a string, or the Layer object itself, to which the newly created column should be added. Full name of shape is also accepted, not applying auto naming function, this will be removed in future releases.

  • material (str): Name of the material of the wall shape to be created, complying VIIA naming convention.

  • geometry (str): Name of the geometry of the wall shape to be created, complying VIIA naming convention.

  • points (list of list of floats and shapes): The points of the contour and opening of the wall shape. Each point is a list of 3 floats or 2 floats and 1 shape. If 3 floats are given, the unmodified point is used. If 2 floats and 1 shape is given, the unknown coordinate at the index of the shape is calculated by projection on this shape. Shapes can be inputted as objects or strings. e.g. [[[0, 0, 0], [1, 0, 0], [1, “wall_1”, 0], [0, wall_1, 0]], [coordinates of opening1], [coordinates of opening2] etc.]. The z-coordinate can also be provided as level object, or name of the level.

  • cavity_inner_wall_id (int): In case of an outer leaf of a cavity wall, the ID will be set based on the ID of the inner leaf. This number should be provided in that case.

  • structural_type (str): Optional structural type, can be either ‘psse’ or ‘nsce’.

Output:
  • Returns the created wall object reference. The ID of the newly created wall is set to the number supplied in the name. For cavity walls, 9000 is added to the id that is supplied. Therefore, if the inner leaf has id = 5, the outer leaf will have id = 9005.

  • The wall is added to the project and to the layer.

Create on grid functions

These functions are used to convert simplified grid-based input for the create functions above. These functions can generate the shapes with list input. Be aware that foundation strips and roofs can’t be created on grid, but should be created with the functions created for roofs and foundations.

viiapackage.VIIAClassDefinition._viia_create_beams_on_grid(project: ViiaProject, layer: str, beam_list: List[List[Union[str, int]]], grid: Optional[Union[Grid, int, str]] = None, is_truss: bool = False) List[Beam][source]

This function is used to set up the beams for a specific layer, making use of a grid system. A beam list is given as input, in which each row represents a beam. Each beam is in turn represented by a list of five values; starting point, end point, z-coordinates, material and cross-section. The points to place the beams should be given in grid notation, for instance ‘A3’. The beams can be optionally turned into truss elements.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • layer (str): String specifying the layer, conform VIIA naming convention. For example: ‘N0’.

  • beam_list (list): List containing the information of the individual beams, for example: [[‘D1’, ‘D9’, [2.5, 3.5], ‘HOUT’, ‘100x100’], [‘D9’, ‘L9’, 2.5, ‘HOUT’, ‘100x100’], [[0, 5.3], [7.5, 5.3], 4.6, ‘HOUT’, ‘100x100’] This will create three timber beams with a cross-section 100mm x 100mm. The first beam is created from grid point D1 at an elevation of 2.5 m to D9 at an elevation of 3.5. The second beam is created from grid point D9 to L9 at an elevation of 2.5 m. The third beam is created at coordinates [0, 5.3] and [7.5, 5.3] at an elevation of 4.6 m. Note that to create an inclined beam, the heights must be given as a list

  • grid (Grid, int, str): Optional object, id or name of the grid to use. By default, the first grid in the collection is used.

  • is_truss (bool): Select to transform the beam object into a truss object. Default value is False.

Output:
  • Each beam described in the beam list is added to the project and the relevant collections.

  • A list containing all beam objects is returned.

Example:

>>> project.viia_create_beams_on_grid(
        layer='N0',
        beam_list=[['D1', 'D9', 3.0, 'MW-KLEI<1945', 210], ['D9', 'L9', [2.0, 3.0], 'MW-KLEI<1945', 210],
        [[0, 5.3], [7.5, 5.3], 4.6, 'HOUT', '100x100']])
viiapackage.VIIAClassDefinition._viia_create_beams_on_grid_in_shape(project: ViiaProject, layer: Union[str, Layer], grid: Union[Grid, int, str], gridlines: List[Union[str, int]], shape: Surfaces, material: str, geometry: str, is_truss: bool = False, is_roof_beam: bool = False) List[Beam][source]

This function can be used to create beams that lie inside a surface shape using the grids. The best use of this function is for purlins and rafters, but can also be used for beams supporting a floor. Beams will be created on all the given gridlines, and they will be cut by the contour of the given surface shape. The beams can be optionally turned into truss elements.

Note

Currently, this function only works for gridlines that are parallel to either the x-axis or the y-axis.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • layer (obj): Layer object in which the beams are located. Alternative (str): String representing the layer name, conforming to VIIA naming convention. E.g. ‘N0’.

  • grid (obj): Grid object that the beams are plotted on. Alternative (int): ID of the grid object. Alternative (str): Name of the grid object.

  • gridlines (list of str or int): List containing the names of the gridlines on which the beams are plotted. The entries in the list can be either strings or integers.

  • shape (obj): The surface shape that the beams are created in.

  • material (str): Name of the material of the beam shape to be created, complying VIIA naming convention.

  • geometry (str): Name of the geometry of the beam shape to be created, complying VIIA naming convention.

  • is_roof_beam (bool): Select to indicate if the beam is part of the roof structure (and is plotted in the roof plot also in case of no roof sheeting). Default value is False.

Output:
  • Each beam described in the beam list is added to the project and the relevant collections.

  • A list containing all beam objects is returned.

viiapackage.VIIAClassDefinition._viia_create_columns_on_grid(project: ViiaProject, layer: str, column_list: List[List[Union[str, int]]], grid: Optional[Union[Grid, int, str]] = None, is_truss: bool = False) List[Column][source]

This function is used to set up the columns for a specific layer, making use of a grid system. A column list is given as input, in which each row represents a column. Each column is in turn represented by a list of five values; starting point, end point, z-coordinate, material and cross-section. The points to place the columns should be given in grid notation, for instance ‘A3’. The columns can be optionally turned into truss elements.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • layer (str): String specifying the layer, conform VIIA naming convention. For example: ‘N0’.

  • column_list (list): List containing the information of the individual columns, for example: [[‘D1’, 0.0, 3.0, ‘LIN-BETON’, ‘210x210’], [‘E4’, 0.0, 3.5, ‘LIN-HOUT’, ‘D180’], [[4.86, 6.01], 0.0, 3.0, ‘LIN-HOUT’, ‘50x100’]. This will create three timber columns with cross-sections 210x210, D180 and 50x100. The first column is created at grid point D1 from an elevation of 0 m to 3.0 m. The second column is created at grid point E4 from an elevation of 0 m to 3.5 m. The third column is created at x-coordinate 4.86 and y-coordinate 6.01 and spans from an elevation of 0 m to 3 m.

  • grid (Grid, int, str): Optional object, id or name of the grid to use. By default, the first grid in the collection is used.

  • is_truss: transforms all columns into trusses. Default value is False.

Output:
  • Each column described in the column list is added to the project and the relevant collections.

  • A list containing all column objects is returned.

Example:

project.viia_create_columns_on_grid(
    layer='N0',
    column_list=[['D1', 0.0, 3.0, 'LIN-BETON', '210x210'], ['E4', 0.0, 3.5, 'LIN-HOUT', 'D180'],
    [[4.86, 6.01], 0.0, 3.0, 'LIN-HOUT', '50x100']])
viiapackage.VIIAClassDefinition._viia_create_floors_on_grid(project: ViiaProject, layer: str, z_coordinate: float, floor_list: List[List[Union[str, float, list]]], grid: Optional[Union[Grid, int, str]] = None) List[Floor][source]

This function is used to set up the floors for a specific layer, making use of a grid system. A floor list is given as input, in which each row represents a floor. Each floor is in turn represented by a list of corner points, a material, a geometry and an optional element_x_axis.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • layer (str): String specifying the layer, conform VIIA naming convention. For example: ‘N0’.

  • z_coordinate (float): The z_coordinate of the floors, in [m].

  • floor_list (list): List containing the information of the individual floors, for example [[‘A1’, ‘B1’, ‘B2’, ‘A2’, ‘LIN-HBV-PLANKEN-0.03-0.040-0.150-0.600’, 0, [0, 1, 0], [‘A2’, ‘B2’, ‘B1’, ‘C1’, ‘C3’, ‘A3’, ‘LIN-BETON’, 300],[[0,0], [7.5,0], [7.5,7.5], [0,7.5], ‘LIN-BETON’, 100]. This will create three rectangular floors. The geometry of the floor shape to be created, needs to comply to VIIA naming convention. If naming convention dictates that the geometry is incorporated into the material (e.g. wood plank floors), setting the geometry to 0 skips the geometry parameter when generating the object name. Optionally a local x-axis can be defined.

  • grid (Grid, int, str): Optional object, id or name of the grid to use. By default, the first grid in the collection is used.

Output:
  • Each floor described in the floor list is added to the project and the relevant collections.

  • A list containing all floor objects is returned.

Example

project.create_floors_on_grid(‘N1’, 3.0, floor_list)

An example of a floor list is:
floor_list = [[‘A1’, ‘B1’, ‘B2’, ‘A2’, ‘LIN-HBV-PLANKEN-0.03-0.040-0.150-0.600’, 0, [0, 1, 0]],

[‘A2’, ‘B2’, ‘B1’, ‘C1’, ‘C3’, ‘A3’, ‘LIN-BETON’, 300], [[0,0], [7.5,0], [7.5,7.5], [0,7.5], ‘LIN-BETON’, 100]]

The first floor in this list spans between gridpoints A1, B1, B2 and A2, is a ‘PLANKEN’ floor with the specified spacing and geometry parameters, and spans in the y direction([0, 1, 0]).

The second floor spans between six gridpoints, is made of concrete and has a thickness of 300mm. The element_x_axis is omitted, which means it will have default value [1, 0, 0].

The third floor spans between four x and y coordinates, is made of concrete and has a thickness of 100mm. The element_x_axis is omitted, which means it will have default value [1, 0, 0].

viiapackage.VIIAClassDefinition._viia_create_walls_on_grid(project: ViiaProject, layer: Union[str, Layer], z_bottom: float, z_top: float, wall_list: List[List[Union[str, int]]], grid: Optional[Union[Grid, int, str]] = None, structural_type: str = 'psse') List[Wall][source]

This function is used to set up the walls for a specific layer, making use of a grid system. A wall list is given as input, in which each row represents a wall. Each wall is in turn represented by a list of four values; starting point, end point, material and thickness. The points to place the wall should be given in grid notation, for instance ‘A3’.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • layer (str): String specifying the layer, conform VIIA naming convention. For example: ‘N0’.

  • z_bottom (float): The z_coordinate of the bottom of the wall, in [m].

  • z_top (float): The z_coordinate of the top of the wall, in [m].

  • wall_list (list): List containing the information of the individual walls, for example [[‘D1’, ‘D9’, ‘MW-KLEI<1945’, 210], [‘D9’, ‘L9’, ‘MW-KLEI<1945’, 210],[[0,0], [7.5,0], ‘MW-KLEI<1945’, 210]]. This will create masonry wall with a thickness of 210mm between grid point D1 and D9, a second wall between grid-points D9 and L9 and third wall between coordinates [0,0] and [7.5,0].

  • grid (Grid, int, str): Optional object, id or name of the grid to use. By default, the first grid in the collection is used.

  • is_foundationwalls (bool): Optional boolean to create foundation walls. Default set to False.

  • structural_type (str): Optional structural type, can be either ‘psse’ or ‘nsce’.

Output:
  • Each wall described in the wall list is added to the project and the relevant collections.

  • A list containing all wall objects is returned.

Example:

project.viia_create_walls_on_grid(
    layer='N0', z_coordinate_bottom=0.0, z_coordinate_top=3.0,
    wall_list=[['D1', 'D9', 'MW-KLEI<1945', 210], ['D9', 'L9', 'MW-KLEI<1945', 210],
    [[0,0], [7.5,0], 'MW-KLEI<1945', 210]])
viiapackage.VIIAClassDefinition.viia_create_collar_ties_on_grid(project: ViiaProject, layer: Union[str, Layer], grid: Union[Grid, int, str], gridlines: List[Union[str, int]], shapes: List[Shapes], beam_height: Union[float, Level, str], material: str, geometry: str, floor_level: Optional[Union[float, Level, str]] = None, is_truss: bool = True, is_roof_beam: bool = False) List[Beam][source]

This function can be used to created collar ties between two roof shapes using the grids. Beams will be created on all the given gridlines, and they will be cut by the two roof plates. The beams can be optionally turned into truss elements.

Note

Currently, this function only works for gridlines that are parallel to either the x-axis or the y-axis.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • layer (obj): Layer object in which the beams are located. Alternative (str): String representing the layer name, conforming to VIIA naming convention. E.g. ‘N0’.

  • grid (obj): Grid object that the beams are plotted on. Alternative (int): ID of the grid object. Alternative (str): Name of the grid object.

  • gridlines (list of str or int): List containing the names of the gridlines on which the beams are plotted. The entries in the list can be either strings or integers.

  • shapes (list of obj): List of two surface shapes that the beams are created between.

  • beam_height (float): Elevation of the collar ties measured from the floor defined in floor_level. Alternative 1 (obj): Level object specifying the elevation of the collar ties measured from the ground. This level must be part of the given grid. Alternative 2 (str): String representation of a level object specifying the elevation of the collar ties measured from the ground. This level must be part of the given grid.

  • material (str): Name of the material of the beam shape to be created, complying VIIA naming convention.

  • geometry (str): Name of the geometry of the beam shape to be created, complying VIIA naming convention.

  • floor_level (float): Optional argument that specifies the height of the floor that may be used along with beam_height to determine the elevation at which to create the beams. This argument is required when beam_height is not a Level object. Alternative 1 (obj): Level object specifying the elevation of the floor. Alternative 2 (str): String representation of a level object specifying the elevation of the floor.

  • is_truss (bool): Select to transform the collar tie objects into truss objects. Default value is True.

  • is_roof_beam (bool): Select to indicate if the beam is part of the roof structure (and is plotted in the roof plot also in case of no roof sheeting). Default value is False.

Output:
  • Each beam described in the beam list is added to the project and the relevant collections.

  • A list containing all beam objects is returned.

VIIA project settings for naming convention - Material creation

viiapackage.VIIAClassDefinition._viia_create_material(project: ViiaProject, material_name: str, hbv_span: Optional[float] = None, hbv_width: Optional[float] = None)[source]

This function contains all settings for the materials that are set by the naming convention used in the VIIA project. These settings are project specific. If material names that are passed are not conform naming convention, an error may be raised.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • material_name (str): Name of the material, using the standard for VIIA project (see UPR).

  • hbv_span (float): Span of the floor for timber floors and roofs, in [m].

  • hbv_width (float): Width of the floor, perpendicular to the span, for timber floors and roofs, in [m].

Output:
  • Updates the material name depending on the VIIA project settings.

  • Returns the object reference to the material (if not present, it is created)

VIIA project settings for naming convention - Geometry creation

viiapackage.VIIAClassDefinition._viia_create_geometry(project: ViiaProject, geometry_name: str, material_object: Material, shape_object: Optional[Union[Shapes, str]] = None, class_type: Optional[str] = None)[source]

This function contains all settings for the geometries that are set by the naming convention used in the VIIA project. These settings are project specific. If geometry names that are passed are not conform naming convention, an error may be raised.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • geometry_name (str): Name of the geometry, using the standard for VIIA project (see UPR).

  • material_object (obj): Object reference to the material of the shape.

  • shape_object (obj): Object reference to the shape the material is applied on. If class_type is provided the shape is not required. Default value is None. Required if the class_type is not provided.

  • class_type (str): Optional input of the type of object to apply the geometry on, for example ‘Floor’ or ‘Lintel’, default value is None. Required if the shape_object is not provided.

Output:
  • Updates the geometry name depending on the VIIA project settings.

  • Returns the object reference to the geometry (if not present, it is created)

Remove shape objects in VIIA project

viiapackage.VIIAClassDefinition._viia_remove_shape(project: ViiaProject, shape: Union[str, Shapes])[source]

Function to remove a shape from project in the VIIA project. In VIIA certain data is saved to the meta-data. These object references should be removed as well at the moment the referenced shape is removed. Normal FEM procedure to remove the shape is performed afterward.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • shape (obj): Object reference of the shape to be removed. Alternative input can be the name or ID of the shape.

Output:
  • Any reference in the meta-data for VIIA is removed.

  • The object is deleted in DIANA (if software is DIANA, model created and not a sub-shape).

  • Before deleting from PY-memory all collections are checked and updated.

  • The object is deleted in PY-memory.

Getters for VIIA shape objects

viiapackage.VIIAClassDefinition.viia_get(project: ViiaProject, collection: Optional[str] = 'all', name: Optional[str] = None, id: Optional[int] = None, unique_id: Optional[str] = None)[source]

This function will return the object with the name that is provided.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • collection (str): Name of the collection of shapes to look in. Default set to all collections present in the project instance.

  • name (str): Name that will be used for searching.

  • id (int): ID that will be used for searching.

  • unique_id (str): Unique-ID that will be used for searching.

Output:
  • Returns the object with the provided name. If no object fulfills the requirements, None will be returned.

viiapackage.VIIAClassDefinition.viia_get_connection(project: ViiaProject, collection_name: Optional[str] = 'all', name: Optional[str] = None, _id: Optional[int] = None, point: Optional[List[float]] = None) Optional[Connections][source]

This function can be used to find a connection based on some queries from user. It will return the connection object. In case multiple conections comply to the query, the first connection is returned and a warning is printed.

The user can provide a name or ID of the connection. The connection with this name or ID is returned. Note that in case of ID the input for the collections should be narrowed.

The user can provide a point (x-, y- and z-coordinate as list). In this case, the function will return the connection for which the point is on the node, line or surface of the connection. Alternative input can be object reference of Node.

Note

Finding connections is not available for volume-shapes with connections applied.

Input:
  • project (obj): Project object reference containing collections of fem objects and project variables.

  • collection_name (str): Name of the collection of connections to look in. Default set to all collections for connections present in the project instance.

  • name (str): Name that will be used for searching, this may be a part of the name too. Function is not case-sensitive. Default value is None, in which case it is not checking for name.

  • _id (int): ID that will be used for searching. Default value is None, in which case it is not checking for ID.

  • point (list of 3 floats): List of the x-, y- and z-coordinates of the point to be used for searching, values in [m]. Default value is None, in which case it is not checking for point. Alternative input object reference of Node.

Output:
  • Returns the connection object from the requested collection, filtered for the requested layer if any, filtered for the connections that comply to the requested inputs. If no connection is found, None is returned. If multiple connections have been found, the first one is returned. The user is notified of this.

viiapackage.VIIAClassDefinition.viia_get_level(project: ViiaProject, shape: Shapes) Optional[Level][source]

Function to return the level of the shape. This is based on the VIIA naming convention.

Input:
  • project (obj): VIIA project object containing collections of fem objects and project variables.

  • shape (obj): Shape of which the level is returned.

Output:
  • Returns the level of the shape as a string, for example ‘N0’.

viiapackage.VIIAClassDefinition.viia_get_shape(project: ViiaProject, collection_name: Optional[str] = 'all', name: Optional[str] = None, _id: Optional[int] = None, point: Optional[List[float]] = None, gridline: Optional[Union[Gridline, str]] = None, grid: Optional[Union[Grid, str]] = None, level: Optional[Union[Level, str]] = None, layer: Optional[Union[Layer, str]] = None) Optional[Shapes][source]

This function can be used to find a shape based on some queries from user. It will return a shape object. In case multiple shapes comply to the query, the first shape is returned and a warning is printed.

The user can provide a name or ID of the shape. The shape with this name or ID is returned.

The user can provide a point (x-, y- and z-coordinate as list). In this case, the function will return the shape for which the point is within the surface of the surface-shape (excluding the openings), the point is on the line of a line-shape or if the coordinate is the point of the point-shape.

The user can also provide a gridline. In this case, the function will return the shape for which the gridline is aligned (vertically) and on the surface plane if it is a surface-shape, the shape is parallel to and on the gridline if it is a line-shape, or the point-shape if the point is on the vertical plane of the gridline.

The user can also provide a level. In this case, the function will return a shape on the level (horizontally).

Different queries can be combined to filter on multiple inputs at the same time.

Note

Finding shape based on the gridline, level or coordinate is not available for volume-shapes.

Input:
  • project (obj): Project object reference containing collections of fem objects and project variables.

  • collection_name (str): Name of the collection of shapes to look in. Default set to all collections present in the project instance.

  • name (str): Name that will be used for searching, this may be a part of the name too. Function is not case-sensitive. Default value is None, in which case it is not checking for name.

  • _id (int): ID that will be used for searching. Default value is None, in which case it is not checking for ID.

  • point (list of 3 floats): List of the x-, y- and z-coordinates of the point to be used for searching, values in [m]. Default value is None, in which case it is not checking for point.

  • gridline (obj or str): Object reference or name of the gridline, specifying the vertical plane in which the shape is searched. In case the gridline is specified as string, the grid should be provided too. This function then will check the gridlines of that grid. Default value is None, in which case it is not checking for gridline.

  • grid (obj or str): Object reference or name of the grid. The grid is only required if the gridline is specified as string. In that case the grid should contain the required gridline. In any other situation input for the grid is ignored. Default value is None.

  • level (obj or str): Object reference or name of the level, specifying the horizontal plane in which the shape is searched. Default value is None, in which case it is not checking for level.

  • layer (obj or str): Object reference or the name of the layer in which to search for the requested shape.

Output:
  • Returns the shape object from the requested collection, filtered for the requested layer if any, filtered for the shapes that comply to the requested inputs. If no shape is found, None is returned. If multiple shapes have been found, the first one is returned. The user is notified of this.