Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Static Solar Panel resized to small size results in physics mass different from stated part mass and thus incorrect dV of craft as calculated in MechJeb #18

Open
SAOBunk opened this issue Dec 28, 2023 · 5 comments

Comments

@SAOBunk
Copy link

SAOBunk commented Dec 28, 2023

A Static Solar Panel resized to 0.14x0.2m, having an area of 0.028 m^2 and using the 11.2kg/m^2 stated for a TL0, should result in a panel mass of 0.3136kg. Checking the .craft file shows that part mass is saved with a couple extra grams at 0.3360kg, a minor difference: (EDIT: TL0 panels are 12kg/m^2, and their mass is thus actually correct at 0.3360kg.)
image

A test craft with 8 of these panels has the following stats in the hangar:
image

However, when firing the R103 SRB from a 200x200km orbit, the resulting 200x1572km orbit does not match MechJeb's expended dV value:
image
This change in apoapsis shows the craft only achieved 359.8 m/s of dV.
image

Performing the same experiment with a panelless craft of the same mass does result in the expected orbit and dV expenditure.
image
image
image

This leads me to suspect that there is an issue with the part mass of very small solar panels when in a flight scene, leading to incorrect dV of craft. Strangely, the solar panel part mass of the craft in save of a KCT simulation seems to be correct:
image

Both craft were created in an up-to-date express install of RO and RP-1.
Solar Panel dV tester nopanel.txt
Solar Panel dV tester.txt

Enlarging the panels' size to instead be 0.5x0.2m, results in a 1.2kg panel. However, the orbit achieved after performing the same test burn as before results in an orbit that is no different, even though the craft should have become heavier.
image
image

This suggests there's some issue where the panels somehow have a minimum mass in the physics simulation that is not reflected in their actual part configuration data, resulting in miscalculated dV values and thus failed missions.

@SAOBunk SAOBunk changed the title Static Solar Panel resized to small size results in incorrect mass or dV of craft as calculated in MechJeb Static Solar Panel resized to small size results in physics mass different from stated part mass and thus incorrect dV of craft as calculated in MechJeb Dec 28, 2023
@SAOBunk
Copy link
Author

SAOBunk commented Dec 28, 2023

Some further testing suggests the minimum mass the solar panel can have for the physics sim is 2kg.

@lpgagnon
Copy link
Contributor

previous discussion of what seems to be the same issue
https://discord.com/channels/319857228905447436/319857228905447436/985972007797674004

@SAOBunk
Copy link
Author

SAOBunk commented Dec 28, 2023

The issue is not present when Principia has been installed

@siimav
Copy link
Contributor

siimav commented Jan 15, 2024

So what is happening here is that KSP internally forces a minimum mass of 2kg on part RigidBodies. Thus the issue isn't limited to ROSolar and any physical part will trigger the discrepancy between calculated and actual dv.

Weirdly though, decreasing partRBMassMin in PhysicsGlobals to 1kg doesn't help at all. However what does work is overriding minimumRBMass at part level to a smaller value.

@skuvosk
Copy link

skuvosk commented Nov 6, 2024

I don't know how ksp parts are setup, but why can't the Static Panel behave the same way as the ST1 Panel? That one doesn't have this extra mass problem and mechjeb gives the correct dV when using it. The ST1 also don't add mass laterally (like experiments).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants