For example, I have a pixel with these values:
CGFloat red = 34
and I want to increase the brightness so that the blue is 255. NOTE: With "Brilliance," I mean the Photoshop L component in the LAB color space. See photos!
There must be a special formula for calculating RGB values ββfor increased brightness, since RGB values ββchange non-linearly!
Evidence. I did a test in Photoshop and created the same color, and then opened the color picker to examine it:

Then I activated the L component of the LAB color space, which controls the brightness (at least this is what I'm talking about - I mean the brightness controlled by this component L. Guess what it is brightness).
So, with L activated, I dragged the slider from the left up until B reached 255: 
Now read the resulting RGB values:
CGFloat newRed = 112
The differences between them:
newRed - red = +78 newGreen - green = +60 newBlue - blue = +65
Interest:
red shift: +38.42% green shift: +29.55% blue shift: +32.01%
This does not match the well-known RGB Luminance calculation formula, which is close to luminance = (red * 0.3) + (green * 0.6) + (blue * 0.1) .
Obviously, they were shifted nonlinearly.
Is there a well-known way to calculate newRed, newGreen, newBlue from red, green, blue in the same way as Photoshop does it?