Найти в Дзене
Геннадий Антонов

VBA and heavy calculations for differential protection Vamp 59

Let's talk today about heavy calculations with help Visual Basic Application.

Also this is publication about - how on the surface simple tasks could go to time-consuming challenge.

Do you remember, reader, in my first article with Visual Basic where I had posted screenshot with Excel diagram? And so we will speak about that.

Once I had to test differential protection of cable line based on Vamp 59 microprocessor relay.

In the manual of relay protection it was explained equations on the basis microprocessor relay made calculations differential and bias currents.

In order to better understanding, I decided at that point, draw diagram in Excel, which will be demonstrated everything.

No sooner said than done.

Let's have a look on screenshot.

-2

It need to some explanations supposedly.

Gray-orange curve this is border of work differential protection. That border consist from 3 straight lines

Red point - this is result of calculations which in real time mode constantly make Vamp 59 relay protection.

If red point placed under curve - is everything fine.

In case of location red point over curve, that condition for trip actions of relay protection.

H'm, pondering, okay, but what if we want to know, which we have to make test current, so that to take red point in particular place of diagram?

No problems, now I will write equation in Excel and it will be everything successfully calculated.

Not on your nelly!

I was amazingly noticed for myself that this equations could be calculated only in one way.

Backward transformation from result were impossible.

Please, see that simplistic equations.

-3

I suppose that matter is in absolute value of number.

That very absolute value make this equations relative non transformable.

At least I did not found math solutions of reverse transformation.

Perhaps reader able to find?

I wrote the word "relative", because of nonetheless it can be to transform, just it necessary to take and to scan ALL possible values of currents and compare result with what we need.

Therefore my chart was redid thus.

-4

It was added blue point on diagram.

This is that place on diagram, where we want "to move" red point.

In other words which values we need to take so that red point moved to place blue point.

It was written macros which by push button bruteforce all values.

During the process development I noticed that initial valued (what we need to find) could be multiply.

Therefore I restrict result output just first 20 positions.

How did it, please look on video.