# Missing mathematical and trigonometric functions

sin
cos
tan
asin
acos
atan

8 Likes

This seems like a critical omission. Yet nobody else seems to care? Thankfully there isn’t an arbitrarily small limit on the length of the equations, because I had to use some Taylor expansions in order to migrate some data over from Google Sheets. What should have been as simple as `ACOS(L/R)` had to be turned into this monster, just to get `0.01` precision…

`3.14159265359/2 - L/R - POWER(L,3)/(6*POWER(R,3)) - (3*POWER(L,5))/(40*POWER(R,5)) - (5*POWER(L,7))/(112*POWER(R,7)) - (35*POWER(L,9))/(1152*POWER(R,9)) - (63*POWER(L,11))/(2816*POWER(R,11)) - (231*POWER(L,13))/(13312*POWER(R,13)) - (143*POWER(L,15))/(10240*POWER(R,15)) - (6435*POWER(L,17))/(557056*POWER(R,17)) - (12155*POWER(L,19))/(1245184*POWER(R,19)) - (46189*POWER(L,21))/(5505024*POWER(R,21)) - (88179*POWER(L,23))/(12058624*POWER(R,23)) - (676039*POWER(L,25))/(104857600*POWER(R,25)) - (1300075*POWER(L,27))/(226492416*POWER(R,27))`

Thank goodness I’m not doing anything more complicated than that right now.

AirTable, please incorporate this extremely basic functionality. This is really not asking much to have to avoid having to use such heinous formulas.

2 Likes

I agree - it is very important that the common math functions pervasive across all spreadsheet products are included in Airtable.

I have one client who could not tolerate this and compelled me to make it possible to use the entire Javascript Math library with Airtable fields. And it supports custom functions which could be mixtures of the standard Javascript Math library. I could only do it using the Airtable API and oddly, I used Google Apps Script to build it out. This is also accomplished without adding more formula fields (which they prefer) - the results are simply numeric fields that are updated whenever they are empty. They use a pseudo-script language in an Airtable text field that I invented which looks like this.

``````// set the base to Airdrop Demo
set base to appAvzbF1dJ9OkgMn

// set the table to the string parsing demo
set table to Math Functions Demo

// compute the values
replace all {{COS Results}} with {{Value (x)}}.Math.cos() where {{Name}} == COS(x)
replace all {{ACOS Results}} with {{Value (x)}}.Math.acos() where {{Name}} == ACOS(x)
replace all {{ATAN Results}} with {{Value (x)}}.Math.atan() where {{Name}} == ATAN(x)
``````

There are so many places where I see people hitting these types of low ceilings. I guess I need to think about open-sourcing my solution. My fear is they will add this functionality the day I publish this approach. If we simply had an embedded javascript engine inside Airtable, this and many other desperately-needed computational features would be at our fingertips.

2 Likes

Additional summary functions (MEDIAN/MODE) on top of the existing AVERAGE would be quite helpful. Not sure why they’re included in the field summary areas, but not in functions?

Also Retool allows users to jam Javascript in just about anywhere - I find this approach to handling transformations much more compelling than Airtable’s formula DSL.

2 Likes

We definitely need these functions. Please implement ASAP

1 Like

Yes please we need these functions, I wanted to recreate a trig function from Excel such as