24.11.2017

The Real History of the C3D Kernel by Yuri Kozulin

Twenty years ago, the founders of ASCON Group made the decision to create their own 3D modeling software, KOMPAS-3D. To power the MCAD system, the company in 1996 established a team to develop a 3D geometric kernel precise enough to compete against other 3D SDKs. This is when the history of the Kolomna geometric kernel began.

During the years that followed, the kernel was continuously developed and improved. New modeling methods were invented, more efficient algorithms were developed, and modules were added like a parametric solver, a data converter, and a visualization module. Behind all these changes, there were people developing the geometric kernel now known as C3D Modeler.

Today, people not only take a greater interest in geometric modeling, but sometimes are also interested in who develops what. And so we decided to conduct interviews with members of the C3D Labs development team. The interviews we've already carried out include the following ones:

In this latest interview, we speak with Yuri Kozulin. He is responsible for developing the C3D Modeler geometric kernel. The interview was conducted by marketing manager Arkadiy Kamnev.

The Real History of the C3D Kernel by Yuri Kozulin, photo 1
Yuri Kozulin, Ph.D., Head of C3D Modeler Department at C3D Labs

Yuri, I would like to begin with some traditional questions. Where were you born? Where did you study? And where did you grow up?

I was born in Daugavpils in the south of Latvia. My father was a military engineer and my mother was a doctor. I went to schools in Latvia, Lithuania, and Germany, in what was then East Germany (GDR). When the Russian military began withdrawing fr om the GDR, we moved to Ryazan in Russia.

Was it hard for you to switch schools so often?

I felt quite comfortable in the Baltics and Germany, but I found it difficult to settle in the Russian school in Ryazan. Sometimes I had problems with my classmates, because when they skipped geography lessons, I usually remained in the classroom to learn more. This continued until the 8th grade, when students who, like me, wanted to study joined a special physics mathematical class.

The physics and mathematics class must have had a major influence on you being admitted to the technical institute.

I owe my love of the exact sciences to my mathematics teacher, Ms. Greta Ryazantseva. She encouraged me to enter the Physics and Mathematics School of the Moscow Institute of Physics and Technology (MIPT) by correspondence school. I loved physics, because there I could apply my knowledge of mathematics. I participated in several regional Olympiads in physics, where I took 2nd and 3rd places. At the same time, I was interested in radio engineering and so studied in a group project for several years. That is why I wanted to enter the Department of Radio Engineering and Cybernetics at MIPT, but I didn't have the required grades, and so in 1995 I entered the Department of Aerophysics and Space Research. In six years, I received my bachelor and master degrees, and then entered graduate school.

What did you study in graduate school?

While I studied, I participated in the Russian-American Observation Satellite International Project (RAMOS), where I investigated the possibility of using the stereo reconstruction of cyclones to forecast their development. My specialty was mathematical modeling, numerical methods, and program complexes. After completing my postgraduate studies, I defended my thesis for the degree of Candidate of Technical Sciences.

Did you ever visit the USA?

No, I never managed to get there as a student. Our partners invited me to the USA, but then relations between the two countries became more tense, and so I lost the chance. Collaboration was gradually phased out between the countries. However, I managed to get there later.

What else did you do when you were a student?

I don't remember exactly when, but sometime during the summer of 1997 or 1998 I has the opportunity to visit the town of Beloyarsky near the Arctic Circle. I was there to inspect the state of anti-corrosive protection of gas pipelines in Khanty-Mansi Autonomous Okrug (Western Siberia, Russia).

How did you end up there?

The theme of my bachelor degree work was related to adjusting ferroprobes used for diagnosing and inspecting gas pipelines. My supervisor told me, "You've developed your own methodology. Great job, but now it's time to test it in the field." So, off I went. In the summer, you get there only by air or by boat on the Kazym and Ob rivers. In the cold season, winter roads are laid right on top of frozen swamps. The following year, I instead inspected gas pipelines in Tver Region.

Did you enjoy your Siberian trip?

Siberia made a good impression on me, if you ignore all the tiny flying insects. I'll never forget the bloody rings on my wrists, where the small midges got through the gaps between my gloves and sleeves! And this is wh ere I first tasted fresh-frozen fish. I even remember its name – muksun. It's a delicacy for many northerners in Russia. Very tasty!

The Real History of the C3D Kernel by Yuri Kozulin, photo 2
Town of Beloyarsky, Khanty-Mansi Autonomous Okrug, Russia (top view)
 
The Real History of the C3D Kernel by Yuri Kozulin, photo 3
Yuri photographed with the customized swamp buggy

What was your first job after graduate school?

After graduation, I searched for a programming job with a mathematics or physics orientation. I got married after I defended my thesis, and so I had no desire to leave my native city. Although there were interesting employment opportunities in Moscow and Novosibirsk, ASCON's office was the closest to my home.

Upon joining ASCON, did you get to immediately join the team of mathematicians?

I misunderstood the published description of the job vacancy. It seemed to me that it was a systems group, and the group that I really thought was mathematical was actually engaged in 3D modeling. Then they explained the difference to me, and I immediately joined the team led by Dr. Nikolay Golovanov. We have been working together for 12 years. It is worth noting that Andrey Penkin and Alexander Maksimenko came to this team even earlier than me. They are our veterans. Eduard Maksimenko, the developer of the visualization module, is another veteran who has also been working at ASCON for a long time, although he is not engaged in mathematics.

What were your first projects after joining ASCON?

In the first six months I worked on bug fixes, and then management began to assign me to developing new functions and improving existing features. Sometimes a new function creates a new stream of bugs, especially when you try to integrate new features into existing functions.

Which functionality do you work with?

To be honest, I can hardly distinguish one software part from another anymore! I work in almost all areas related to geometric kernel development, and I even worked a little on optimization the conversion module. However, I never dealt with parametrization. All these components are now parts of C3D Toolkit.

Tell us about some of the most memorable moments in your work.

Well, I can't say that I've taken part in developing any breakthrough projects! I made many improvements and fixes to existing functions, such as for Boolean operation on bodies. I significantly improved the thin-walled shelling and the split line operation, and I created a shell-cutting operation from scratch. I've added a lot of special cases for surface and curve intersections.

Just what made these tasks interesting from the mathematics point of view? What were some of the challenges did you faced?

We don't invent anything from the point of view of mathematics; we put into practice what is described in theory. In this regard, we are ordinary programmers, but with a clear mathematical bias. Our work often requires more logical tweaks than mathematical ones. Often, we have to improve iterative processes. This helps improve stability and obtain more accurate solutions.

The Real History of the C3D Kernel by Yuri Kozulin, photo 4
The operation for constructing a thin-walled shell improved by Yuri Kozulin
 
The Real History of the C3D Kernel by Yuri Kozulin, photo 5
A Boolean operation for merging a cylinder and a sweep body

Last year, you were involved in improving the speed of operations in the C3D Modeler. Tell us a bit more about this.

I was indeed involved in performance improvement, but I could not devote 100% of my time to the task. There were many urgent bugs that I needed to fix. This is the main difficulty when you are trying to increase performance, because the task of fixing bugs in the kernel always has a higher priority.

This leads to a slowdown in some operations, and so we say that there is some kind of conditional "struggle" between performance and functionality: the more you focus on improving quality, the harder it is to increase performance. Today, I'm involved in increasing the performance of algorithmic improvements. I try to avoid solving problems connected with parallelization, except for cases when the use of several threads leads to errors in the calculations.

With who do you most collaborate in C3D Labs?

It's easier for me to name those with whom I least collaborate! These are my colleagues who deal with the C3D Solver parametric kernel. For that matter, C3D Converter, for example, is much more closely integrated with the C3D Modeler than C3D Solver.

The earliest versions of C3D geometric kernel focused on creating 2D/3D geometry, calculating mass properties, solving logical and dimensional constraints, and converting data between the most common formats. Over time, however, our customers began to request specific functions as modules that would be licensed separately. We decided on a new licensing model for our 3D SDK that turned the geometric, parametric, and conversion parts of our kernel into standalone products. All these modules – C3D Modeler, C3D Solver, and C3D Converter – are parts of a single SDK. At the marketing level, they are different products, but at the software level they are not. Recently, we added C3D Vision to help developers optimize visualization in their applications, and then we began marketing C3D Toolkit as the complete solution for 3D software developers.

Is it possible to separate geometry, parametrization, and conversion from each other unambiguously?

Converters use the geometric basis (curves and surfaces), so they are inseparable from the geometric kernel. C3D Toolkit gives us tight access to C3D Converter functions, and we do so as part of our licensing model. But the converters themselves do not disappear after this operation.

As for C3D Solver, it could potentially be separated from C3D Toolkit, because it doesn’t share that many objects with C3D Modeler. I can give an example: when I was involved in solving performance problems, I exported all NURBS surface calculation algorithms to a separate file and passed it to my colleagues, who were able to ensure isolated use of these algorithms in shaders. To work properly, these algorithms only need two objects from the geometric kernel: a vector and a point.

You devote a lot of time to fixing bugs, tell us how you are involved with the ServiceDESK.

I am the coordinator of the ServiceDESK at C3D Labs. As the work related to improving the kernel performance is becoming more intense, I am increasingly delegating bug fixing to others. To date, C3D Modeler bugs are fixed by me, Nikolay Golovanov, and Sergey Biryukov in roughly equal proportions. C3D Converter bugs are fixed by Alexander Spivakov. There is also a separate area that is led by Alexander Alakhverdyants from the C3D Solver team. This area is related to problems that arise for operating systems other than Windows: Mac OS, Linux, and Android. By the way, recently we noticed that the growth in the number of ServiceDESK requests is gradually declining. However, the number of tickets remaining open has increased, because there are very complex bugs and bugs that require a long implementation in the system.

How do ServiceDESK requests differ? Do you encounter difficulties in dealing with customers?

Issues vary from request to request: there are simple problems and complex ones. A very few are absolutely amateurish, while others are really simple to solve. I believe that this is due to shortcomings in the documentation for C3D Toolkit. We have to make our documentation more detailed.

As for dealing with customers, any emotion, positive or negative, is absolutely inappropriate here. Even if such emotions arise in our staff, we put them aside. When we respond to a customer's request, we should be strictly professional. After all, our customers help us improve our products and participate in the development of the roadmaps. We are very appreciate of this.

Who at C3D Labs oversees relations with global customers?

As a rule, I answer questions from our global customers in English. Most of these requests are sent in by potential customers; few requests from current users are received by ServiceDESK. Anna Ladilova answers questions regarding the geometric kernel's C# wrapper to partners in Sweden and India.

C3D Labs sent you on overseas business trips, such as South Korea.

Yes, but we encountered some difficulties during the visit, which we had to resolve quickly. For example, to communicate verbally with a potential customer we used a tablet with an online translation service. I did not expect to see Visual Studio with a Korean interface installed on the workstation, and so it was really hard for me to find the required commands! After this initial meeting, we now always take along a laptop with the software in English. Following this trip to South Korea, SolarTech bought a license to use the C3D Toolkit to develop QuickCADCAM software.

What do you remember most from your visits to South Korea and the USA?

During my entire time in South Korea, I always felt secure. Seoul is a very calm city, even though it is a metropolis. The USA impressed me with its good roads, and their non-aggressive, very responsible drivers. When I returned to Russia, it was difficult for me to not notice the gloominess of my fellow citizens. It turned out that foreigners are friendlier and more positive. This applies to both countries that I visited.

The Real History of the C3D Kernel by Yuri Kozulin, photo 6
Yuri Kozulin advises a customer during the business trip to South Korea
 
The Real History of the C3D Kernel by Yuri Kozulin, photo 7
Neighborhoods near The Scottsdale Plaza Resort in Arizona, the venue of the COFES

At COFES 2017 in Arizona, there was a lot of talk about the optimization of 3D models. If customers were to ask you to implement this function in the C3D Toolkit, could you?

C3D Labs doesn't make physics calculations; our field of activity is completely different. However, we do work with geometric bodies. If one of our partners gives us an optimized 3D model and asks us to process it, we will, of course, decide how to proceed with it. And this need not necessarily be a solid body, it could be a polygonal model. So when we come to a new field we need to teach our solutions to work with polygonal models directly. And this concerns not only section planes, but also Boolean operations, as well as any other functions required by users.

To end our interview, tell us about your hobby. What interests you outside of your work?

In the last few years, I haven't had enough free time for a serious hobby. However, I like to make rope crafts, like bracelets and flowerpots, and I used to be fond of making pencil sketches. I also liked analog photography at the time that film cameras were still in widespread use. I processed the film and printed the photos myself.

The lack of regular practice means that my drawing skills have decreased, but my wife and son are still delighted by them. I also like reading science fiction. But lately, it's getting harder to find good books. Authors tend to write formulaic books to earn big money while they can, so modern science fiction gradually ceases to be interesting. Because of this, I began to re-read old books. During rare trips to bookstores, I usually buy collections of short stories, as they sometimes contain good ones.

The Real History of the C3D Kernel by Yuri Kozulin, photo 8
Pencil sketches that Yuri drew for his son
 
The Real History of the C3D Kernel by Yuri Kozulin, photo 9
Homemade rope bracelets are Yuri's main hobby

Please provide a few parting words to the professionals who are thinking of joining C3D Labs.

If you get involved in geometric kernel development, there will be no way back =)

Share
Up