Hi all,
I came across a problem when I tried to call the 'call field_gradient_vector(ivarfl(iu), 1, imrgra, inc, gradv)' or the pressure gradient in a subroutine that I build up in the cs_user_module.f90. For some reason it works fine when I use 1 processor. When I switch to more, I get " MPI error (communicator MPI_COMM_WORLD):
MPI_ERR_TRUNCATE: message truncated"
Any ideas how I can fix the way the gradient variable are communicate with the other processors to fix it?
Thanks,
Costas
Velocity_gradient_calculation
Forum rules
Please read the forum usage recommendations before posting.
Please read the forum usage recommendations before posting.
-
- Posts: 4077
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Velocity_gradient_calculation
Hello,
Yes, I have some ideas, but not enough info to work with.
Regards,
Yvan
Yes, I have some ideas, but not enough info to work with.
Regards,
Yvan
Re: Velocity_gradient_calculation
Dear Yvan,
Thanks for the response.
The idea is to compute the tangential pressure and the velocity gradient of the boundary cell and then pass that info to a define module. The define module will include both subroutines for the gradients, the subroutine that calls for further calculations and any additional functions that are needed.
Please find attached the error message . .
Regards,
Costas
Thanks for the response.
The idea is to compute the tangential pressure and the velocity gradient of the boundary cell and then pass that info to a define module. The define module will include both subroutines for the gradients, the subroutine that calls for further calculations and any additional functions that are needed.
Please find attached the error message . .
Regards,
Costas
-
- Posts: 4077
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Velocity_gradient_calculation
Hello Costas,
This is still not the information I need. The error is probably in your data setup.
Regards,
Yvan
This is still not the information I need. The error is probably in your data setup.
Regards,
Yvan
Re: Velocity_gradient_calculation
Dear Yvan,
Thank you for your reply.
I cannot find anything wrong with my setup but I have attached the files.
Regards,
Costas
Thank you for your reply.
I cannot find anything wrong with my setup but I have attached the files.
Regards,
Costas
- Attachments
-
- listing.txt
- (24.08 KiB) Downloaded 174 times
-
- setup.log
- (24.24 KiB) Downloaded 194 times
Last edited by C0st4s on Wed Jul 03, 2019 8:10 am, edited 1 time in total.
-
- Posts: 4077
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Velocity_gradient_calculation
Hello,
I cannot understand how you can pass information to a dedicated module as you describe with no user subroutines.
Regards,
Yvan
I cannot understand how you can pass information to a dedicated module as you describe with no user subroutines.
Regards,
Yvan
Re: Velocity_gradient_calculation
Dear Yvan,
I have not included my subroutines on purpose. If you think that the problem arises from the way I define the module I will check that again. Otherwise, what is the easiest way to compute the velocity and pressure gradients of cell?
Regards,
Costas
I have not included my subroutines on purpose. If you think that the problem arises from the way I define the module I will check that again. Otherwise, what is the easiest way to compute the velocity and pressure gradients of cell?
Regards,
Costas
-
- Posts: 4077
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Velocity_gradient_calculation
Hello,
Using the field_gradient_* functions is usually th simplest solution.
Best regards,
Yvan
Using the field_gradient_* functions is usually th simplest solution.
Best regards,
Yvan
Re: Velocity_gradient_calculation
Dear Yvan,
I think the problem arises because I try to select a boundary face,<call getfbr>, and based on that selection call the gradient function for the near boundary face cell. For 1 processor the code runs ok but when I switch to 2< it fails since the second processor does not see that information on the same near wall boundary face. I tried to use the synsca function before the gradient call in my module subroutine and print the rank in a file but aparently the second processor which the boundary face is not included it does not show/sync. Any suggestions how can I get the right synchronize gradient information on each processor for the corresponding face selection?
Note that I also use periodicity and halo cells are involved.
Regards,
Costas
I think the problem arises because I try to select a boundary face,<call getfbr>, and based on that selection call the gradient function for the near boundary face cell. For 1 processor the code runs ok but when I switch to 2< it fails since the second processor does not see that information on the same near wall boundary face. I tried to use the synsca function before the gradient call in my module subroutine and print the rank in a file but aparently the second processor which the boundary face is not included it does not show/sync. Any suggestions how can I get the right synchronize gradient information on each processor for the corresponding face selection?
Note that I also use periodicity and halo cells are involved.
Regards,
Costas
-
- Posts: 4077
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Velocity_gradient_calculation
Hello,
I do not understand how you use the gradient function for specific cells, since the function applies to all cells.
In any case in parallel it is a collective function so all processes must make the same call (with their local data of course).
Regards,
Yvan
I do not understand how you use the gradient function for specific cells, since the function applies to all cells.
In any case in parallel it is a collective function so all processes must make the same call (with their local data of course).
Regards,
Yvan