I know I've studied this before, but for whatever reason I can't figure it out. I want to find two positive numbers. What I know is the difference between them and the percentages of their sum that they represent. I've been tinkering around and I came up with a formula that finds some relation, but doesn't get me to solve for those two numbers. Here's what I've been toying around with:

H = D + S(1 - P)

Where:

H = the higher number

D = the difference of the two numbers

S = the sum of the two numbers

P = the higher number's percentage of the sum of the two numbers

I feel like I'm on the wrong track by going about it this way, but what I've been trying to do with this is get all possible D's and P's on one side and H's and S's on the other. I can't seem to make that happen without creating duplicate variables that I can't formulate out. I start going all over the place like this:

H = D + S(1 - P)

H - D = S(1 - P)

(H - D)/(1 - P) = S

(H - D)/S = 1 - P

H/S - D/S = 1 - P

H/S = (1 - P) + D/S (has H and S on one side, but duplicates S on the other)

Like I said, I'm probably going about this all wrong, but I would like a start in the right direction.