## numerical integration – Are there any dedicated built-in methods to NIntegrate over the unit sphere or the 3D rotational group?

As part of a molecular-physics calculation, I need to perform an integral to find the average of a certain function over all the possible orientations of the molecule,
$$langle f(mathbf v)rangle = int_{Rinmathrm{SO}(3)} f(Rmathbf v) :mathrm dR$$
To some extent, it is relatively easy to find clear ways to do this in Mathematica: the Haar measure in $$mathrm{SO}(3)$$ is cleanly expressed in terms of the Euler angles, and these are then easy to translate to $$R$$ using `EulerMatrix`, so one can use something like

``````NIntegrate(
f(EulerMatrix({α, β, γ}) . v) 1/8 Sin(β)
, {α, -π, π}, {β, -(π/2), π/2}, {γ, π, π})
``````

However, this approach doesn’t really “know” anything about the structure of the rotation group, and it looks liable to choose some sub-optimal sampling strategies that over-sample the regions where the Euler-angle coordinate mapping is singular.

(In case a specific example is useful, $$f(mathbf v)$$ can be chosen to be e.g. $$f(mathbf v) = left((mathbf acdotmathbf v)^2+(mathbf bcdotmathbf v)^2right)^p$$ for suitable semi-random $$mathbf a$$, $$mathbf b$$ and $$p$$.)

Having a look at the literature, there seems to be a clear consensus that the optimal way to do this is to decompose $$mathrm{SO}(3) cong mathbb S^2 times mathbb S^1$$ (i.e., use the angle-axis representation used by `RotationMatrix(θ,w)`) and then use

• some simple 1D integrator for the $$mathbb S^1$$ factor, and
• a dedicated spherical quadratures for the integration over the rotation-axis orientation in $$mathbb S^2$$.

As I understand it, the leading spherical quadrature used for the second factor is the Lebedev quadrature, which is symmetric under the octahedral group and is chosen to integrate, exactly, the spherical harmonics up to a given order.

So, on to my questions:

• Is there an existing (built-in, or pre-built package) way to use Lebedev quadratures in Mathematica?
• If not, is there an existing implementation that can be adapted for this?
• Alternatively, is there any way to inform `NIntegrate` about this structure and make it exploit it?
• Or can this be ignored by suitable settings for `NIntegrate` that will make it choose a close-to-optimal integration strategy?

## terminology – Is a constant literal an example of a built-in?

My understanding is that in a programming language, built-ins are bindings that exist without the user having to make them. (Like `+` to its referent, for example.)

My understanding of a constant literal is that it is a variable whose name encodes its value. (Like `3`, or `{"Name": "Steve", "age": 47}` in JS.

Is a constant literal considered a type of built-in?

## audio – After using a Bluetooth speaker: Macbook headphone audiojack is inserted, but the built-in speakers keep working instead

audio – After using a Bluetooth speaker: Macbook headphone audiojack is inserted, but the built-in speakers keep working instead – Ask Different

## Does Bisq have built-in wallet support for anything other than Bitcoin and BSQ?

In theory, one could use Bisq and not even have Bitcoin Core, or at least I believe such is the case. You could use it as your sole Bitcoin wallet, with local private keys and all. (But in practice, I don’t trust it as much as I trust Bitcoin Core, so I transfer it out to my Bitcoin Core wallet.)

It also supports its own cryptocurrency, called “BSQ”. That much I know for a fact, and it makes sense.

But what about all the other garbagecoins that it supports for trading? Does it actually allow you to hold those inside Bisq, with no extra software having to be installed? For example, if I buy an Ethereum (not that I would), can Bisq hold that or would it require me to have a separate “Ethereum wallet” installed to transfer to?

Are Bitcoin and BSQ just “special cases”, or are any crypto currency that Bisq supports for trading actually supported within Bisq itself to hold and manage?

## data – Time limit or built-in flush of HashTable entries

Is there a standard data type which is a struct or a table or a dictionary which will always delete objects that are older than t minutes? for example if I want to make sessions expire after 60 minutes. I don’t want to traverse the whole structure of course. I think we can do it with 2 generations. Every hour it makes the new generation and copies the first to the second

``````if self.server.current_hour_epoch != current_hour_epoch:
self.server.current_hour_epoch = current_hour_epoch
self.server.g1 = self.server.g0
self.server.g0 = {}
``````

then when we make lookups we look first in g0 and then in h1

``````# Generation 0 - we know all sessions in here are valid.
if sessionkey in self.server.g0:
userid = self.server.g0.get(sessionkey)
elif sessionkey in self.server.g1:
# Generation 1 - a session in here might be valid.
userid = self.server.g1(sessionkey)
``````

But I never saw a standard object with this capability, even though I think it is a general solution to a common problem.

## xinput – how to disable my laptop builtin keyboard permanently?

Respected members,
My laptops built in keyboard is broken or not working its automatically pressing keys , then i used x input but when it get switch off X input is disabling,when i boot up keyboard will automatically back online and it disturbing booting of the system. Is there way permanently disable the keyboard?

## plugins – WordPress built-in compression of images? How well does it compare to Photoshop or Shortpixel?

I think the quiestion is pretty straight forward.

I have around 5000 images I want to upload. I need to compress them somehow, but how?!

Photoshop compression
or
use the built-in compression of new wordpress versions.

Like does Photoshop do anything better? Because the only thing I can see in Photoshop is basically the % of compression for jpg. It also offers a preview of the image but I don’t really care nor need that for these types of images. I would do it in a batch either way.

So yeah, really? What is the difference and what would be beneficial in using the Photoshop compression or Shortpixel compression?

## How do I activate the built-in flash on the Canon Powershot G5 X?

I have a problem with the onboard flash of my camera.

I can’t figure out how to activate the flash…

Even in automatic mode, the camera is not flashing in dark scenes. I turned off the light in the room and it was really dark. But no flash…

The flash has to be opened manually, but how can I activate it? There is a button with a flash symbol, but it doesn’t do anything.

## networking – How can I discover a local network appliance and connect to its built-in webserver?

There are protocols / combinations of protocols designed for this very scenario. They broadly fall under the category of zero configuration networking aka zeroconf. Some popular implementations are Apple’s Bonjour (formerly known as Rendezvous), mDNSResponder (an Open Source implementation by Apple), and Avahi, an Open Source cross-platform implementation compatible with Bonjour. Microsoft’s protocol is called UPnP (Universal Plug and Play). There are also many implementations targeted at the IoT space for all kinds of footprints down to the smallest sensor platforms.

There was an effort standardizing zeroconf networking in the early 2000s, but the working group was dissolved without being able to agree on a set of protocols. Nonetheless, many operating systems, devices, and applications implement the drafts and ideas that were the basis of this working group. There has also been renewed interest in this area because of IoT.

It uses a combination of three protocols for fully zero configuration networking, but you can also pick and choose only one or two of those protocols.

• APIPA (Automatic Private IP Assignment) uses a pseudo-random number generator with retries to assign an IP address from the 169.254.0.0/16 network to a device. The protocol guarantees that eventually every device will have an IP address and there are no collisions. The equivalent for IPv6 has been designed in from the get-go: every link automatically always has a link-local IPv6 address, so any two devices can always communicate with each other over IPv6 with no configuration whatsoever required.
• DNS-SD (DNS Service Discovery) uses special DNS entries to describe services. For example, to find a printer in the local network, you just resolve the `SRV` record `_ipp._tcp.local.`
• mDNS (Multicast DNS) makes it possible to essentially just blindly send DNS Queries into the network as multicast UDP messages and allow anybody to answer them.

So, DSN-SD allows you to find services using DNS without having to know their location or address. mDNS makes it possible to use DNS without a DNS server or any sort of DNS infrastructure. And APIPA (or link-local addresses for IPv6) make it possible to assign IPs to devices without either having to statically configure them or requiring some form of infrastructure (e.g. a DHCP server).

In your case, you wouldn’t actually need DNS-SD, because you are not looking for any device that offers a particular service (i.e. “show me a list of all coffee machines”), you are looking for the device itself (“I want the coffee machine with serial number NCC-1701”).

mDNS is essentially a combination of your first two ideas.

## is there any builtin system in unity to categorize audio sources and change volume of a category?

I need a centralized setting for audio, like volume changes. so I need to put all audio source components in the scene in different categories. I can make a system for it but maybe there is a standard simple way to do it unity. is there any way to categorize those audio sources and set their volume based on those groups or categories like music,vfx, etc…