GSoC Report
https://szymag.github.io/
Recent content on GSoC ReportHugo -- gohugo.ioen-ukWed, 23 Aug 2017 20:41:21 +0100GSoC 2017 Report, Implementation of multiple types of coordinate systems for vectors
https://szymag.github.io/post/report/
Wed, 29 Aug 2017 20:41:21 +0100https://szymag.github.io/post/report/This page summarizes the work which I’ve done this summer.
About me My name is Szymon Mieszczak and I’m master student at Adam Mickiewicz University in PoznaĆ, Poland.
The goals The aim of my work was to introduce different kind of orthogonal curvilinear coordinate systems to vector package in SymPy. Previously coordinate system could be only rotated or/and translated with respect to other coordinate systems.
My work can be split into tasks.Week 11
https://szymag.github.io/post/week-11/
Wed, 23 Aug 2017 20:41:21 +0100https://szymag.github.io/post/week-11/During week 11 I extended differential operator to handle mixed coordinate system.
Mixed means that scalar or vector which we’re using as argument has elements coming from several different coordinate systems. Not necessarily connected. These work were split into three PR’s, one for every differential operator, gradient#13118 , divergence#13128 and curl#13154.
To implement this, we need to only take care about product rule for scalar and vector, but they are well defined.Week 10
https://szymag.github.io/post/week-10/
Thu, 10 Aug 2017 20:41:21 +0100https://szymag.github.io/post/week-10/During week 10 with my mentor, we finished creation of new CoordSys3D constructor. We can set now transformation while coordinate system is created. We’ve moved functionality from _connect_to_standard_cartesian to constructor so we support the same type of transformation as previously.
Now I demonstrate shorty how coordinate system different that Caertsian can be created in SymPy:
a = CoordSys3D('a', transformation='spherical', variable_names=["r", "theta", "phi"]) a.lame_coefficients() a.transformation_to_parent() b = CoordSys3D('b', lambda r, theta, phi: (r*sin(theta)*cos(phi), r*sin(theta)*sin(phi), r*cos(theta)), variable_names=["Week 9
https://szymag.github.io/post/week-9/
Wed, 02 Aug 2017 20:41:21 +0100https://szymag.github.io/post/week-9/Reconstruction of constructor in CoordSys3D is like never ending story, but fortunately we are almost at the end of the work. We decide to distinguish two cases. When rotation matrix or location is set and when transformation is set. In the first case we are creating transformation equations from rotation matrix and translation vector. In the second, user is responsible for defining transformation equations but it is also possible to use some pre-defined curvilinear coordinate system.Week 8
https://szymag.github.io/post/week-8/
Tue, 25 Jul 2017 20:41:21 +0100https://szymag.github.io/post/week-8/During week 8 I added several methods which calculate transformation equations for some specific situation. We’ve finished step, where transformation equations are obtained for rotation, translation, and changing the type of coordinate system. This all transitions are handled in vector module. We’ve also prepared the method for composition of any two kind of transformations, because coordinate system can be rotated and translated at the same time.
My current task is to use already added methods in CoordSys3D constructor.Week 7
https://szymag.github.io/post/week-7/
Tue, 18 Jul 2017 20:41:21 +0100https://szymag.github.io/post/week-7/During week 7 I continued my work on transformation equations for rotation. One PR #12960 which obtains transformation equations from rotation matrix was merged. I have prepared also method for composition of transformation equation but I didn’t push them. I need to still think how to arrange the whole structure. My mentor suggest that we can just use transformation equations instead of rotation matrix, because it’s just general concept. After that we could modify constructor in CoordSys3D class and put them transformation equation instead of rotation matrix.Week 6
https://szymag.github.io/post/week-6/
Tue, 11 Jul 2017 20:41:21 +0100https://szymag.github.io/post/week-6/In the last week I didn’t create any PR which is worth to mention so in this report I’d like to introduce the concept which we’re going to add vector module.
Currently, in SymPy we have transformation equations but they’re responsible only for rotation and translation. We have already implemented the transformation equations for changing type of coordinate system so we need to somehow deals with composition of this two kind of transformation.Week 5
https://szymag.github.io/post/week-5/
Tue, 04 Jul 2017 23:41:21 +0100https://szymag.github.io/post/week-5/This posts contains summary of two weeks work.
I was working on introducing transformation equations in CoordSysCartesian. We decide, up to now, to connect every other curvilinear coordinate system to Cartesian, so equations maps the rectangular one to the desired one. We allow user to set new coordinate system in three possible way:
a = CoordSys3D('a') a.connect_to_cartesian('spherical') a.connect_to_cartesian((a.x, a.y, a.z)) x, y, z = Symbols('x y z') a.connect_to_cartesian((x, y, z), (x, y, z)) So we can set coordinate system by str from pre-defined dict.Week 3
https://szymag.github.io/post/week-3/
Tue, 20 Jun 2017 23:41:21 +0100https://szymag.github.io/post/week-3/In the last week I focused mainly on finishing tasks related Lame coefficients. During this time two PR were merged. In my previous post I described how we can calculate gradient, curl and divergence in different type of coordinate system, so now I described only new thing which was already add to mainline. We decided to remove dependency between Del class and CoordSysCartesian. From mathematical point of view it makes sense, because nabla operator is just an entity which acts on vector or scalar and his behavior is independent from coordinate system.Week 2
https://szymag.github.io/post/week-2/
Tue, 13 Jun 2017 19:41:21 +0100https://szymag.github.io/post/week-2/My second week I spent on introducing Lame coefficients into CoordSysCartesian. Unfortunately, our work is restricted by SymPy structure so, we don’t have too much freedom in our implementation. Hopefully, with my mentor, Francesco, we found some solution how to achieve our goals without destroying vector module. This week shows that I have lack in my knowledge about object-oriented programming and SymPy.
Having access to Lame coefficient I was able to modified Del operator (in mathematics nabla operators) to handle spherical and cylindrical coordinate system.Week 1
https://szymag.github.io/post/week-1/
Fri, 02 Jun 2017 23:41:21 +0100https://szymag.github.io/post/week-1/My first task, which corresponds to GSoC was create three classes, Curl, Divergence, Gradient. They create object which are unevaluated mathematical expression. Sometimes it’s better working on such expression, for example when we wants to check some identity. We have to check if it’s true for every possible vector. We have still some work here, because in next step we want to create abstract vector expression. There is one open PR corresponding to described task:Week -2/Week -1
https://szymag.github.io/post/week--2/
Tue, 16 May 2017 23:41:21 +0100https://szymag.github.io/post/week--2/The end of may is quite busy for me. I have to finish some projects on my University before the end of month, to be sure that I will able to spend enough time on GSoC. Everything is on track, so there’s no reason to worry.
At the weekend I’m going to spend time on looking into SymPy, especially into diffgeom module. I would like to find some idea, witch could be use in my project.