---
title: "Automatically calculate plot dia after slope angle"
url: "https://openforis.support/questions/4515/automatically-calculate-plot-dia-after-slope-angle"
tags: ["arena"]
status: "answered"
score: 0
answer_count: 2
asked: "2026-07-01T13:17:39"
last_activity: "2026-07-02T11:02:34"
source: "Open Foris Support - Q&A Forum"
license: "Copyright Open Foris, 2026. Some rights reserved under creative commons license."
---

# Automatically calculate plot dia after slope angle

Asked by Ten Trees Squared on 2026-07-01

Good day.
I'm trying to set up a field in the survey form designer, that will automatically calculate corrected plot radius for the survey team in field, after the slope angle has been determined and entered into the appropriate field.
Is this possible and how do I go about it?


plot_radius / Math.sqrt(Math.cos(slope_angle * Math.PI / 180))


## Answer (score 0, by Stefano (OF) on 2026-07-01)

Link: https://openforis.support/questions/4515/automatically-calculate-plot-dia-after-slope-angle/4516

Dear user,  
If your survey has an attribute with the plot radius called "plot_radius" and another one with the slope angle (in degrees) called "slope_angle", the expression you typed will work as it is.  
Create a new read-only attribute, called for example "plot_radius_adjusted" and use that expression as a default value expression (define it using the "Advanced" expression editor), following these steps:  

 - Create a new decimal attribute and mark it as read-only:  

![alt text][1]

 - In the expression editor that appears, click on the "Advanced" button on the top right corner:  

![alt text][2]

 - Copy and paste the expression in the text input:  

![alt text][3]

 - Apply the changes and if the expression is correct, the result should be this one:  

![alt text][4]


Many thanks,  
Open Foris Team


  [1]: https://openforis.support/upfiles/Screenshot_From_2026-07-01_14-33-27.png
  [2]: https://openforis.support/upfiles/Screenshot_From_2026-07-01_14-31-12.png
  [3]: https://openforis.support/upfiles/Screenshot_From_2026-07-01_14-31-41.png
  [4]: https://openforis.support/upfiles/Screenshot_From_2026-07-01_14-27-37.png


## Answer (score 0, by Ten Trees Squared on 2026-07-02)

Link: https://openforis.support/questions/4515/automatically-calculate-plot-dia-after-slope-angle/4517

Thank you so much for the help I really appreciate it.
