The problem is that your 500mV output requirement is rare, so that very few regulators use a reference that is lower than ~1.25V (a few use 800mV).
One way to get this to work is to amplify the feedback signal using an op-amp. A gain of 3 would allow you to use any regulator with a reference voltage up to 1.5V.
Edit:
Say your regulator has a 1.25V reference, so you'd normally use a voltage divider RA/RB on the output such that Vout = 1.25V (1+ \$\frac {R_A}{R_B})\$.
Add a suitable op-amp to amplify the output voltage:
Vin comes from your output voltage. Say it is 500mV and your regulator has a reference voltage of 1.25V. Vout goes to the feedback input of the regulator (where the tap on the voltage divider goes).
In general your output voltage will be Vout = Vref (\$\frac {R_G}{R_F+R_G})\$, so in this particular example we might pick Rg = 10K and thence calculate Rf = 15K.
The very highest output voltage you can expect from this circuit with the chip in regulation is about 3.7V, so a 1K pot would be more appropriate. In fact you should allow a bit of margin, so maybe 3.5V maximum.
Using a pot as a rheostat is bad, using it as all the resistance is worse, and using only 20% (or less) of the element is really, really horrible, even if it's a good pot.
A 1% of full scale change in that pot means the output voltage will change by 5%, or 165mV if it's 3.3V.
If you're interested in millivolts, you should definitely limit the range of adjustment as much as possible. For example, if you need 3.3V you might use a 100 ohm pot with 787 ohms in series and an 499 ohm resistor for the bottom part of the divider.
For even better performance, shut the pot with a precision resistor of perhaps 1/10 the value and use it as a voltage divider. For example, a 1K pot used with a 110 ohm shunt. Then you could use a 452 ohm resistor for the and a 787 ohm resistor as follows:
simulate this circuit – Schematic created using CircuitLab
A 1% of full scale change in the pot position will change the output by about 0.2%, which is 100x better than your circuit, whilst still using very inexpensive components. The purpose of shunting the pot is two-fold- pot elements have lousy tolerance compared to resistors and this reduces the variation, and they have lousy temperature coefficient so that is proportionally reduced. Using it as a voltage divider virtually eliminates errors due to contact resistance variation (CRV).
You're also putting considerable current through the TLV431, presumably so you can draw a lot of current from it. Consider using a lower current and buffering the reference- it will reduce temperature-related drift of the bandgap reference. Trade that off against the inaccuracy caused by a high impedance in the feedback terminal.
(of course the above example value are just for illustration- substitute your own requirements and do the math for your situation).
Best Answer
Datasheet
R1 is chosen to set Vref on the TL431 to its nominal value of 2.495V. The output of the TL431 is dependent on the values of R1 and R2.
R4 is chosen to protect the Piezo from seeing more than 7V which is its limit. To figure out the value of R4 you have to consider the voltage drop of Vds on the FET and the current the piezo draws. From this calculate R4 to produce enough of a voltage drop to keep the voltage across the piezo to 7V or less.