Logo by AGUS - Contribute your own Logo!

END OF AN ERA, FRACTALFORUMS.COM IS CONTINUED ON FRACTALFORUMS.ORG

it was a great time but no longer maintainable by c.Kleinhuis contact him for any data retrieval,
thanks and see you perhaps in 10 years again

this forum will stay online for reference
News: Support us via Flattr FLATTR Link
 
*
Welcome, Guest. Please login or register. April 27, 2024, 10:28:52 AM


Login with username, password and session length


The All New FractalForums is now in Public Beta Testing! Visit FractalForums.org and check it out!


Pages: 1 2 3 [4] 5 6 7   Go Down
  Print  
Share this topic on DiggShare this topic on FacebookShare this topic on GoogleShare this topic on RedditShare this topic on StumbleUponShare this topic on Twitter
Author Topic: A few formulas (For Luca... :D)  (Read 12771 times)
Description: Who can change the name of this thread... :D
0 Members and 1 Guest are viewing this topic.
M Benesi
Fractal Schemer
****
Posts: 1075



WWW
« Reply #45 on: November 01, 2015, 06:17:09 AM »

Set up the Benesi_Transforms UI with a magFoward at the beginning with a magBack half way down and lots of transforms in between. Was interesting when I used the UI  to recreate T1 out of five transforms, as there was not much increase in render time.
  Cool.  The rotations don't use trig functions, since we use precalculated square roots and the like... and the z^2 pine tree is all algebra too.  Makes it fast. 

And I must see if I can get the DE calc working ( generally outside my ability.)
  DE is pretty easy for this one. Keep a running derivative, multiply by the transforms scale.. if you use a non-vector scale!  To do the vector scale like you're doing, you're going to need to do some fancy footwork...


  T1 really is a good base to go from.. then throw another one in there every once in a while.  I'm liking t4 the most now, but might switch back to T2... should add that to the .frag.  Still learning the frag stuff...
Logged

mclarekin
Fractal Senior
******
Posts: 1739



« Reply #46 on: November 01, 2015, 11:23:23 AM »

I have been just having fun with the magTransforms on there own, but  attached is random examples  with Mbox, Mbulb and Menger_Sponge.

A bonus is using magForward & magBack  to orientate the fractal to vertical symmetry.

DE calcs are more than halving render times grin afro.

Well when making a basic scale transform I came across this fancy footwork problem. And  considered  Laplace & Lagrange but in the end decided on summing the components and dividing by three. grin

Cheers


* MboxMbulbMgr3.jpg (199.63 KB, 1500x388 - viewed 197 times.)
Logged
M Benesi
Fractal Schemer
****
Posts: 1075



WWW
« Reply #47 on: November 01, 2015, 05:35:26 PM »

lol.. the one on the right looks quite amusing... although I am easily amused at times.  cheesy 
Well when making a basic scale transform I came across this fancy footwork problem. And  considered  Laplace & Lagrange but in the end decided on summing the components and dividing by three. grin
I was thinking the length of z divided by three, tested it, didn't work... didn't do your thing.  nice that that works.  Can add it to other things...
Logged

ericr
Fractal Fanatic
****
Posts: 318


« Reply #48 on: November 02, 2015, 10:10:48 PM »

Where are "magTransforms on there own, but  attached is random examples  with Mbox, Mbulb and Menger_Sponge." for mandelbulb3d

ericr

 
Logged
mclarekin
Fractal Senior
******
Posts: 1739



« Reply #49 on: November 04, 2015, 04:32:39 AM »

@ M.Benesi  summing  fabs(scale. x y & z) /3 will  work when scale.x, scale.y & scale.z are the  similar, I have yet to retest when they are dissimilar.

Added six variables   for  pow( ) in T5B. Have yet to test.

 I recoded all the transforms, learning from your code that I can do   z  = CVector3 ( maths   , maths  , maths   ); grin
Spent all of yesterday fixing the bugs I had then created, sometimes I wish I was born an android, it is that human factor that causes me problems.LOL

And  now I should retro-fit rotations. 


 So I currently  now have all these transforms/formulas working in Mandelbulber grin


 
Code:
void benesiMagForwardTransformOneTransform3D(const sTransformBenesiMagForwardTransformOne &benesiMagForwardTransformOne, CVector3 &z, int i);
void benesiMagBackTransformOneTransform3D(const sTransformBenesiMagBackTransformOne &benesiMagBackTransformOne, CVector3 &z, int i);

void benesiMagTransformOneTransform3D(const sTransformBenesiMagTransformOne &benesiMagTransformOne, CVector3 &z, int i, sExtendedAux &aux);
void benesiMagTransformOnePlusMinusTransform3D(const sTransformBenesiMagTransformOnePlusMinus &benesiMagTransformOnePlusMinus, CVector3 &z, int i, sExtendedAux &aux);
void benesiMagTransformTwoTransform3D(const sTransformBenesiMagTransformTwo &benesiMagTransformTwo, CVector3 &z, int i, sExtendedAux &aux);
void benesiMagTransformThreeTransform3D(const sTransformBenesiMagTransformThree &benesiMagTransformThree, CVector3 &z, int i, sExtendedAux &aux);
void benesiMagTransformFourTransform3D(const sTransformBenesiMagTransformFour &benesiMagTransformFour, CVector3 &z, int i, sExtendedAux &aux);
void benesiMagTransformFiveBTransform3D(const sTransformBenesiMagTransformFiveB &benesiMagTransformFiveB, CVector3 &z, int i, sExtendedAux &aux);

void benesiFastPwr2PineTreeTransform3D(const sTransformBenesiFastPwr2PineTree &benesiFastPwr2PineTree, CVector3 &z, CVector3 &c, int i, sExtendedAux &aux);


Logged
M Benesi
Fractal Schemer
****
Posts: 1075



WWW
« Reply #50 on: November 04, 2015, 06:39:45 AM »

  Nice coloring...  Since this is the help thread....


  Update.  Having a bit of problems with the coding the assembly portions.  I probably did something silly.  Not sure about the jmps and conditionals, since I'm not used to assembly.

  Anyway, posting the code in this thread for Luca (or anyone who wants to debug it) to look at.  I'll hack at it more tomorrow. 

  I might be dividing in the wrong order.. (fdiv or fdivr???) or.. maybe I added a command after the jump command... haha.. I don't know.  Tired.

* BenesiSpheric.m3f (5.66 KB - downloaded 76 times.)
* BenesiUnSpheric.m3f (3.76 KB - downloaded 76 times.)
« Last Edit: November 04, 2015, 08:48:54 AM by M Benesi » Logged

M Benesi
Fractal Schemer
****
Posts: 1075



WWW
« Reply #51 on: November 04, 2015, 07:45:50 AM »

Awesome... I'm adding the cube to sphere and sphere to cube to M3D.   
Logged

DarkBeam
Global Moderator
Fractal Senior
******
Posts: 2512


Fragments of the fractal -like the tip of it


« Reply #52 on: November 04, 2015, 11:55:17 AM »

Finally had time to look at your works! wink

1) The transforms look OK but the DEoption must be different. That should be the reason why the images look bad currently.
2) Some of your formulas are a mystery to me; why they look like a quaternion? (No visible fractal detail)
Why redo IQbulb?
Why IQpinetree looks like a tricorn? Probably sign mistake/flipped Cx and Cy?

Some work is needed. And transforms need a _ prefix before too. wink

PS Have you got a non-trigonometric expansion for IQ formula (even just for power 2)? Would be greatly appreciated!!! Azn
« Last Edit: November 04, 2015, 12:01:49 PM by DarkBeam » Logged

No sweat, guardian of wisdom!
DarkBeam
Global Moderator
Fractal Senior
******
Posts: 2512


Fragments of the fractal -like the tip of it


« Reply #53 on: November 04, 2015, 06:19:10 PM »

Here I simplified a bit spheric (less temporary stuff & grouped some multiplications) + I will rename it with a _ prefix, added proper DE option (works perfect) wink
The only way to see which is good (div or divr?) is to test it directly with ollydbg; put two numbers in the stack and see which works each time or you will pick the wrong one grin

Code:
[OPTIONS]
.Version = 2
.DEoption = -1
.Double Scale = 0.81649658092773
[CODE]
558BEC81EC300000005356578B75088B7E308BD8D9D0DD02D8C8DD55F8DD01D8
C8DD55F0DEF9D9E8D8D9DFE080E4417E04D9E8DEF1D9E8DEC1D9FADD5DE890DD
45F8DC45F0DD03D8C8DEF9D9E8D8D9DFE080E4417E04D9E8DEF1D9E8DEC1D9FA
DC4FF0D9C0DC4DE8DD5DE8DD5DF090DD03DC4DF0DD02DC4DE8DD01DC4DE8DD19
DD1ADD1BD9D08BC35F5E5B89EC5DC20800
[END]


Description:

Warps a cube to a sphere; transform made by M.Benesi, optimized by
Luca.

/ spheric  code
 rCyz= (z.y*z.y)/(z.z*z.z);
 rCxyz= (z.y*z.y+z.z*z.z)/(z.x*z.x);
if (rCyz<1.) {rCyz=sqrt(rCyz+1.);} else {rCyz=sqrt(1./rCyz+1.);}
if (rCxyz<1.) {rCxyz=sqrt(rCxyz+1.);} else {rCxyz=sqrt(1./rCxyz+1.);}

z.yz*=rCyz;  
z*=rCxyz/sr32;
[/code]
Logged

No sweat, guardian of wisdom!
M Benesi
Fractal Schemer
****
Posts: 1075



WWW
« Reply #54 on: November 05, 2015, 05:56:36 AM »

You're awesome Luca.  Thanks!

  I'm going to try to flip that code for the unSpheric option after I finish this sphere to tetrahedron transform I'm working on.  For the cool "squares" you do Transform 1 (not pine tree!), unspheric, pine tree, spheric, on whatever iteration you want the cubes to appear.

  I'm working on a sphere to tetrahedron transform... and will probably make a tetrahedron to sphere as well.  With those, we will be able to blend Sierpinski and a Menger, with other stuff... cheesy


Logged

M Benesi
Fractal Schemer
****
Posts: 1075



WWW
« Reply #55 on: November 05, 2015, 07:58:07 AM »

Here is the "unSpherical" .m3f


  Do a pine tree or 2, T1, this, Pinetree x pixel, spherical, repeat...  for a few squarey sections.  cheesy


* BenesiLucaUnSpheric.m3f (4.08 KB - downloaded 82 times.)
Logged

DarkBeam
Global Moderator
Fractal Senior
******
Posts: 2512


Fragments of the fractal -like the tip of it


« Reply #56 on: November 05, 2015, 08:27:46 AM »

 A Beer Cup
I am curious: difference between spheric/unspheric? wink edit! Got it just that the sqrt(...) becomes 1/sqrt(...) wink
Editedit: Nope... I will keep your version as mine fails! cheesy A form of allergy perhaps? sad
Going to update "my" formula file now!
Pls reply to my questions above too afro
« Last Edit: November 05, 2015, 10:32:26 AM by DarkBeam » Logged

No sweat, guardian of wisdom!
M Benesi
Fractal Schemer
****
Posts: 1075



WWW
« Reply #57 on: November 05, 2015, 11:03:55 AM »

Finally had time to look at your works! wink
I thought you were talking about Mclarekin.. sorry.  lol.. This thread is all over the place.  

1) The transforms look OK but the DEoption must be different. That should be the reason why the images look bad currently.
 Ok, I probably need a few pointers. wink  maybe I should re-read stuff that you've told me..but I get caught up in stuff and miss it.  Sooo....  I might not set the DEoption things correctly.

  I did make a DE version for Fragmentarium (just do scale of Transforms, then standard .5*log(r)*r/dr (dr*scale for the transform iterations, *power for the pine tree section, etc...).

2) Some of your formulas are a mystery to me; why they look like a quaternion? (No visible fractal detail)
 Ok.  The "no YZ" ones don't have the y and z pixel component added in, which is why they look a bit like a spun Mandy.  What I need to do is change them, so they have pixel multipliers in the formula.  Then all of the extra formulas, like pine treeX  (which is only x pixel!) and PineTree1noYZ (no y z... only x, but it HAS the transform with it.  You need only pine tree, without transform 1, for certain things like the following:

Code:
Mandelbulb3Dv18{
g.....S....O/...w....2....kFvS./.....980zxzzzr1EIqupJ0QfnwHS4trZ.ruAzAZrFKNa3U.E
................................OaNaNaNadz1........A./..................y.2...wD
...Uz6....k2..../MU0/.....ke....2/....E3.....QzIXLua2PrD/..........m/dkpXm1....U
z.....kD12../..........wz.................................U0.....y1...sD...../..
.z1...sDECayXi7lax1..........WjJy0vma8djv8jrnNkXyq9YXdzcPGgNzEEnhwuma8dj2oQ9jigd
GuHyKt9g9PeYyYmQF6ua2PqDU.....2J..............sD.6....sD..G.....................
.............oAnAt1...sD....zw1.........................................A....k1.
.....Ksulz1.......kz.wzzz1.U..6.P....U5...EB....m....c3....F....6/...I1.....SF52
...U.qFG9yzb2zzzRYoWzz7lz16.pc..zXCc..kvrEtMc7xD6ocyFE0ujz1..........2.28.kFrA0.
.Ub96aAIVz9.1se7Umvxz0........../EU0.wzzz1...........s/...................E.2c..
zzzz.............0...................2./8.kzzzD............8....................
/EU0.wzzz1...................................2CcN/UvNPcveeWCNq0.yRiibHJJUk1f..XR
SvBmx3CcN/UvNPcvQsLsUa3.ibhVi1bTV1OK.sSq4uCly3CcN/UvNPcvMwLsUa3.ibhVinqTV1OK.sSq
4uCkz3CcN/UvNPcv..EsUa3feeWCNqGQIJ36wk8EwyLsUa3f................................
E....ME/F3U.....I....6....UEZtKNnZ4Jm3aPnNqPmpKA................................
...................../.........E................................................
................................................................................
.....................2.....3..../....6INiJqQdlIRX3KJiB3QcJaQdB4.................
..............................zD................................................
................................................................................
................................/....E/.........0JaPZBLOEZaPZV3.EZ4SZl4.........
........................................U.2.....................................
................................................................................
..........................................E.....I....2....UEZtKNnZqIkVKNmZqM.A4.
...................................................wz...........................
................................................................................
.....................................................A.....3....0....6INiJqQd/JO
iJKAixKKO/.....................................................E..........2.....
................................................................................
................................................................/....E/...U.....
0JaPZBLOI7LMiBbNj7LPo.....................................................2.....
...wz...........................................................................
............................................................................}
{Titel: square}


 
Why redo IQbulb?
Why IQpinetree looks like a tricorn? Probably sign mistake/flipped Cx and Cy?
Accident.  I used IQ for a template for pinetree or something, and I made a mistake, and it was an old version of the bulb (the flat one, shaped like a 2d Mandelbrot).  It might be unnecessary- I don't use it, although it would be good to mix it in if we had one or 2 more formula tabs to play with... then it would add more details.

Some work is needed. And transforms need a _ prefix before too. wink
 K...  I saw that... I just didn't get around to changing them before I got them up.  A bit excited, I suppose.  Apologies.  

PS Have you got a non-trigonometric expansion for IQ formula (even just for power 2)? Would be greatly appreciated!!! Azn

  K...  I will do tomorrow, time for sleep almost!  Original IQ, or one of my mistakes?  I think IQ pinetree was to make a non-z^2 pine tree for higher powers.... to mix with transforms and stuff.  
Logged

DarkBeam
Global Moderator
Fractal Senior
******
Posts: 2512


Fragments of the fractal -like the tip of it


« Reply #58 on: November 05, 2015, 11:15:16 AM »

Oh and I have found this old thread - a cousin of your fractal? The formula is very different though grin (edit not really - almost identical hehe wink )

http://www.fractalforums.com/theory/the-christmas-tree-3d-mandelbrot-set/

 A Beer Cup

Also; I think "_FoldingTetra3D" can be ok as a base for your tetrahedral project... look at it smiley
« Last Edit: November 06, 2015, 12:28:57 AM by DarkBeam » Logged

No sweat, guardian of wisdom!
M Benesi
Fractal Schemer
****
Posts: 1075



WWW
« Reply #59 on: November 05, 2015, 06:21:44 PM »

THATS WHAT HE CALLED IT!!    I thought he called it pine tree....  that's why I kept calling it pine tree... it does look like one a bit.  

  Christmas tree, not pine tree... hahaha...  

  I did switch the y and z coordinates for symmetry (it is slightly more symmetric with y and z switched)....

  I will check ________Folding_tetra_3d... and rename formulas (you can if you have mod editing power) with _ for transforms.  Might need to name transforms something other than T_1 through T_n...


"Note that this code does NOT affect the Menger-type formulas."   For the tetra.  It does affect them if you do it in between unsphere and sphere transforms, but it's not the type of thing I was going for.

  Ohh, and the scale factor for the sphere and unsphere?  Should default to 1 in the formulas to be correct- I thought the sphere was the wrong size, but it wasn't- and it really shows up when you mess with the tetra formula!  That's a quick change in the options!

* _BenesiLucaSpheric.m3f (0.71 KB - downloaded 72 times.)
* _BenesiLucaUnSpheric.m3f (4.06 KB - downloaded 68 times.)
« Last Edit: November 05, 2015, 06:43:05 PM by M Benesi » Logged

Pages: 1 2 3 [4] 5 6 7   Go Down
  Print  
 
Jump to:  

Related Topics
Subject Started by Replies Views Last post
has anybody tried using ifs formulas with the mandelbuld/mandelbox formulas? 3D Fractal Generation cKleinhuis 4 16486 Last post May 05, 2010, 03:17:07 PM
by Power 8
More Formulas? Mandelbulb 3d The Rev 2 4051 Last post November 21, 2010, 11:51:25 PM
by The Rev
Rot Box formulas Mandelbulb 3d The Rev 7 4962 Last post December 21, 2010, 01:37:13 PM
by Power 8
Formulas Mandelbulb 3d scheven_architect 5 5716 Last post April 28, 2011, 05:51:13 PM
by DarkBeam
Using formulas Mandelbulb 3d « 1 2 3 » Martial 43 5808 Last post February 09, 2012, 02:04:00 PM
by Jesse

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines

Valid XHTML 1.0! Valid CSS! Dilber MC Theme by HarzeM
Page created in 0.273 seconds with 29 queries. (Pretty URLs adds 0.016s, 2q)