plot_bending.Rd
Plot bent
plot_bending(...) plot_bending_3d(...)
... | A list of X, Y, Z data.frames for each beam of beam state |
---|
A ggplot or a plotly object (see plotly::plot_ly()
)
file_path = system.file("extdata/6_EW01.22_17_kanan.txt", package = "biomech") field_data = read_mat(file_path) # Un-bending the field measurements: df_unbent = unbend(field_data) # Adding the distance of application of the left and right weight: df_unbent$distance_application = distance_weight_sine(df_unbent$x) # (Re-)computing the deformation: df_bent = bend(df_unbent, elastic_modulus = 2000, shear_modulus = 400, step = 0.02, points = 100, iterations = 15, verbose = TRUE)#> Final torsion angle at the tip (degree) = 12.52822# And finally, plotting: plot_bending(bent = df_bent, "un-bent" = df_unbent)# And in 3d: # plot_bending_3d(bent = df_bent, "un-bent" = df_unbent)