2.22 Thursday, July 2, 2020

2.22.1 Top new questions this week
2.22.2 Greatest hits from previous weeks
2.22.3 Can you answer these questions?

2.22.1 Top new questions this week

How to make a structured mesh with a hole and extrude it
How to NOT a specific pattern?
Ordering Problem With VoronoiMesh
Peculiar behaviour in the implementation of "Filling"
i_:0|1 varies in v12.1: incompatible change or bug?
Inverse of StringReplace
Intersection of 3 circles in GeometricScene

How to make a structured mesh with a hole and extrude it

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=224739

I am trying to use the FEMAddOns package to make a structured mesh with a hole and then extrude it. As a warm up example this worked nicely.

Needs["FEMAddOns`"] 
pts1 = Table[ 
  25. (  ...

asked by Hugh https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=12558 14 votes

answered by Tim Laska https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=61809 13 votes

How to NOT a specific pattern?

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=225008

been going around in cirlces on this:

{1/3, 1, 0.22, 3, "v", 4} /. _?NumericQ -> "999"

Now I’m trying to replace everything that is not a number; is there a way to do this? ...

asked by CuriousDudeFromEgypt https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=66462 10 votes

answered by Szabolcs https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=12 13 votes

Ordering Problem With VoronoiMesh

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=224830

Imagine I want to model 2D cells moving in a tissue. Consider, as an example, Lloyd’s relaxation algorithm. Using VoronoiMesh I’m able to mimic some cell movement. Now, if I colour one of the cells in ...

asked by sam wolfe https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=64001 9 votes

answered by TumbiSapichu https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=53229 2 votes

Peculiar behaviour in the implementation of "Filling"

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=224907

I was working with mathematica and I need to use "Filling", however I notice that it doesn’t work when you have "small" numbers, for example if I make the following:

asked by Cruz https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=69573 9 votes

i_:0|1 varies in v12.1: incompatible change or bug?

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=224987

Just check

i_: 0 | 1 // FullForm 
 
In v12.0 or earlier the output is 
Alternatives[Optional[Pattern[i, Blank[]], 0], 1] 
 
But in v12.1 the output becomes 
Optional[Pattern[i, Blank[]], Alternatives[0,  ...

asked by xzczd https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=1871 9 votes

answered by Szabolcs https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=12 9 votes

Inverse of StringReplace

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=225071

Suppose I have the following StringReplace rule

StringReplace[st, {"a" -> "0", "OverBar[a]" -> "1", "b" -> "1",

asked by math https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=72358 8 votes

answered by Suba Thomas https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=5998 8 votes

Intersection of 3 circles in GeometricScene

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=224874

I am trying to represent the image below in Mathematica and can’t seem to make it work. There doesn’t seem to be any constraint of type circle intersection in the documentation. I tried this:

asked by SorinS https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=73427 8 votes

answered by SneezeFor16Min https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=69875 11 votes

2.22.2 Greatest hits from previous weeks

Why I get the "Set::write: "Tag Times in is Protected." error?
What are the most common pitfalls awaiting new users?
Is it possible to export the equations from Mathematica to MATLAB?
Generate a Unit Circle Trigonometry
How to find the position of elements in a list satisfying criteria
Get a "step-by-step" evaluation in Mathematica
Is there any algorithm that runs faster in Mathematica than in C or Fortran?

Why I get the "Set::write: "Tag Times in is Protected." error?

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=11868

Why I get the error below with this code:

Needs["VectorAnalysis`"] 
 
 = 1000; 
g = 9.80665; 
 = 0.001; 
p[x_, y_, z_, t_] = {x^2, Sqrt[y], -z, t^3}; 
f[x_, y_, z_, t_] = {-x^2, Sqrt[y]/2, z, t^2}; 
 
  ...

asked by Aurelius https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=1669 10 votes

answered by Mark McClure https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=36 13 votes

What are the most common pitfalls awaiting new users?

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=18393

As you may already know, Mathematica is a wonderful piece of software. However, it has a few characteristics that tend to confuse new (and sometimes not-so-new) users. That can be clearly seen from ...

asked by Dr. belisarius https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=193 462 votes

answered by Michael E2 https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=4999 279 votes

Is it possible to export the equations from Mathematica to MATLAB?

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=14035

Is it possible to export the output expressions from Mathematica computations (e.g., equations) in valid MATLAB syntax?

asked by Seyhmus Güngören https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=4256 41 votes

answered by rm -rf https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=5 48 votes

Generate a Unit Circle Trigonometry

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=2456

Struggling often with Trigonometry I would like to have some code to generate this Unit Circle Trigonometry. Would be of great help when I need to transform some data :

asked by 500 https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=172 18 votes

answered by Mark McClure https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=36 32 votes

How to find the position of elements in a list satisfying criteria

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=180

Say I have a list x=2,4,6,8,10 and I want to find out the positions of the elements that are greater than 7.

Select[x, #>7&] gives the elements themselves, and Position[x,8] gives the  ...

asked by PeterR https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=140 64 votes

answered by J. M.’s technical difficulties https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=50 62 votes

Get a "step-by-step" evaluation in Mathematica

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=148

Is it possible in Mathematica to get a step-by-step evaluation of some functions; that’s to say, outputting not only the result but all the stages that have led to it? If so, how does one do it?

asked by Cydonia7 https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=44 125 votes

answered by J. M.’s technical difficulties https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=50 105 votes

Is there any algorithm that runs faster in Mathematica than in C or Fortran?

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=208045

I’m just curious. My friend just told me that Mathematica is mostly for symbolic calculation and not efficient for Numerical computations. He told me that’s the reason most of the people don’t use ...

asked by Gummala Navneeth https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=66938 44 votes

answered by Szabolcs https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=12 73 votes

2.22.3 Can you answer these questions?

An apparent bug in Geometry‘ConvexHull2
When making a package, how can I make a function that is already used by system?
Simplifying expressions using elementary properties of integrals

An apparent bug in Geometry‘ConvexHull2

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=224966

I was replacing some usages of Geometry‘ConvexHull2 with ConvexHullMesh and found one of my tests failing. It turned out the test asserted an incorrect expected result that agrees with the result of ...

asked by Vladimir Reshetnikov https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=7288 1 vote

When making a package, how can I make a function that is already used by system?

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=224730

Obviously, Plus[a,b] is given by Mathematica but say I have a package and I want to name a function Plus[a,b]. How can I go about making a new function without overwriting the original function ...

asked by Brandon https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=73362 2 votes

Simplifying expressions using elementary properties of integrals

https://mathematica.stackexchange.com/landing/r/digest?cta=question&id=225023

I want to be able to use Simplify (or FullSimplify) to simplify expressions involving, for example, sums of integrals, for instance turning \[ \int _a^b f(x)\,dx + \int _b^c f(x)\,dx \] into \[ \int _a^c\] ...

asked by Pillsy https://mathematica.stackexchange.com/landing/r/digest?cta=user&id=531 2 votes