-
Notifications
You must be signed in to change notification settings - Fork 4
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
1D Time of flight #9
Comments
I got some help from @AleksandarJ1984 : solved removing "r" (radius) and using w_vec = interpolate(Constant((1.7e5, )), W). However, I don't get the expected analytical results. By the way, when I have finished this part, I will try to do a PR asap since it is linked to #3 |
If someone has an explanation for the following source term:
The first part corresponds to the analytical expression of ne, multiplied by the velocity and alpha. So why it is not in logarithmic scale for the "ne" expression ? |
In fact, the source term definition does not change whether the log formulation is used or not. With log formulation the time derivative term changes to n_e*dN_e/dt, where n_e = exp(N_e). The equation is solved for N_e = log(n_e) but the rest of the equation, including the source term, remains unchanged (using n_e and not N_e). |
Make sure that you consider the proper analytical solution to compare with when the problem is reduced to 1D. |
|
This is working now, I will do a PR as soon as possible. |
@RaphaelPile Thank you very much for making the 1D example. I will check it out and merge it with other examples. |
Hello there !
I am working on 1D version of time of flight example. I have not modified the beginning and the end of the code, just the boundaries and the mesh at first. I got a first problem with the velocity vector, which wa solved by using
w_vec = Expression(('1.7e5', 0.), element=W.ufl_element())
instead ofw = interpolate(Constant(('0','1.7e5')), W)
in the flux Gamma calculation.But now I am a bit stuck with the error I get below. Maybe my previous modification was a mistake, I don't really know....
Here is my code (the modified part of time-of-flight.py) and the error log.
Any help is welcome.
The text was updated successfully, but these errors were encountered: