-
Notifications
You must be signed in to change notification settings - Fork 3
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
Non-orthogonal mesh improvements #166
base: master
Are you sure you want to change the base?
Commits on Jan 27, 2023
-
Small bugfix in find_intersection
If both upper_wall and lower_wall are True, `len(contour) // 2` rather than `len(contour // 2)` should be used.
Configuration menu - View commit details
-
Copy full SHA for 55cb29e - Browse repository at this point
Copy the full SHA 55cb29eView commit details -
MeshRegion.addPointAtWallToContours handle no intersection
If a contour starts outside the wall then it can be that no intersection is found. Handle that case, leaving original contour.
Configuration menu - View commit details
-
Copy full SHA for 0fc5357 - Browse repository at this point
Copy the full SHA 0fc5357View commit details -
Method to plot single points, for interactive debugging
Configuration menu - View commit details
-
Copy full SHA for f63a8a9 - Browse repository at this point
Copy the full SHA f63a8a9View commit details -
Improve robustness of non-orthogonal mesh generation
Attempting to handle cases where no intersection is found
Configuration menu - View commit details
-
Copy full SHA for 3e019b6 - Browse repository at this point
Copy the full SHA 3e019b6View commit details -
Plots cell corners joined together, and cell centers as points. Perhaps could use xlow, ylow points to provide a quadratic cell shape?
Configuration menu - View commit details
-
Copy full SHA for d5530b0 - Browse repository at this point
Copy the full SHA d5530b0View commit details -
Add wall intersection finding to FineContour
The idea is to first extend FineContour to the wall, then distort PsiContour's points along the FineContour curve. A divide-and-conquer algorithm is used to make finding intersections with a large number of points efficient.
Configuration menu - View commit details
-
Copy full SHA for f55a69b - Browse repository at this point
Copy the full SHA f55a69bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 94cd821 - Browse repository at this point
Copy the full SHA 94cd821View commit details -
MeshRegion add plotGridLines and plotCells
Move plotting to MeshRegion so individual regions can be plotted. Mesh plotting methods iterate over and call MeshRegions.
Configuration menu - View commit details
-
Copy full SHA for 9291e5d - Browse repository at this point
Copy the full SHA 9291e5dView commit details -
Revert change to PsiContour.get_distance
Broke test case TestContour.test_append
Configuration menu - View commit details
-
Copy full SHA for c616500 - Browse repository at this point
Copy the full SHA c616500View commit details -
Configuration menu - View commit details
-
Copy full SHA for 0607d52 - Browse repository at this point
Copy the full SHA 0607d52View commit details -
Add PsiContour.map and FineContour.getPoint
FineContour.getPoint is the inverse of getDistance: It returns a Point2D if given a distance along the FineContour PsiContour.map takes a function that returns a distance shift, and returns a new PsiContour that shares the FineContour with the original. This will be used to perform mesh deformations.
Configuration menu - View commit details
-
Copy full SHA for 94660c1 - Browse repository at this point
Copy the full SHA 94660c1View commit details -
Configuration menu - View commit details
-
Copy full SHA for b6cb785 - Browse repository at this point
Copy the full SHA b6cb785View commit details -
Configuration menu - View commit details
-
Copy full SHA for 22d8d60 - Browse repository at this point
Copy the full SHA 22d8d60View commit details
Commits on Jan 28, 2023
-
Enable MeshRegion to be passed contours
If given, MeshRegion doesn't need to follow radial coordinate lines and create PsiContours.
Configuration menu - View commit details
-
Copy full SHA for f4c7f85 - Browse repository at this point
Copy the full SHA f4c7f85View commit details
Commits on Jan 30, 2023
-
Add MeshRegion.map and Mesh.map
Enables mapping of the mesh points using shift functions.
Configuration menu - View commit details
-
Copy full SHA for 5c2468e - Browse repository at this point
Copy the full SHA 5c2468eView commit details -
Add plot_cells option to hypnotoad-geqdsk script
Plots straight-sided cells connecting cell corners. Added script plotting options to possible options list, so that an exception isn't raised when they're used.
Configuration menu - View commit details
-
Copy full SHA for c302eeb - Browse repository at this point
Copy the full SHA c302eebView commit details -
Small fixes in FineContour and PsiContour
- Ensure that psi is passed to get_fine_contour - Handle rounding errors near FineContour edges
Configuration menu - View commit details
-
Copy full SHA for 661902a - Browse repository at this point
Copy the full SHA 661902aView commit details -
Configuration menu - View commit details
-
Copy full SHA for e647736 - Browse repository at this point
Copy the full SHA e647736View commit details -
Mesh.map() now creates an instance of self.__class__, so subclasses including BoutMesh can be mapped.
Configuration menu - View commit details
-
Copy full SHA for ddb59e5 - Browse repository at this point
Copy the full SHA ddb59e5View commit details -
PsiContour.map small improvements, fix
Ensure that final index has ypos=1, to be consistent with upper_shift. Prevent crossing lines from going off end of FineContour
Configuration menu - View commit details
-
Copy full SHA for cb8a2f4 - Browse repository at this point
Copy the full SHA cb8a2f4View commit details
Commits on Jan 31, 2023
-
Add MeshRegion.wallAlignShiftFunction and setWallIntersections
MeshRegion.setWallIntersections(Equilibrium) calls FineContour.setWallIntersections to calculate where contours intsersect walls. MeshRegion.wallAlignShiftFunction() creates a lambda function that shifts a MeshRegion to align to the wall. That can map cells to have zero size, but PsiContour.map prevents cells from crossing.
Configuration menu - View commit details
-
Copy full SHA for 1a381a9 - Browse repository at this point
Copy the full SHA 1a381a9View commit details -
Simplify Equilibrium.plotWall()
Change `axis` keyword to `ax` for consistency, return axis.
Configuration menu - View commit details
-
Copy full SHA for e9d4468 - Browse repository at this point
Copy the full SHA e9d4468View commit details -
MeshRegionMapper and MeshMapper classes
Use a polynomial basis to represent mesh point shifts within each MeshRegion. MeshRegionMapper generates new MeshRegion objects given a list of polynomial coefficients. The order of the polynomials in X and Y is set in the constructor. MeshMapper uses MeshRegionMapper to generate new Mesh objects, using a combined list of polynomial coefficients.
Configuration menu - View commit details
-
Copy full SHA for f4be4c0 - Browse repository at this point
Copy the full SHA f4be4c0View commit details -
MeshMapper combine shared PsiContours
PsiContours that are shared between MeshRegions will in general not be mapped in the same way. These PsiContours are averaged in MeshMapper.generate to produce a consistent boundary between regions.
Configuration menu - View commit details
-
Copy full SHA for 8c0e0e8 - Browse repository at this point
Copy the full SHA 8c0e0e8View commit details -
MeshMeasure and BoundaryDistance optimiser
Optimises meshes by varying the distortion parameters to minimise a MeshMeasure. For now only one MeshMeasure: BoundaryDistance combines distances between the mesh and the wall.
Configuration menu - View commit details
-
Copy full SHA for 494eda2 - Browse repository at this point
Copy the full SHA 494eda2View commit details
Commits on Feb 1, 2023
-
Add Orthogonality mesh measure
Enables the optimiser to take into account the orthogonality of the mesh, by minimising tan(Beta) over the mesh, where Beta is the angle between coordinate lines.
Configuration menu - View commit details
-
Copy full SHA for e5a1d1e - Browse repository at this point
Copy the full SHA e5a1d1eView commit details -
Mesh user_options and versioning arguments
Can be used to disable some parts of Mesh construction in optimiser loop.
Configuration menu - View commit details
-
Copy full SHA for 7362778 - Browse repository at this point
Copy the full SHA 7362778View commit details -
Reduce printed output when optimising
Repeatedly creating regions and meshes, so reduce the amount of text printed each iteration
Configuration menu - View commit details
-
Copy full SHA for abe7cbe - Browse repository at this point
Copy the full SHA abe7cbeView commit details -
Mesh optimisation in script, PoloidalSpacing measure
- PoloidalSpacing measures the ratio of the poloidal size of neighbouring cells, penalising variations - When PsiContours are merged on region boundaries, re-use the FineContour and distances that have already been calculated. - Add __str__ methods to the MeshMeasure subclasses - Add automatic optimisation to the `hypnotoad-geqdsk` script
Configuration menu - View commit details
-
Copy full SHA for 81a48cd - Browse repository at this point
Copy the full SHA 81a48cdView commit details
Commits on Feb 2, 2023
-
Output printing and plotting in script
- In optimisation loop only print every 20th iteration - In hypnotoad-geqdsk script save the plotted cells to file
Configuration menu - View commit details
-
Copy full SHA for 1128299 - Browse repository at this point
Copy the full SHA 1128299View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7e2bd16 - Browse repository at this point
Copy the full SHA 7e2bd16View commit details
Commits on Feb 3, 2023
-
Configuration menu - View commit details
-
Copy full SHA for a317cba - Browse repository at this point
Copy the full SHA a317cbaView commit details