Tag Info

New answers tagged

2

This is far from ideal and it has limitations with extreme triangles. The aesthetically pleasing images prompt me to post despite this. Perhaps others will improve. I modified David G. Stork function. The solid area is reasonable straight forward. The orange spheres delineate triangle: ae[a_, b_, c_] := Developer`PartitionMap[VectorAngle @@ # &, {a, ...


5

The general idea is the same as bbgodfrey's so most credits for him, the approach is slightly different, perhaps more automatic. We start by converting OP's parametric expression to cartesian: eq = #.# &@{Cos[Θ], Sin[Θ]} /. Solve[ Thread[{x, y} == RotationMatrix[β].{a + c Cos[Θ], b + d Sin[Θ]}], {Cos[Θ], Sin[Θ]} ][[1]] // Simplify ...


9

This problem can be simplified substantially by noting that only the largest ellipses contribute to the boundary of the second figure in the question. So, for instance, Table[ParametricPlot[RotationMatrix[β].{a + 5 Cos[Θ], b + 6 Sin[Θ]}, {Θ, 0, 2 Pi}, PlotRange -> {{-15, 15}, {-15, 15}}], {a, 0, 5, 1}, {b, 1, 6, 1}, {β, 0, Pi, 1}] // Flatten // ...


4

Make points on a sphere: pts = {p1, p2, p3} = Sort[Normalize /@ Table[RandomReal[{-1, 1}], {3}, {3}]]; Then plot a sphere with a region function on the 'positive' side of each of the three planes defined by the origin ({0,0,0}) and successive pairs of points: oneSide = ContourPlot3D[x^2 + y^2 + z^2 == 1, {x, -1, 1}, {y, -1, 1}, {z, -1, 1}, ...


3

If you do have version 10, another possibility is to use the new geometric computation functionality: ArcLength@DiscretizeGraphics@BSplineCurve@data1 The above give the total length. To find the length of the segment of the spline function sp between times t1 and t2, you could extend the same approach like so: length[{t1_, t2_}] := ...


1

Something easy to do, not very efficient though. dz = .0000001; arc[z_]:=NIntegrate[Norm[(sp[z + dz] - sp[z])/dz], {z, 0, 34}]


5

Using the somewhat outdates Splines package: Needs["Splines`"] f = SplineFit[{{0, 0}, {2, 0}, {2, 2}, {0, 1}}, Cubic]; ParametricPlot[f[t], {t, 0, 3}] The SplineFunction cannot be differentiated symbolically: f'[0] (* (SplineFunction[Cubic, {0.,3.}, <>]^\[Prime])[0] *) NDSolve can construct a numerical derivative (apparently): {arclength} ...


3

Simplifying complicated results sometimes takes a long time, so many Mathematica functions do not do so by default. Or they do it under a time constraint. Such is the case here, and in addition, FullSimplify is needed to simplify the nested Root objects. Note we need to add the constraints as assumptions to get the desired simplification. res = ...


4

supposing that your polynom is given with 2 dimensional points in counter-clockwise ordering. For example: points = {{4, 0}, {1, 2}, {0, 4}, {-3, 0}, {0, -1}}; Lets define a "test area" in which the polynom is embeded: {minX, maxX} = {Min@#, Max@#} &@points〚All, 1〛; {minY, maxY} = {Min@#, Max@#} &@points〚All, 2〛; The edges of the polynom are ...


4

myData = {{2, 1, #}, {1, 1, 0}} & /@ Table[1/(n + 2) + .2 RandomReal[], {n, 1, 15}]; SectorChart3D[myData, BoxRatios -> {1, 1, 1}, ColorFunction -> Function[{x, y, z}, Hue[z]], ColorFunctionScaling -> False]



Top 50 recent answers are included