L-norms of scalar functions

If f(t) is in L_2, does that imply that it is in L_infinity?

Background:

I know that if f(t) is in L_2, and g(t) is in L_infinity, then their product f(t)*g(t) is in L_2.

But if I know that h(t)*k(t) is in L_2, can I conclude that both h(t) and k(t)?

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/Ninjamonz
πŸ“…︎ Jan 13 2022
🚨︎ report
In the Logistic Function Theory, do I actually have to calculate the maximum of the function to determine if I should buy c2 or not? I plugged it into a function visualizer, setting c1 and q as scalars, and the function goes down after a certain c2, so I probably shouldn't buy c2 after the threshold
πŸ‘︎ 12
πŸ’¬︎
πŸ‘€︎ u/Kastamera
πŸ“…︎ Dec 27 2021
🚨︎ report
When I am using #SQL Aliases I can retrieve which file and library it is built over with #SQL scalar functions. [ #IBMi #rpgpgm ] rpgpgm.com/2022/01/retrie…
πŸ‘︎ 5
πŸ’¬︎
πŸ‘€︎ u/RPGPGM
πŸ“…︎ Jan 06 2022
🚨︎ report
Within the framework of the schrodinger equation, Is the wave function a completa scalar field?

Sorry for the basic question. I am trying to build a solid understanding from the ground up. Edit: i meant complex scalar field. Autocorrect is BS.

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/tricotraco123
πŸ“…︎ Nov 16 2021
🚨︎ report
Are activation functions useful when trying to predict scalars?

In most examples I've seen using activation functions the desired result is a boolean, like in giant_neural_network's series where the machine tries to determine whether a flower is red or blue based on its length and width. Is it useful for predicting scalars too (as in trying to predict the width based on the length and color)? Maybe by activating and deactivating certain weights?

πŸ‘︎ 4
πŸ’¬︎
πŸ‘€︎ u/AnonCaptain0022
πŸ“…︎ Sep 19 2021
🚨︎ report
A new #SQL scalar function that allows me to create PDF from spool files. This can be more than one spool file at a time, as I can do a whole output queue or even all the spool files belonging to a user. [ #IBMi #rpgpgm #IBMChampion ] rpgpgm.com/2021/06/creati…
πŸ‘︎ 6
πŸ’¬︎
πŸ‘€︎ u/RPGPGM
πŸ“…︎ Jun 03 2021
🚨︎ report
Assert as a scalar function?

So trying to dynamically categorize transactions from my banking statements.

Thing is the vendor/payee name often includes a specific transaction number or seller number so instead of paying 'amazon market place' the payee is 'amazon marketplace somespecificsellerid'

I was thinking of having a rules table with a stub column that would be equivalent to an assert statement 'vendor like 'amazon marketplace%'

Ideally I could join to this rule table and the scalar function would return true is the assert would pass

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/kurai_tori
πŸ“…︎ Jul 06 2021
🚨︎ report
New #SQL scalar function allows me to execute #CL commands within #SQL statements when they are executing. [ #IBMi #rpgpgm #IBMChampion ] rpgpgm.com/2021/06/qcmdex…
πŸ‘︎ 4
πŸ’¬︎
πŸ‘€︎ u/RPGPGM
πŸ“…︎ Jun 25 2021
🚨︎ report
finding the inverse of a scalar-valued function of two variables

if i had a function like f(x,y) = 2x-y, how would i find the inverse of it?

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/pinkiepie9247
πŸ“…︎ Apr 11 2021
🚨︎ report
Elliptic Curve Parametrization Using Weierstrass P function. Possibilities of use include point multiplication on elliptic curves by simply multiplying the parameter by some scalar

https://www.desmos.com/calculator/iv4ec9hmcv

https://preview.redd.it/1z5dwat0g2z61.png?width=238&format=png&auto=webp&s=dd172ed980a2e28de75604461094ff2f0edcca4f

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/AlephNullDesmos
πŸ“…︎ May 14 2021
🚨︎ report
Plotting a pitchwise mass averaged scalar function against span from a plane at the exit of a turbine blade (STAR-CCM+)

I am attempting to plot the pitchwise mass averaged data for multiple scalar functions against span for a stator blade in a turbine. The data is from a plane at the exit of the stator blade. I have tried using the mass flow averaged report but I can only seem to get a value for the whole plane. Is there a way to get the pitchwise mass averaged data on this plane plotted against span.

Here is the plane I am attempting to do this on https://imgur.com/a/mW3CDvB

This is being done in STAR-CCM+. I am fairly new to CFD so I apologise if I have missed something very basic but help would be appreciated.

This simulation is being done to mimic a physical experiment and the measurements for that were doen with a measurement plane with circumferential points to get this data. (if this is of any use)

Thank you!

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/ValorToMe
πŸ“…︎ Nov 13 2020
🚨︎ report
If a linear function T has a fixed point, does every scalar multiple bT also have a fixed point at bx?

If T(x)=x, then for some scalar b, bT(x)=bx=T(bx) by linearity of T.

Is this a sufficient proof?

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/MTGplayer1254
πŸ“…︎ Dec 11 2020
🚨︎ report
Is gradient of a scalar function a tensor? How?

The question is in the title, i didn't get the concept of tensors and i've been looking to find an answer to that. Can anyone enlighten me?

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/SorryMathStud
πŸ“…︎ Dec 02 2020
🚨︎ report
Scalar function too slow - Calculated field in column based on another columns

I have a big query, (really big, 800+columns - can't really make it smaller) that I'm trying to build in the most efficient way.

I have some fields like this:

SELECT distinct(td.EVENT_ID), 
       td.MENU_HINT, 
       td.EVENT_NAME, 
       td.EVENT_DT AS Expr1003, 
       COUNT(td.EVENT_NAME) AS [Total Runners], 
       -- AS [WinnerPrice], 
       -- COUNT(td.ID) AS [WinnerCount],
       SUM(CASE WHEN td.BSP >= 1 AND td.BSP < 2 THEN td.BSP END) AS Sum1to2, 
       count(CASE WHEN td.BSP >= 1 AND td.BSP < 2 THEN td.BSP END) AS count1to2, 
       avg(CASE WHEN td.BSP >= 1 AND td.BSP < 2 THEN td.BSP END) AS average1to2,
       dbo.FN_SumWinnerRunners(td.EVENT_ID,34,55,0,7,12) AS [TEST FUNCTION],
       SUM(CASE WHEN (td.BSP >= 2 AND td.BSP < 3) AND td.WIN_LOSE =1 THEN td.BSP END) AS SumWinnerPrice2to3, 
       count(CASE WHEN (td.BSP >= 2 AND td.BSP < 3) AND td.WIN_LOSE =1 THEN td.BSP END) AS CountWinnerPrice2to3
       FROM tblData td 
GROUP BY td.EVENT_ID, 
         td.MENU_HINT, 
         td.EVENT_NAME, 
         td.EVENT_DT
ORDER BY [Total Runners] DESC;

And here a graphical one (click to enlarge):

https://preview.redd.it/5xpivq1wvum41.png?width=1039&format=png&auto=webp&s=c77b04efb616ad4c7909da16b8c39ace75ba429e

if you notice, I've tried, as I have several queries that are fairly similar, to use a function (dbo.FN_SumWinnerRunners(td.EVENT_ID,34,55,0,7,12)

the definition for it below:

CREATE FUNCTION [dbo].[FN_SumWinnerRunners](
                                @event_id    INT,   
                                @BSPFrom     SMALLINT, 
                                @BSPTo       SMALLINT, 
                                @Win_Lose    SMALLINT, 
                                @RunnersFrom SMALLINT, 
                                @RunnersTo   SMALLINT)
RETURNS FLOAT
AS
     BEGIN
         DECLARE @result FLOAT=
         (
             SELECT SUM(CASE
                            WHEN(td.BSP >= @BSPFrom
                                 AND td.BSP < @BSPTo)
                                AND td.WIN_LOSE = @Win_Lose
                            THEN td.BSP
                        END)
             FROM tblData td
             WHERE td.EVENT_ID = @event_id
             HAVING COUNT(td.EVENT_NAME) > @RunnersFrom
... keep reading on reddit ➑

πŸ‘︎ 20
πŸ’¬︎
πŸ‘€︎ u/Baldie47
πŸ“…︎ Mar 15 2020
🚨︎ report
[P] Learning minima of an ND->scalar function

Hi community.

I have a computationally expensive scalar function f(r) of a large vector. My aim is to find its local minima using some heuristics starting from many different r0. I can do it directly (using CG, etc) but it takes a lot of computational time to do it.

Instead, I would like to learn g(r) ≃ f(r) and to find local minima of the learned function within some error bar err. I am free to generate arbitrary learning datasets as long as they are not too large. I hope that learning the function in the proximity of a few local minima will enable me to do that.

So my workflow is as follows: I learn the function g from the dataset of {r_i -> f(r_i)}, I test its values |g(r) - f(r)| < err and then I minimize the learned function g. This produces reasonable r_min (i.e. it remains close to the local minimum), however, |g(r_min) - f(r_min)| > err is still too large. Despite my dataset containing a lot of data close to local minima and despite random checks producing reasonable error bars minimization of g(r) always ends up at some "special" values of r_min with a much larger error bar.

My NN is quite simple (4 layers) and the learning process just minimizes |g(r) - f(r)|. What can go wrong here?

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/zpwd
πŸ“…︎ Aug 12 2020
🚨︎ report
Star CCM field function for passive scalar location

Hi I’m trying to define a passive scalar location for my tank (which has no inlet) as a spherical ball (equation x^2 + y^2 + z^2 = 0.1). Essentially a sphere of radius sqrt(0.1) at origin. What would be the syntax for this?

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/roderamoke
πŸ“…︎ Jun 27 2020
🚨︎ report
What is does the scalar-value mean in regards to a 'scalar valued multivariable function'?

I'm refreshing my multivariable calculus w/ a Coursera course, and when referring to the Jacobian they mention that "if you calculate it (the Jacobian) for a scalar valued multivaraible function you get a row vector pointing in the direction of greatest slope...".

I understand what a multivariable function is, but this is the first time I've heard any reference to a "scalar-valued" function. What does that mean?

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/GhostGlacier
πŸ“…︎ Dec 01 2019
🚨︎ report
Unsuccessfully obtaining the Return value of a SQL Scalar Function

Hi guys,

Relatively new to PS but I've spent hours trying to get to the bottom of this and now hope you can help.

I'm trying to run a SQL Function that returns a single result, not as the output but as the return value.

The function I'm running is dbo.WsParameterReadf('FPF_START_TIME'), which when run in a SQL browser returns the expected value '2019-12-17 17:43:12', a string representation of a date. The function itself is described as 'scalar-value function WherescapeMetaRepo.dbo.WsParameterReadF(@p_parameter varchar(64)) RETURNS varchar(4000), and as normal works by using EXEC or SELECT.

I've attempted two functions to get this value but both have been unsuccessful. I would appreciate any help!

Attempt 1:

function getParam($Parameter) 
{
$RepoCon                  = New-Object System.Data.Odbc.OdbcConnection($RepoConStr)
$RepoCon.ConnectionString = "DSN=${env:WSL_META_DSN}; Integrated Security=true;"
	$RepoCon.Open()
$cmd                      = New-Object System.Data.Odbc.OdbcCommand
$cmd.Connection           = $RepoCon
$cmd.CommandText          = "SELECT dbo.WsParameterReadf('$Parameter');"
$result                   = $cmd.ExecuteReader()

try
{
	while ($result.Read())
	{
		Add-Content $FILELOG "try:  SELECT dbo.WsParameterReadf('$Parameter') ($result.GetValue($1))"
		return $result.GetValue($1)
	}
}
catch
{
	Add-Content $FILELOG "catch: $_.Exception.Message"
}
finally
{
	  $RepoCon.Close()
  $RepoCon.Dispose()
  $cmd.Dispose()
}
}

$out = getParam("FPF_START_TIME")

Add-Content $FILELOG "out: $out"

Log reads:

try:  SELECT dbo.WsParameterReadf('FPF_START_TIME') (.GetValue())
catch: Exception calling "GetValue" with "1" argument(s): "No data exists for the row/column.".Exception.Message
out: 

When I manually run what it's running (over same ODBC DSN) I get a single row result...

Attempt 2:

function getParam($Parameter)
{
	$RepoConStr             = "DSN=${env:WSL_META_DSN}; Integrated Security=true;"
	$RepoCon                = New-Object System.Data.Odbc.OdbcConnection($RepoConStr)
	$cmd                    = New-Object System.Data.Odbc.OdbcCommand
	$RepoCon.open()
	$cmd.CommandTimeout     = 120
	$cmd.CommandType        = "StoredProcedure"
	$cmd.CommandText        = "WsParameterReadf '$Parameter'"
	$cmd.Connection         = $RepoCon
	$outParam               = New-Object System.Data.Odbc.OdbcParameter
	$outParam.ParameterName = "@Result"
	$outParam.Direction     = "ReturnValue"
	$outParam.O
... keep reading on reddit ➑

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/VegyBS
πŸ“…︎ Dec 19 2019
🚨︎ report
Super fast scalar integer base 2 logarithm and integer sqrt combinator functions

Scalar Integer Log2

While working on combiler, I tend to get distracted by another idea on how to compact one circuit or even get ideas for completely new ones - thanks to u/Halke1986 in particular :p

The other day, he presented a prototype for a fast base 2 logarithm function and we tinkered with it until the following super compact version was found:

Blueprint https://pastebin.com/K85X7rcy

It's really just this small, 1 decider combinator and 2 constant combinators acting as a ROM. The principle behind it is rather general, so allow me to explain how it works:

Fist, take a look at the graph of y=log_2(x) and the integer version, which just computes y=floor(log_2(x)), the latter of which I'll call ilog2 in the rest of this writeup

https://preview.redd.it/wh10rx99xr331.png?width=401&format=png&auto=webp&s=44ff2f3168bc929d5a58aed1a507384e413d6b72

The important feature of this function that we will exploit is that it's monotonic and that it's value range is really small:

  • log2 of negative numbers or zero doesn't make sense, and the best thing to do here is to just return 0
  • for all positive integers x, ilog2 will be a number between 0 and 31 (both ends inclusive) - this happens because signal values in factorio are just 32 bit signed integers, and the highest value is thus 2^(31)-1, whose ilog2 is 31

Now consider what the following decider combinator does:

[100 < Black then Black += 1] 

It seems simple:

  • pass in a value smaller than 100, and the result will be 0
  • pass in one that is greater or equal to 100, and the result it 1.

Now, consider what happens if you have two of those in parallel, but with different numbers, say 100 and 200:

  • pass in a value less than 100, and the result will be 0, since neither combinator returns 1
  • pass in a value between 100 (inclusive) and 200 (exclusive), and the result will be 1, since only the first combinator returns 1
  • pass in a value greater than or equal to 200, and the result will be 2, since both combinators return 1 each

I hope you start to see where we're going with this: each such combinator is a prototypic monotonic function, which simply

... keep reading on reddit ➑

πŸ‘︎ 19
πŸ’¬︎
πŸ‘€︎ u/Allaizn
πŸ“…︎ Jun 11 2019
🚨︎ report
Given a vector field F, find scalar functions u and v to decompose F into u grad(v) and v grad(u).

Is it always possible to find a pair of functions that satisfy this condition? And if so how can I find them?
This question popped up when watching Introducing Green's Functions for Partial Differential Equations (PDEs) 3:15.
Any guidance would be greatly appreciated, thanks in advance.

πŸ‘︎ 2
πŸ’¬︎
πŸ“…︎ Dec 27 2019
🚨︎ report
C++ Coder: C Function calls always return scalar values but a non-scalar value is expected here

I have the following code

returnPolygon.h:

double *add(double *in1, double *in2, int L);

returnPolygon.cpp:

#include "returnPolygon.h"
double *add(double *in1, double *in2, int L)
{
    double *res = new double[L];
    for (int i = 0; i < 5; i++) {
        res[i] = in1[i] + in2[i];
    }
    return res;
}

callReturnPolygon.m:

function S = callReturnPolygon  
%#codegen
if coder.target('MATLAB')
else
    coder.updateBuildInfo('addSourceFiles','returnPolygon.cpp');
    coder.cinclude('returnPolygon.h');
    res=[0 0];
    res = coder.ceval('add', [1,2,3], [4,5,6], 3);
    S=sum(res);
    sprintf('sum: %s', char(num2ascii(S,1)))
end

But I get the error

codegen -config:dll callReturnPolygon -report
??? C function calls always return scalar values but a non-scalar value is expected here.

Error in ==> callReturnPolygon Line: 8 Column: 11
Code generation failed: View Error Report
Error using codegen

Could anyone help?

EDIT

THe Matlab docs mentioned that coder.ceval can't return arrays. So I tried to solve the problem using Structures instead:

returnPolygon.h:

struct returnPolygon
{
	double *x;
	double *y;

	returnPolygon(double *in1, double *in2);
};

returnPolygon.cpp:

#include "returnPolygon.h"

returnPolygon::returnPolygon(double *in1, double *in2) {
	this->x = in1;
	this->y = in2;

}

main.cpp:

#include "returnPolygon.h"
#include <iostream>
using namespace std;

int main()
{
	double xarr[5] = { 1,2,3,4,5 };
	double yarr[5] = { 21,22,23,24,25 };
	returnPolygon rp = returnPolygon(xarr, yarr);
	std::cout << "x: " << std::endl;
	for (int i = 0; i < 5; i++) {
		std::cout << rp.x[i] << std::endl;
	}
	std::cout << "y: " << std::endl;
	for (int i = 0; i < 5; i++) {
		std::cout << rp.y[i] << std::endl;
	}
	return 0;
}

When I run the above code in Visual Studio, it compiles with no errors and correctly displays the values. But when I try the Matlab code

function S = callReturnPolygon1  %#codegen
S=struct('x',{0},'y',{0} );
if coder.target('MATLAB')
else
    coder.updateBuildInfo('addSourceFiles','returnPolygon.cpp');
    coder.cinclude('returnPolygon.h');
    S = coder.ceval('returnPolygon', [1,2,3], [4,5,6]);
    sprintf('sum: %s', char(num2ascii(S.x,1)))
end
end

and codegen -config:lib callReturnPolygon1 -report, I get the error

... keep reading on reddit ➑

πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/w358349
πŸ“…︎ May 17 2019
🚨︎ report
[Android][Scalar Pro][$2.49 -> Fully Free][Advanced Calculator][Math Engine][Math Scripts][Functions Graphs][Console Calculator][No Ads][No In-App Purchases]
πŸ‘︎ 36
πŸ’¬︎
πŸ‘€︎ u/leroykegan
πŸ“…︎ May 06 2019
🚨︎ report
Complex Drama on "Real Math" in a thread about the sins of K-12 math education when one karma scalar defends formula memorization, making the situation tensor. Can current math teaching function rationally, or does a sim totally need to rebuild it from the ground up? np.reddit.com/r/TrueReddi…
πŸ‘︎ 85
πŸ’¬︎
πŸ“…︎ Oct 14 2016
🚨︎ report
Evolutionary game landscapes: from fitness scalars to fitness functions. egtheory.wordpress.com/20…
πŸ‘︎ 13
πŸ’¬︎
πŸ‘€︎ u/DevFRus
πŸ“…︎ May 01 2019
🚨︎ report
[Vector Calculus] Given two arbitrary scalar functions, f and g, show βˆ‡ (fg) = fβˆ‡g + gβˆ‡f

So first off, should I be computing βˆ‡g and βˆ‡f as respective gradients of each vectors? Or as a dot product ( ex: βˆ‡ βˆ™ f) ?

Next, how would I go about doing this in a clean manner? I have about 6 other similar problems where two arbitrary scalar functions or arbitrary vector functions are given and I'm supposed to prove that LHS = RHS

πŸ‘︎ 3
πŸ’¬︎
πŸ‘€︎ u/throwawaylifeat30
πŸ“…︎ Jun 14 2018
🚨︎ report
SQL User Defined Functions | Table Valued Function vs Scalar Valued Func... youtube.com/attribution_l…
πŸ‘︎ 2
πŸ’¬︎
πŸ‘€︎ u/mamtabanerjee
πŸ“…︎ Feb 19 2019
🚨︎ report
Is a vector function always the gradient of a scalar function?
πŸ‘︎ 6
πŸ’¬︎
πŸ‘€︎ u/pigiou
πŸ“…︎ Jun 15 2020
🚨︎ report
[Android][Scalar Pro][$2.49 -> $0.99][Extremely Flexible Math Engine and Scripting Calculator + Beautiful Function Graphs]
πŸ‘︎ 14
πŸ’¬︎
πŸ‘€︎ u/leroykegan
πŸ“…︎ Apr 27 2019
🚨︎ report

Please note that this site uses cookies to personalise content and adverts, to provide social media features, and to analyse web traffic. Click here for more information.