Copyright (c) 2003, Junzo SATO. All rights reserved.

Pangea with MathGL3D

The Pangea 3D graphics was displayed using MathGL3D application package.

Junzo SATO

July 28th 2003

[Graphics:HTMLFiles/index_1.gif]

•Pangea Algorithm

θ(rx_, ry_, rz_) := cos^(-1)((-rx cos(η) - ry sin(η))/(rz^2 + rx^2 cos^2(η) + ry^2 sin^2(η) + rx ry sin(2 η))^(1/2))

r := Module[{ϕ = Random[Real, {0, 2 π}], z = Random[Real, {-1, 1}]}, {(1 - z^2)^(1/2) cos(ϕ), (1 - z^2)^(1/2) sin(ϕ), z}]

rands = Table[r, {32}] ;

funcs = Map[Apply[θ, #] &, rands] ;

mat = Table[0, {360}, {180}] ;

<< Statistics`NormalDistribution`

gauss := Random[NormalDistribution[0, 1]]

newcut[nl_] := Module[{g = gauss},  If[Random[] < .5,  Join[Table[g, {#}], Table[0, {180 - #}]] & /@ nl,  Join[Table[0, {#}], Table[g, {180 - #}]] & /@ nl]]

Do[ nums = Table[Round[180 funcs[[k]]/π], {η, 0, 2 π - 2 π/360, 2 π/360}] ;  mat = mat + newcut[nums],  {k, 1, Length[funcs]}] ;

ConnectRGBColor[{iniR_, iniG_, iniB_}, {finR_, finG_, finB_}, var_] := RGBColor @@ ({iniR, iniG, iniB} (1 - var) + {finR, finG, finB} var)

earthColor[x_] := If[x <= .25, ConnectRGBColor[{0, 0, 0}, {0, 0, 1}, x/.25], If[x <= .65 ... 75) (x - .75)], ConnectRGBColor[{.90, .5, .15}, {.90, .5, .15} * 0.1, 1/(1 - .875) (x - .875)]]]]]

tex = ListDensityPlot[Reverse[Transpose[mat]], Mesh -> False, AspectRatio -> .5, ColorFunction -> (earthColor[#] &)]

[Graphics:HTMLFiles/index_14.gif]

-DensityGraphics -

max = Max[mat] ; min = Min[mat] ; lvl = Map[(# - min)/(max - min) &, mat, {2}] ;

General :: spell1 :  スペル間違いの可能性があります.新規シンボル\" max \"はすでにあるシンボル\" Max \"に似ています.

General :: spell1 :  スペル間違いの可能性があります.新規シンボル\" min \"はすでにあるシンボル\" Min \"に似ています.

texG = Show[Graphics[ Table[{earthColor[lvl[[i + 1, j + 1]]], EdgeForm[],  Polygon[{{i, j}, {i + 1, j}, {i + 1, j + 1}, {i, j + 1}}]}, {i, 0, 358}, {j, 0, 178}]],  AspectRatio -> .5]

[Graphics:HTMLFiles/index_20.gif]

-Graphics -

•MathGL3D

<< MathGL3d`OpenGLViewer`

<< Graphics`Shapes`

MVClear[] ; MVShow3D[Graphics3D[Sphere[]],  MVTexture -> texG,  MVTextureMapType -> MVSphereMapping,  MVNewScene -> True,  MVTextureSize -> {136, 136} ]

{MVScene3D[] <= MVTexture2D[23], MVSphereMapping, {128, 128, MVRGBTexture}}

MVPasteGraphics[]

[Graphics:HTMLFiles/index_27.gif]

-Graphics -


Converted by Mathematica  (July 28, 2003)