Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails with smoothing radius <0.4 #8

Open
NH89 opened this issue Apr 26, 2018 · 2 comments
Open

Fails with smoothing radius <0.4 #8

NH89 opened this issue Apr 26, 2018 · 2 comments

Comments

@NH89
Copy link
Owner

NH89 commented Apr 26, 2018

Noticed by Shafeeq: The program fails when reducing smoothing radius below 0.4 in my computer.

@NH89
Copy link
Owner Author

NH89 commented Apr 26, 2018

I will investigate this, once I have the C++ branch working. My first suspicion is that it may be 'correct' behaviour - i.e. if particles are created wider apart than the outer limit of their smoothing radius, then they are separate (like grains of sand) and should move like a granular fluid.

@eshafeeqe
Copy link
Collaborator

eshafeeqe commented Apr 27, 2018

Dear Nick,

I am not telling the mathematical or theoretical problem here.

The system is crashing while smoothing radius <0.4. and crashing is happening in kernel insert_particles_in_bin_array

The code in the kernel given below,

kernel void insert_particles_in_bin_array (PSO_ARGS, global uint * backup_prefix_sum) {
    USE_FIELD_FIRST_VALUE(n, uint) USE_FIELD(gridcell, uint) USE_FIELD(cellparticles, uint)

    size_t i = get_global_id(0);

    if (i < n)
    {
        
        cellparticles[atomic_inc(backup_prefix_sum + gridcell[i])] = i;
    }

}

I am suspecting that there could be some memory access violation happening here if the smoothing radius is less than 0.4.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants