You can use begin_f_loop and end_f_loop when you want to loop over all faces in a
given face thread. It contains a begin and end loop statement, and performs operation(s) on each
face in the face thread as defined between the braces . This loop is usually nested within thread_loop_f when you want to loop over all faces in
all face threads in a domain.
face_t f;
Thread *f_thread;
begin_f_loop(f, f_thread) /* loops over faces in a face thread */
{
}
end_f_loop(f, f_thread)
Example
/* Loop over faces in a face thread to get the information stored on faces. */
begin_f_loop(f, f_thread)
{
/* F_T gets face temperature. The += will cause all of the face
temperatures to be added together. */
temp += F_T(f, f_thread);
}
end_f_loop(f, f_thread)