|
| | DynamicModel (DynamicMesh &mesh_, Record &record_) |
| | Constructs a new Model object.
|
| |
| void | next_step () |
| | This code iterates over all vertices in a mesh and displaces them randomly based on a force term and a random term. The displacement is added to the original vertex position.
|
| |
| | Model (Mesh &mesh_, Record &record_) |
| | Constructs a new Model object.
|
| |
| bool | should_continue_optimization () |
| | Determines whether the optimization algorithm should continue running.
|
| |
| void | determine_trial_step_size () |
| | This code determines the step size used in an optimization algorithm. The step size is used to calculate how far to move in each iteration of the optimization algorithm to minimize an energy function.
|
| |
| std::string | to_string_current_step () |
| | Returns a string representation of the current step's iteration number, trial step size, and optimal step size. The function concatenates the values of model.iteration, model.oa.trialStepSize, and model.stepSize to the following format: "step: , trial StepSize = , StepSize = ".
|
| |
| void | update_ncg_direction () |
| | Updates the direction for nonlinear conjugate gradient (NCG) optimization.
|
| |
| void | reset_ncg_direction () |
| | Reset the direction for nonlinear conjugate gradient (NCG) optimization.
|
| |
| double | linear_search_for_stepsize_to_minimize_energy () |
| | Performs a linear search to find the optimal step size that minimizes energy using either nonlinear conjugate gradient method or simple line search.
|
| |
| bool | simulated_annealing_next_step (bool forceAttempt=false) |
| | Use a Metropolis thermal trial move to sample beyond local gradient descent.
|
| |
| void | enforce_boundary_conditions_after_coordinate_update () |
| | Synchronize boundary/ghost coordinates after direct coordinate updates.
|
| |
| void | update_vertex_using_NCG () |
| | Update vertex coordinates using a non-linear conjugate gradient method.
|
| |
| void DynamicModel::next_step |
( |
| ) |
|
This code iterates over all vertices in a mesh and displaces them randomly based on a force term and a random term. The displacement is added to the original vertex position.
The boundary conditions are checked for each vertex before displacement, and if the vertex is a ghost or boundary, and not part of a periodic boundary condition, then the displacement is set to 0.
The displacement amount, along with the vertex index, whether it is a boundary or ghost vertex, and the dimension being displaced (x, y, z) is printed to the console using std::cout.