0
votes
0answers
39 views

best way of plotting 3D surface from a binary voxel representation in Mathematica [duplicate]

I do have binary Voxel based data for representing a 3D mesh, i.e. a VoxelVolume with values of 1 or 0, 1 specifying that the voxel belongs to the object, 0 not belonging to the object. Standard ...
0
votes
0answers
72 views

How to solve boundary value problem with singularities at boundaries?

I have a boundary value problem, solving a system of differential equations with a singular boundary condtion (V[0] = 1/s, s->0) ...
1
vote
0answers
35 views

Issue with Mathematica Interface Colors in Linux

I have Mathematica installed on Linux and I have noticed that the colors are quite difficult to read. I am not sure how to configure the colors Mathematica uses for its interface components. In the ...
5
votes
3answers
199 views

If statement within WhenEvent

I'm trying to integrate an equation with a periodic solution using NDsolve. I want to stop the integration after the derivative of my solution has become zero for ...
0
votes
0answers
22 views

How to get an image when having indices of pixels [duplicate]

I am doing a perspective projection of a list of voxel V={v1,v2,v3,...,vn} using the perspective projection matrix 3*4 to get the indices of each pixel pi=(xi,yi). pi=P*vi Once I get the indices, I ...
0
votes
1answer
71 views

Plotting complicated Bessel functions expression

I am trying to plot this function ...
3
votes
1answer
66 views

Blocking Dataset`$ElisionThreshold doesn't work

I would like to define a simple function to automatically show all rows in a Dataset. Based on Taliesin Beynon's answer, I tried the following trivial snippet: ...
7
votes
1answer
119 views

Writing code which generates a function to append many columns to a dataset

I love datasets in Mathematica. Say I have one that looks like this: ...
1
vote
1answer
91 views

Help with singular integral

I'm new in Mathematica. I need solve a singular integral like $$\int_a^b \frac{A_0 + A_1 s + A_2 s^2 + A_3 s^3}{(B_0 + B_2 s^2 + B_4 s^4)(t-s)}ds$$ where $A's$ and $B's$ are reals and ...
2
votes
1answer
105 views

Boundary condition not fully taken into account in DEigensystem?

Context Mathematica 10.3 now has the very nice DEigensystem function. ...
1
vote
1answer
54 views

Replacing product of functions wih another function

I have a function which depends on w,x,y,z. Let me call ...
8
votes
1answer
265 views

Creating a colour variation effect of the Northern Lights

As is well known (see https://www.youtube.com/watch?v=fVsONlc3OUY ), the Northern Lights or Auroral displays appear as variations of several colours (generally pale green and pink). Is there a ...
1
vote
1answer
90 views

Multiple Import and Export of Images

I wrote a program that imports an image and creates three new images, for example "black and white" or "grey scaled". My problem is that i work with around 200 images and it takes a long time to ...
1
vote
0answers
59 views

Find multiple optimization parameters of Max-Min problem in numerically

I have an optimization problem $$\max \min [x_1,~\cdots,~x_m,~\cdots,~x_M]:~M\geq 2$$ where $$x_m=P_m(1-a_m)\prod_{j=1}^{m-1}\left(\frac{a_j}{1-a_j}+b_j\right)$$ and $$0\leq a_i<1;~~0\leq ...
3
votes
2answers
123 views

How to get Nearest lower value?

Nearestgives me the closest value to my reference, but what if I am always looking for the closest value, which is lower than my reference? ...
2
votes
1answer
85 views

simple contour plot with variable thickness

I have a data set on the form of 3 spatial coordinates x,y,z and an amplitude. Here is a small crop of the data, : ...
3
votes
3answers
53 views

How to use pattern matching to apply a function to specific elements of a matrix

I have a 3x3 matrix testweightedgraph = {{{}, {p, q, pq, pq}, {}}, {{p, q, pq, pq}, {q}, {}}, {{}, {}, {}}}; whose elements are (possibly empty) lists. I would ...
10
votes
3answers
247 views

Custom edge style (e.g. brush stroke, writing ink, etc.)

I would like to draw a graph with Mathematica in such a way that it looks like a handmade drawing or painting. To be more precise, is there a way to set a custom edge style such that it looks made ...
3
votes
1answer
94 views

Integration of angular distribution along cartesian axis

I am plotting an anisotropy distribution function as color coding on the surface of a unit sphere with this code: ...
1
vote
0answers
60 views

Prevent Mathematica using previous result [closed]

How can I prevent mathematica from using the previous computation in new one? How do I make the code below to compute same amount of time without memorizing previous computation. ...
3
votes
3answers
171 views

Making large calculation results persistent

Very often, I need to do same calculations under different parameters for comparing the results. Every calculation may generate a large data set; for example, the calculation result of ...
13
votes
2answers
303 views

How do you handle upgrade frequency now that minor releases come so quickly?

Does anyone understand the Mathematica upgrade treadmill these days? With the minor releases (10.2, 10.3) coming out fairly ...
3
votes
2answers
382 views

Solve stiff system by shooting method

I'm trying to solve a second order differential equation with the shooting method but, it appears to be a stiff system. This is worst for a larger parameter $\mu$. I've tried different methods: ...
4
votes
3answers
95 views

How create text label of form “var = ”, var properly formatted

If I use z = 99; Row[{TraditionalForm@HoldForm[z == 1], z}] then as output I get a property formatted math expression $z = 199$. How do I accomplish the ...
0
votes
1answer
54 views

Adjusting components of the MatrixPlot

I have the following code which yields the figure attached: ...
0
votes
0answers
39 views

Impose a condition on a function in a loop

I am trying to calculate something in the following code and I need to omit the final values which are going to be infinity.obviously I want to extract the answers of H2[s] which are zero. ...
1
vote
1answer
89 views

Using the Norm Function

I am trying to take the norm of a general vector and show that for vectors, v,w, that Norm[v cross w]^2==Norm[v]^2*Norm[w]^2-(v dot w)^2 In Mathematica, here are my steps: ...
2
votes
1answer
104 views

DateListPlot show iso week

How can I make DateListPlot show the iso week number? I would like to make a Date plot so that for each dot it will show the iso week date in the x-axis .
0
votes
1answer
53 views

Using Trig functions

This is a fairly simple notation problem. I am trying to compute ArcTan of the point (5,2). I have the code: ArcTan[5,2] which outputs: ...
1
vote
0answers
67 views

notebooks not opening in mathematica 10 (still, 15 months later)

Many of my students have Mathematica notebooks that they cannot open. I think that it's for the same reason identified in the other post with this title from July 2014. If you open a file, DON'T SAVE ...
6
votes
2answers
123 views

Scale SmoothHistogram curve to Histogram

Like in this question, I would like to display a histogram and a smooth histogram in the same plot. I believe the default “bin height specification” (or $\textit{hspec}$) for ...
5
votes
2answers
108 views

Retrieving normal looking Mathematica input from a cell expression

After a bad saving, I had problems with my Mathematica notebook. I have expressions in this form: ...
2
votes
0answers
39 views

Scaling 1D ArrayPlot divide by zero error [closed]

I am trying to overlay an ArrayPlot onto a WaveletScalogram, using the helpful answer here; however, my ArrayPlot is one-dimensional. My code: ...
8
votes
2answers
298 views

How can I use words/letters as pixels in an image?

I'd like to take the text of a novel or whatever and arrange it in a way that forms an image. Essentially recreating these works from Postertext. . I'm mostly looking for ideas regarding a ...
1
vote
2answers
102 views

Ploting horizontal lines in a ListLinePlot?

Hello i have made a graph with a oscillating behavior but i need to highlight the maximum value of the oscillation because i will use that value like a threshold and I need to put a horizontal line in ...
4
votes
1answer
107 views

How to collect terms with z-derivative?

my equations are very long (several pages). Here I will provide simple example: ...
1
vote
2answers
64 views

Plot of function-generated lists: Why does this workaround not work?

My problem is a classic one: I want to plot a function-generated list, and there's no way to pre-evaluate (because the actual function includes NMinimize and thus ...
6
votes
3answers
205 views

Creating new lists

We have the following list data = {{1,2,3,4,5}, {6,7,8,9,10}, {11,12,13,-1,14}} If I want to create a new list containing the first and the fourth elements of ...
4
votes
1answer
73 views

ToExpression to Latex Parenthesis

Everytime I use ToExpression to transform a TeX expression into mathematica input form, Mathematica always interprets parenthesis ('(' and ')') as square brackets, ...
3
votes
0answers
78 views

Improving the speed of an optimization algorithm via compilation and parallellization

I have written an implementation of eight variants of the PSO-algorithm and I want to test them over a set of test functions. I am using parallelization as it improves the speed a lot and I have also, ...
2
votes
2answers
78 views

mesh vertex coloring

So I created a mesh like this: mesh2 = ToElementMesh[FullRegion[2], {{1, 10}, {1, 10}}, MaxCellMeasure -> 1.]; and want to plot it, coloring the squares: ...
1
vote
0answers
29 views

Login failed with Windows account into sql server using mathemcatica

I am trying to make a connection from WOLFRAM- MATHEMATICA to an SQL server database. When I tried with my windows authentication, I am getting an error saying login failed for user, but when I tried ...
0
votes
0answers
47 views

SetOption for Plot

I have a very related question to my former one SetOption for plotting and I am not sure if I should edit it in order to ask two questions. So if one of the experienced users tells me to do so, I will ...
1
vote
0answers
52 views

Show doesn't show DataRange [closed]

I have the following simple code: ...
0
votes
1answer
86 views

Generating a function with named slots

Say I have an association: a = <|"a" -> "albatross", "b" -> "barbecue", "c" -> "champagne"|> And say I want a function with named slots to ...
5
votes
1answer
107 views

Huge overhead in RandomPoint[ImplicitRegion]

Commenting answers of this question @JasonB noticed the big overhead of RandomPoint ...
1
vote
0answers
50 views

Autocorrelation in Tail Events

I have a single time series of financial data (stock index returns) and would like to study the autocorrelation among (log-)returns that are classified as "extreme", for example via exceedance of a ...
3
votes
1answer
68 views

Whitespace is lost during MathML -> XMLElement conversion

ImportString["<mtext> </mtext>", {"MathML", "XMLElement"} ] XMLElement["mtext",{},{}] while I'd expect: ...
25
votes
5answers
2k views

Generate two random numbers with constraints

I want to generate two random numbers, $p$ and $q$, between $0.5$ and $1$. They are connected by the constraint $1/(2q) > p$. How do I generate $p$ and $q$?
3
votes
1answer
84 views

How to insert into a nested list/association?

Considering following nested structure: ...

15 30 50 per page