Request : some useful formulas for the formula deformer.


Just started using the formula deformer. The default function is useful but of course just the tip of the iceberg. While I’m not completely mathematically illiterate, coming up with useful new formulas except by trial and error is beyond my abilities. I wondered if anyone had any nice formulas they’d like to share, or a link to some mathematics resource site with some likely candidates ?
Cheers for any suggestions.


It’s in french, but the images should be self-explanatory:


Thanks fluffouille - some good stuff in that thread. And I can give my rusty french a spin :smiley:


Excellant fluffouille, lots of resources there. Thanks for posting.


Wow, that’s a great resource, it’s like a formula wiki, thanks Sébastien. This may be a newbie question, but I tried replicating them with the formula deformer and it seems the deformer base80 uses is a bit different ( an older plugin perhaps?), and I don’t get any visible results.
Any ideas of how they should be translated into the formula deformer?


yeah great references.


Some of the most useful are the most basic

In r11.5 (with the new formula parser)


this is just a linear falloff from the center of a radial effect


this is a falloff that’s curved in a nice quadratic shape. You can adjust the shape by changing the last number (the power) in the pow function from close to 0 to up to any value. 1 is linear, below curves out above curves in.

sin((u + t) * pi2)

a nice sine curve from the center moving over time (t), to apply a falloff just multiply it by one of the previous two, anythign you multiply it by will be it’s overall scale.

sin((u + t) * pi2 * 10)

the same thing but with 10 times the frequency of waves

finally a fun one to mess around with, set your formula deformer to manual mode then the formula to the following (and put a plane under it)

for x : sin(xpi2)sin(zpi2)
for y : cos(x
for z : sin(x*pi2)cos(zpi2)

Then start messing a round with the size of the formula deformer. It’s also good fun to play with the values you multiply with to create more crazy shapes.


thx Per-Anders :slight_smile: .


All these samples were produced with the Spline formula (it’s an old thread), so I’m not sure how much can be applied to the formula deformer.


Per-Anders, thanks for the jump start on the newer Formula Object!
Very nice to play with falloffs this way.
Since the formula field is a string, I feed some settings from
UserData (on the DropFormula Object) with a few tostring() values.


QT Movie 1MB


Thanks Per!


Thanks Lennart - Can you explain what you did with the coffee portion of this scene on the Drop Formula Objects?


It’s a way to use the Userdata to animate/edit the Formula field.
For example, if I want to animate the t-parameter in this:

sin((u + t) * pi2)

I add a Userdata to the object. That becomes op#ID_USERDATA:1.

In the coffee tag I write:

 var t = op#ID_USERDATA:1;
 var formula = "sin((u + " + tostring(t)+" * pi2)"; // Insert the value in the string

 op#FORMULAOBJECT_DLT = formula; // Fill the formula field



How about some useful Coffee effector examples?


Thanks for all the tips, guys. Some great stuff in here.


per added this to an interesting gerstner thread a while back

however Per do you have any idea why this file seems to be broken in 11.5 as it works fine in 11 ?



Nice example there Lennart. I havent had a chance to look at the 11.5 features or d-load the demo. Do ALL deformers have falloff now? (sounds like at least the formula deformer does now?) That would be very nice.


Some nice formulas can be found on this german page:



The formula field is a bit more strict now, in that file the second formula doens’t have enough closing braces, just change the coffee to :

	var freq = op#ID_USERDATA:1;
	var wavelength = 1.0/op#ID_USERDATA:4;
	var magnitude = op#ID_USERDATA:2;
	var amplitude = op#ID_USERDATA:3;
	var wavevector = 2 * pi * wavelength;

	var x = "x - (" + tostring((wavevector / magnitude) * amplitude) + " * sin(" + tostring(wavevector) +  " * x - " + tostring(freq) + " * t ))";
	var y = "y + (" + tostring(amplitude) + " * cos( "+tostring(wavevector)+" * x - " + tostring(freq) + " * t )[B])[/B]";



thanks for explaining that. its a terrific set up BTW and a lovely render too.