DFoundations

For D-Foundations the pile design is calculated based on CPT results. To be able to import these CPTs into the calculation, the GeoPackage is based on Moondriaan and OpenGround.

Where Moondriaan can be used to import CPTs and do the classification, and where OpenGround is the database in which all this information is stored. From OpenGround an export can be made for this ground investigation. The exported csv's are the basis where the D-Foundations connector works with.

In addition to the CPTs, D-Foundations also requires some user input on the pile types and calculation options. These can be set in the GeoPackage (python environment), where the connector makes use of GeoLib. The current development for the GeoPackage is working with GeoLib 0.1.8.

The connector for D-Foundations now focuses on bearing piles only. Eventually tension piles will be added as well.

Connector_DFoundations_Geopackage

The current way of working is that the D-Foundations connector functions as a wrapper around GeoLib, where the user can create calculation files from a python script. In this script the user is able to easily setup a pile- and calculation type.

Creating a model

We first create a model, in which we can add the different classes.

from rhdhv_geo import Model
model = Model('example-model')

Creating a pile

The wrapper uses classes and functions to be able to add piles into the model in an easy way.

from rhdhv_geo.geo_pile import create_rectangular_pile

#First we set up the pile:
pile = create_rectangular_pile(
    x=2.0,
    y=3.0,
    pile_head_level=z_coordinate_top,
    base_length=0.2,
    base_width=0.2,
    F_sls=1900,
    F_uls=2300,
    installation_type=PileInstallationType.PREFAB_CONCRETE,
    elasticity_modulus=2e7
)
#Adding an id and name to the pile    
pile.id = "Paal 1"
pile.name = f"Paal 1"
#Finally we add the pile to the model
model.piles.append(pile)

Import piles from speckle stream

Additionally we can also import a speckle stream into the geo model. Currently the pile supports are recognized and can be send to the D-Foundations file.

model.from_datafusr_fem(stream_url="https://rhdhv.speckle.xyz/streams/14ddd6955c/commits/ae53edadb2")

By reading the speckle stream, piles are added into the model. However, the pile type and some other relevant parameters need to be added still. This can be done in the following way:

for i, pile in enumerate(model.piles):
    pile.geometry = RectangularPileGeometry(base_length=0.4, base_width=0.4)
    pile.installation_type = PileInstallationType.PREFAB_CONCRETE
    pile.elasticity_modulus = 2e7
    pile.name = f"Paal-{i}"

Adding a CPT

As mentioned, the D-Foundations connector is based upon csv data exported from Open Ground. The connector can now translate any material from Moondriaan to DFoundations. In case the user wants to use project specific or user defined materials, it is recommended to use the connection to Origin.

When the data is exported to csvs from OpenGround, the data can be read into the D-Foundations connector. Assemble the files from OpenGround in a folder, preferably in your python working directory. Three files are expected inside this folder, that should have the following names:

  • cpt-data.csv (Static Cone Penetration Tests - Data.csv)
  • cpt-stratified.csv (Field Geological Descriptions.csv)
  • Location-Details.csv (Location Details.csv)

Note: the names have been changed slightly in the OpenGround export (see between brackets), this is currently not changed in the rhdhv_geo package. You can change the name manually and the connector will still work.

In the following example we expect a folder named cpt_data in the same directory as the Python file:

from patlib import Path
from rhdhv_geo import Model

model = Model('example-model-cpt')
folder = Path('cpt_data')
model.load_CPTs(folder)

for cpt in model.cpts:
    print('CPT: ', cpt.cpt_id)
    print(cpt.soil_layers)

Note that for all unique soil material names defined in the CPT data, a SoilMaterial object will be created in the Model class. These objects only have a name defined, so no parameters are assigned yet. For more information on working with soil materials, see this section.

Settings

The calculation settings give the user the flexibility to set the safety factors and correlation factors.

Currently the connector assumes a complete verification calculation add a certain pile tip level. In the future additional modules can be added, but this will give the geotechnical engineer the flexibility to calculate the bearing capacities and the spring stiffness already.

model.dfoundations.create_general_settings(phreatic_level=-3, excavation_level=-10)
model.dfoundations.create_dfoundations_model_options_bearing(
  is_rigid=False, factor_xi3=1.2, factor_xi4=1.2)
model.dfoundations.create_dfoundations_calculation_options(
  calculation_type="VERIFICATION_COMPLETE", cpt_test_level=-20)

Generate model

Once everything is set up and added into the model (in the python memory), we are ready to create the calculation file.

model.to_dfoundations(Path('basic-model.foi'))

Read results

#ToDo

Plaxis

Installation

WARNING

The rhdhv_geo package is currently only compatible with Plaxis 2D Version 22

The rhdhv_geo package has to be installed in the Python interpreter of Plaxis. The required installation files can be found in the following link:

Download installation script

Download and run the install_rhdhv_geopackage.bat file. This will set up the rhdhv_geo package in the Python interpreter of Plaxis, and also copy the gui.py file to the pytools folder of Plaxis. Package installation will proceed, and you may be requested to sign in using your web browser.

GUI

Using the rhdhv_geo package , it is possible to exchange geometrical objects like point, line and polygon objects between Plaxis 2D and Speckle.

Receiving a Plaxis model from a speckle stream

Open Plaxis 2D. The rhdhv_geo package GUI is available in Plaxis 2D input window in Expert -> Run Python tool -> gui. To receive geometrical objects from speckle as Plaxis objects, click on the Receive button in the GUI. Select DataFusr as the "Send model to" option, and specify the speckle url. Click Receive model. The objects from the speckle stream should now be visible in Plaxis.

GUI screenshot

Sending a Plaxis model to a speckle stream

Open Plaxis 2D. The rhdhv_geo package GUI is available in Plaxis 2D input window in Expert -> Run Python tool -> gui. To send geometrical objects of a plaxis model to speckle, click on the Send button in the GUI. Select DataFusr as the "Receive model from" option, and specify a speckle url. Click Send Model. This will create a new speckle branch with the objects from Plaxis.

GUI screenshot

D-Stability

WARNING

The rhdhv_geo package is currently only compatible with D-Stability version 2023.01.

With the D-Stability software slope stability calculations can be performed based on a two-dimensional cross-section. To be able to import all the necessary information for the D-Stability model, one can use the standalone app PACE: PACE webapp

See also the different components in a D-Stability file via the web viewer Stixie: Stixie viewer

The way of working of the D-Stability module in the rhdhv_geo package is to facilitate a wrapper around Geolib. This makes sure that the relevant information of a D-Stability calculation is structured in a logical way and links to the database of PACE.

Creating a schematisation

We first create a schematisation, in which we can add the different classes.

from rhdhv_geo.dstability.objects.dstability_schematisation import DStabilitySchematisation
dstability_schematisation = DStabilitySchematisation()

Creating a stage

The wrapper uses classes and functions to be able to create a stage (part of a D-Stability schematisation) in an easy way.

from rhdhv_geo.geometry import Point
from rhdhv_geo.dstability.objects.stage import Stage
from rhdhv_geo.dstability.objects.soil_type import SoilType
from rhdhv_geo.dstability.objects.soil_layer import SoilLayer

# First we create a stage object
stage = Stage(name='Stage')
# Then we set up the soil type and soil layer
soil_type = SoilType(
    name='dijksmateriaal zand', 
    gamma_unsat=20, 
    gamma_sat=18, 
    soil_behaviour='drained', 
    phi=30, 
    c=0,
    ksi=0, 
    color='#D3A13B'
)
soil_layer = SoilLayer(
    geometry=[
        Point(x=-20, z=0), 
        Point(x=20, z=0), 
        Point(x=20, z=2), 
        Point(x=-20, z=1)
    ],
    soil_type=soil_type
)
# Finally we add the soil layer to the stage
stage.soil_layers.append(soil_layer)

Similar to soil layers, it is also possible to add water lines and loads to a stage.

from rhdhv_geo.dstability.objects.water_lines import WaterLine, PhreaticLine
from rhdhv_geo.dstability.objects.loads import UniformLoad

# First we set up a phreatic line in combination with a reference line
phreatic_reference_line = WaterLine(
    points=[
        Point(x=-20, z=0), 
        Point(x=20, z=0)
    ]
)
phreatic_line = PhreaticLine(
    points=[
        Point(x=-20, z=2), 
        Point(x=20, z=1)
    ], 
    reference_line=phreatic_reference_line
)
# Then we set up a uniform (traffic) load
load = UniformLoad(
    label='Traffic load', 
    magnitude=10, 
    angle_of_distribution=30, 
    start=-5, 
    end=5
)
# Finally we add the elements to the stage
stage.water_lines.append(phreatic_line)
stage.loads.append(load)

Finally, we add the stage to the schematisation.

dstability_schematisation.stages.append(stage)

Generating a D-Stability model

The created schematisation can be converted to a D-Stability model and exported to a .stix file. The conversion is based on the geolib package of Deltares.

from pathlib import Path
from rhdhv_geo.dstability.create_dstability_model import create_dstability_model

dstability_model = create_dstability_model(
    soil_types=[soil_type], 
    dstability_schematisation=dstability_schematisation
)
dstability_model.serialize(Path('rhdhv_geo_tutorial.stix'))

Calculations

At the moment it is not possible to execute D-Stability calculations with rhdhv-geo or geolib. As soon as this feature becomes available it will be added to this documentation. It is already possible to define an analysis method in the D-Stability model (e.g. Bishop, Spencer, Uplift Van). The calculation still needs to be executed via the D-Stability software. The latest version of D-Stability can be downloaded here: D-Stability download

D-Sheet Piling

WARNING

The rhdhv_geo package is currently only compatible with D-Sheet Piling V23.1.1 For this d-geoilb 1.3.3 was used with dec-sheetpiles 0.2.0 (with some minor adjustments)

This module for the geopackage is using both GeoLib and DEC Damwanden, where DEC Damwanden is a wrapper around GeoLib.

The connector for D-Sheet Piling was created for the project Knooppunt Nieuwe Meer. The main principle behind this is that we can import parameters from Origin, which are then converted into python objects and can be used to set up a D-Sheet Piling model.

Soil materials and profiles

In order to import soil materials, we can import them straight from origin. Within Origin we can store the materials in an aspect. In this aspect we can have multiple aspects (materials), with variables (soil parameters).

The code below will grab the materials and parameters, within this function the material and it's parameters are converted into a SoilMaterial. This is a class in the geopackage for D-Sheet Piling.

soil_materials = soil_materials_from_origin_aspect(ORIGIN_PROJECT_NAME, ORIGIN_API_KEY, aspects=["parameter_set_geo"])

For each calculation, the user can store a soil stratigraphy in Origin. These are then pulled from origin using the following code:

soil_profile = soil_profile_from_origin_aspect(ORIGIN_PROJECT_NAME, ORIGIN_API_KEY, aspects=["Geosnedes Damwanden",Cross_section, "Grondprofiel"])

Now that both the materials and soil profile are known, we can send this into the D-Sheet Piling calculation using the following code:

layers = []
    for soil in soil_profile:
        layers.insert(0, SoilLayer(soil_material=make_dec_dsheet_soil_material(soil_materials[soil]),
                                   top=soil_profile[soil],
                                   head_top=general_properties_dict["phreatic_level"],
                                   head_bottom=general_properties_dict["phreatic_level"]))

    soil_profiles = {Side.BOTH: SoilProfile(name="initial soil profile",
                                            layers=layers,
                                            phreatic_level=general_properties_dict["phreatic_level"],
                                            bottom=-30)}

So each layer is added with the relevant material. Then the soil profile is generated. Good to note here is that the phreatic level is now coming from a dictionary, but it could be a hardcoded number such as the bottom level is.

Surfaces

Surfaces are basically a list of coordinates which define a line. Within the current package, we can both import a speckle stream as well as get the data from a json file.

The line below will import the name of a speckle stream from Origin and convert it into a surface. The current speckle stream connection grabs a list of coordinates and converts it into a surface.

""" Getting the speckle stream:"""
surfaces_dict = single_item_dict_from_origin_aspect(ORIGIN_PROJECT_NAME, ORIGIN_API_KEY, ["Geosnedes Damwanden",Cross_section],"Maaiveld_lijnen")
""" Creating the surfaces from speckle:"""
for surface in surfaces_dict:
    # print(surface)
    Surfaces[surface] = get_speckle_surface_data(surfaces_dict[surface])

We can have different surfaces, which can be used in the stages. You can imagine an intial surface, and a final surface for example.

Sheetpiles and anchors

For sheetpiles and anchors we can use the available classes from the DEC sheetpiles wrapper. We did have to add a @classmethod there to be able to create the class from a dictionary. For the sheetpile this looks as follows.

This makes it possible to easily create the class from a dictionary instead of having to specify each variable. Within Origin we already have defined all these variables, which can then be mapped in to the class.

@classmethod
def from_dict(cls, data):
    name = data['name']
    top_level = data['top_level']
    top_level = data['top_level']
    bottom_level = data['bottom_level']
    W_el = data['W_el']
    yield_stress = data['yield_stress']
    profile_height = data['profile_height']
    #coating_area = data['coating_area']
    section_area = data['section_area']
    width_of_sheetpile = data['width_of_sheetpile']
    acting_width = data['acting_width']
    E = 210
    return cls(name, top_level,bottom_level,W_el,yield_stress,profile_height,section_area,width_of_sheetpile,acting_width,E)

We can create a sheetpile and an anchor as such:

sheetpile = NormalSheetPile.from_dict(sheetpile_section_dict)
anchor = Anchor.from_dict({**anchors_geom_dict[anchor],**dict})

Stages

For stages, the DEC sheetpiles wrapper provides a standard list of activities. Such as an excavation, or installation of an anchor. Each of these activities can be created by calling a function. We can define all the different stages by defining which type of activity it is, and which variables are there. This is done in origin. We also define the stage number to be able to have the sequence of stages.

With this information, we create a dictionary for all phases and loop trhough it:

for i in range(0,len(stages_origin.items())):
    for stage, stage_info in stages_origin.items():
        if stage_info['stage_no'] == i+1:
            activity = dict_to_stage(stage,stages_origin,Surfaces,Anchors,Loads)
            calculator.add_construction_activity(activity)

The dict_to_stage function uses a mapping to know what type of activity is being added. The mapping refers to the correct function to create the activity, below is an example of GenericEarthWork:

activity = GenericEarthWork(name=stage_dict['name'],
                side=sides[stage_dict['side']],
                 partial_factor_set=partial_factor_mapping[stage_dict['partial_factor_set']],
                surface_line=Surfaces[stage_dict['surface']],
                 surface_load=loads)

Where loads are created in the function itself.

Importing from Origin

For the KNM project we have defined multiple items within origin. We have the following items:

  • Soil parameters
  • Cross sections
    • Soil profile
    • Stages
    • Sheetpile type and levels
    • Loads
    • Anchors
    • Surface
  • Sheetpile parameters
  • Anchor parameters
Last Updated:
Contributors: Jelle van der Zon