# I have a square plate and I want to impose a gaussian random traction

Here sample1 and sample2 are constant number applied throughout the top and the left edges (uniformly distributed load) of the square plate. But now I want to implement a traction which is basically gaussian random noise throughout the edge.

traction_expr = Expression((‘sample1near(x[0],1)', 'sample2near(x[1], 1)’),sigma = 0.5, sample1 = sample1, sample2 = sample2 , degree = 1)

F = inner(stress,grad(v))dx + dot(body_force,v)dx + dot(traction_expr,v)ds + rhoinner(u, v)/(dt**2) * dx - 2rhoinner(u_n_minus_one,v)/(dt2) * dx + rho*inner(u_n_minus_two,v)/(dt2)*dx

problem = NonlinearVariationalProblem(F, u, [bc_left, bc_bottom], J = derivative(F, u ,du))

# Create the Newton solver

solver = NonlinearVariationalSolver(problem)

# Set solver options (optional)

solver.parameters[“newton_solver”][“relaxation_parameter”] = 1.0
solver.parameters[“newton_solver”][“relative_tolerance”] = 1e-10
solver.parameters[“newton_solver”][“maximum_iterations”] = 100
solver.solve()