linear#

PySeismoSoil.helper_simulations.linear(vs_profile: ndarray, input_motion: ndarray, boundary: Literal['elastic', 'rigid'] = 'elastic') tuple[numpy.ndarray, ...][source]#

Linear site response simulation.

helper_site_response.linear_site_resp() also performs linear site response calculation. The difference between this function and the other is: this function can produce the time histories of acceleration, velocity, displacement, stress, and strain of every layer, while the other function only produces the ground motion time histories on the ground surface.

If the user only wants the ground surface motion, then the other function (linear_site_resp()) is faster.

Parameters:
  • vs_profile (np.ndarray) –

    Shear-wave velocity profile, as a 2D numpy array. It should have the following columns:

    Thickness [m]

    Vs [m/s]

    Damping

    Density [kg/m^3]

    Material No.

    (Damping unit: 1)

  • input_motion (np.ndarray) – Input acceleration on rock outcrop (unit: m/s/s). It should have two columns (time and acceleration). It should be the “rock outrcop” motion if boundary is set to "elastic", and it should be the recorded motion at the bottom of the Vs profile (i.e., the “borehole” motion) if boundary is set to "rigid".

  • boundary (Literal['elastic', 'rigid']) – Boundary condition. ‘Elastic’ means that the input motion is the “rock outcrop” motion, and ‘rigid’ means that the input motion is the recorded motion at the bottom of the Vs profile.

Returns:

A tuple of 11 numpy arrays:
new_profile

Re-discretized Vs profile.

freq_array

”Single-sided” frequency. Shape: (half_N, ) or (half_N - 1, ).

tf

Transfer function (complex-valued). Same shape as freq_array.

accel_on_surface

Simulated acceleration on the ground surface (two-columed).

out_a

Simulated acceleration time history of every layer. Shape: (num_time_step, n_layer).

out_v

Simulated velocity time history of every layer. Same shape as out_a.

out_d

Simulated displacement time history of every layer. Same shape as out_a.

out_gamma

Simulated shear strain time history of every layer. Shape: (num_time_step, n_layer - 1).

out_tau

Simulated shear stress time history of every layer. Same shape as out_gamma.

max_avd

Maximum acceleration, velocity, and displacement during the shaking process, of each layer. Shape: (n_layer, ).

max_gt

Maximum shear strain and shear stress during the shaking process, of each layer. Shape: (n_layer - 1, ).

Return type:

tuple[np.ndarray, …]